Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-68328

Active Choices is not work when i use Jenfinsfile script

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Blocker Blocker
    • active-choices-plugin
    • None
    • Jenkins 2.303.1
      Active choices 2.6.1

      Hello,

      I work actually on jenkins version Jenkins 2.303.1 and i use active choice plugin version 2.6.1. When i use a Jenkinsfile declaration, the active choices is not shown but when i try in web UI on pipeline it's work.
      can you help me please?

      ======The content of Jenkinsfile is =====

      properties([
          [$class: 'BuildConfigProjectProperty',
              name: '',
              namespace: '',
              resourceVersion: '',
              uid: ''
          ],
          parameters([
              choice(choices: ['ruf', 'med'], description: 'Choisir le site emplacement', name: 'site'),
              [$class: 'CascadeChoiceParameter', choiceType: 'PT_RADIO', description: 'Merci de selectionner un datacenter',
                  filterLength: 1,
                  filterable: false,
                  name: 'datacenter_name',
                  randomName: 'choice-parameter-8649817365215456',
                  referencedParameters: 'site, platform',
                  script: [$class: 'GroovyScript',
                      fallbackScript: [classpath: [],
                      sandbox: false,
                      script: ''
                  ],
                  script: [classpath: [],
                      sandbox: false,
                      script: '''if ( site == "med")

      {                                 return ["MEDINA:selected"]                             }

                                  else

      {                                 return ["Rufisque"]                             }

                              '''
                          ]
                  ]
              ]
          ])

      ])

            kinow Bruno P. Kinoshita
            babagadji Baba GADJI
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: