Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-27375] Add options to enable / disable choice providers #12

Merged

Conversation

Projects
None yet
2 participants
@ikedam
Copy link
Member

commented Mar 22, 2015

JENKINS-27375

Now you can enable / disable choice providers like this:
choicelistproviderdescriptor

Inheriting ChoiceListProviderDescriptor allows you display a global configuration only when it is enabled (See Global Textarea Choice Provider in the screenshot above).

[JENKINS-27375] Added system configuration fields for ExtensibleChoic…
…eParameterDefinition to disable specific providers.
@jenkinsadmin

This comment has been minimized.

Copy link
Member

commented Mar 22, 2015

Thank you for a pull request! Please check this document for how the Jenkins project handles pull requests

ikedam added some commits Apr 26, 2015

[FIXED JENKINS-28046][JENKINS-25403] Now uses f:dropdownDescriptorSel…
…ector, which is provided by Jenkins core. This avoids problem with Jenkins-1.610. / Now handles also $class not only stapler-class.

@ikedam ikedam changed the title WIP: [JENKINS-27375] Add options to enable / disable choice providers [JENKINS-27375] Add options to enable / disable choice providers Apr 26, 2015

[JENKINS-27375] the nested configuration in enabled / disabled sectio…
…n is enabled only when inheriting ChoiceListProviderDescriptor.
</j:scope>
</j:forEach>
</f:dropdownList>
<f:dropdownDescriptorSelector title="${%Choice Provider}" field="choiceListProvider" descriptors="${descriptor.enabledChoiceListProviderList}" />

This comment has been minimized.

Copy link
@ikedam

ikedam Apr 26, 2015

Author Member

Gets to use dropdownDesciptorSelector to resolve JENKINS-28046.
And descritor.enabledChoiceListProviderList hides disabled providers.

String staplerClazzName = formData.optString("$class", null);
if (staplerClazzName == null) {
// Fall back on the legacy stapler-class attribute.
staplerClazzName = formData.optString("stapler-class", null);

This comment has been minimized.

Copy link
@ikedam

ikedam Apr 26, 2015

Author Member

Changes for JENKINS-25403.

@ikedam

This comment has been minimized.

Copy link
Member Author

commented Apr 26, 2015

Includes changes for JENKINS-28046 and JENKINS-25403 as changes for config.jelly will be conflicted if splitting them into different pull requests.

);
assertEquals("no choice is provided and editable", null, target.getDefaultParameterValue());
}
}

This comment has been minimized.

Copy link
@ikedam

ikedam Apr 26, 2015

Author Member

Above tests are moved from ExtensibleChoiceParameterDefinitionSimpleTest.

);
assertEquals("no choice is provided and editable", null, target.getDefaultParameterValue());
}
}
}

This comment has been minimized.

Copy link
@ikedam

ikedam Apr 26, 2015

Author Member

Above tests are moved to Above tests are moved fromExtensibleChoiceParameterDefinitionJenkinsTestas those tests get to require Jenkins instance andExtensibleChoiceParameterDefinitionSimpleTest` doesn't set up Jenkins instance to save test execution time.

ikedam added a commit that referenced this pull request May 15, 2015

Merge pull request #12 from ikedam/feature/JENKINS-27375_DisableProvi…
…ders

[JENKINS-27375] Add options to enable / disable choice providers

@ikedam ikedam merged commit 74176e3 into jenkinsci:master May 15, 2015

1 check passed

Jenkins This pull request looks good
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.