From 6072e9a52cf01723aea2b9a5ca7dfe22b101fbfc Mon Sep 17 00:00:00 2001 From: Unknwon Date: Thu, 23 Feb 2017 18:25:12 -0500 Subject: 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. --- public/js/gogs.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'public/js') 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 () { -- cgit v1.2.3