I have a repeatableProperty in Jenkins Global Configuration page (see 
https://github.com/jenkinsci/warnings-ng-plugin/pull/266 
<https://github.com/jenkinsci/warnings-ng-plugin/pull/266>).

Expanded snippet:
<f:section title="${%Warnings Next Generation Plugin Global Settings}">
  <f:entry title="${%sourceDirectories.title}" 
description="${%sourceDirectories.description}">
    <f:repeatableProperty field="sourceDirectories">
      <f:entry title="">
        <div align="right">
          <f:repeatableDeleteButton />
        </div>
      </f:entry>
    </f:repeatableProperty>
  </f:entry>

</f:section>

(And a describable config.jelly)
<f:entry title="${%Absolute path of folder}" field="path">
  <f:textbox/>
</f:entry>
I can successfully add entries and delete entries in the UI. However, if I 
remove the last element in the UI then the empty list ist not saved. More 
precisely, the data bound setter 
/**
 * Sets the list of source directories to the specified elements. Previously 
set directories will be removed.
 *
 * @param sourceDirectories
 *         the source directories that contain the affected files
 */
@DataBoundSetter
public void setSourceDirectories(final List<SourceDirectory> sourceDirectories) 
{
...


Is not called if I remove all elements in the UI (it is called for 1,…,n 
elements). Has anyone an idea what I am making wrong? 

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/987D0FAA-15D1-4AD7-9EF8-9918EB79FF62%40gmail.com.

Reply via email to