Hi everyone,

I'm currently implementing a plugin to allow the creation of jobs using a
"master job".
Basically, I have a job "Job Creator", that currently has a dropdown list
for the job type to be created and the available build steps to the given
job type.

Right now, my jelly looks like this:

  <f:entry title="Jobname" field="jobName">
    <f:textbox />
  </f:entry>
  <f:entry title="Build job after creation?" field="runJobAfterCreation">
    <f:checkbox />
  </f:entry>
  <f:entry field="projectType" title="Project / Job Type">
    <f:select default="noTypeSelected"/>
  </f:entry>
  <f:repeatable var="buildSteps" name="buildSteps"
items="${instance.buildSteps}" noAddButton="false" minimum="1">
      <f:entry field="buildStepType" title="Build Step Type" <!--
description="build step to be added" -->>
        <f:select default="noBuildStepSelected"/>
      </f:entry>
  </f:repeatable>

However, the job configuration shows no add/delete buttons. If I add them
manually like this:

  <f:entry title="Jobname" field="jobName">
    <f:textbox />
  </f:entry>
  <f:entry title="Build job after creation?" field="runJobAfterCreation">
    <f:checkbox />
  </f:entry>
  <f:entry field="projectType" title="Project / Job Type">
    <f:select default="noTypeSelected"/>
  </f:entry>
  <f:repeatable  var="buildSteps" name="buildSteps"
items="${instance.buildSteps}" noAddButton="false">

      <f:entry field="buildStepType" title="Build Step Type"
description="build step to be added">
        <f:select default="noBuildStepSelected"/>
            <f:entry> 
          <div align="left">
            <input type="button" value="Delete" class="repeatable-delete
show-if-only" style="margin-left: 1em;" /><br/>
            <input type="button" value="Add" class="repeatable-add" />
              </div>
        </f:entry>
      </f:entry>

  </f:repeatable>

...the buttons show up, but another problem emerges. The add-button does
nothing (clickable, but no additional dropdown lists get added) and the
delete button deletes the whole build step, not just the dropdown list.

Can someone point out what may be wrong with my code?

Thanks in advance,
Sebastian 



--
View this message in context: 
http://jenkins-ci.361315.n4.nabble.com/Repeatable-add-delete-buttons-do-not-show-up-do-not-work-tp4718150.html
Sent from the Jenkins dev mailing list archive at Nabble.com.

-- 
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].
For more options, visit https://groups.google.com/d/optout.

Reply via email to