aboutsummaryrefslogtreecommitdiff
path: root/public/js
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2017-02-23 18:25:12 -0500
committerUnknwon <u@gogs.io>2017-02-23 18:25:12 -0500
commit6072e9a52cf01723aea2b9a5ca7dfe22b101fbfc (patch)
tree17fe0e830584dfef2ff855bc75992df727997c08 /public/js
parentb78e03934d057bdb4c628fefb364dda6eb1f260a (diff)
repo: add protect branch whitelist (#4177)
Add options to add users and teams to whitelist of a protected branch. This is only available for organizational repositories.
Diffstat (limited to 'public/js')
-rw-r--r--public/js/gogs.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/public/js/gogs.js b/public/js/gogs.js
index 2cd98d3b..0bf65c13 100644
--- a/public/js/gogs.js
+++ b/public/js/gogs.js
@@ -341,7 +341,7 @@ function initRepository() {
// Branches
if ($('.repository.settings.branches').length > 0) {
initFilterSearchDropdown('.protected-branches .dropdown');
- $('.enable-protection').change(function () {
+ $('.enable-protection, .enable-whitelist').change(function () {
if (this.checked) {
$($(this).data('target')).removeClass('disabled');
} else {
@@ -1223,7 +1223,9 @@ $(document).ready(function () {
});
// Semantic UI modules.
- $('.dropdown').dropdown();
+ $('.ui.dropdown').dropdown({
+ forceSelection: false
+ });
$('.jump.dropdown').dropdown({
action: 'hide',
onShow: function () {