diff options
author | Georg Ehrke <dev@georgswebsite.de> | 2012-08-01 18:03:08 +0200 |
---|---|---|
committer | Georg Ehrke <dev@georgswebsite.de> | 2012-08-01 18:03:08 +0200 |
commit | 8766b3286b479157cb7d6690209ff506fb01974a (patch) | |
tree | c66cc54b76bcb49f0d7c0fe2fd52baf94cc30ce0 /settings/js/users.js | |
parent | 98f37b93f62ce01d11234dfca2abfdae7203a92e (diff) | |
download | nextcloud-server-8766b3286b479157cb7d6690209ff506fb01974a.tar.gz nextcloud-server-8766b3286b479157cb7d6690209ff506fb01974a.zip |
fix a subadmin UI bug
Diffstat (limited to 'settings/js/users.js')
-rw-r--r-- | settings/js/users.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/settings/js/users.js b/settings/js/users.js index 7f3b027b4df..8fb587778b7 100644 --- a/settings/js/users.js +++ b/settings/js/users.js @@ -304,9 +304,13 @@ $(document).ready(function(){ tr.attr('data-uid',username); tr.find('td.name').text(username); var select=$('<select multiple="multiple" class="groupsselect" data-placehoder="Groups" title="Groups">'); + var subadminselect=$('<select multiple="multiple" class="subadminsselect" data-placehoder="Groups" title="' + t('files', 'SubAdmin') + '">'); select.data('username',username); select.data('userGroups',groups); + subadminselect.data('username',username); + subadminselect.data('userGroups',groups); tr.find('td.groups').empty(); + tr.find('td.subadmins').empty(); var allGroups=$('#content table').data('groups').split(', '); for(var i=0;i<groups.length;i++){ if(allGroups.indexOf(groups[i])==-1){ @@ -315,12 +319,18 @@ $(document).ready(function(){ } $.each(allGroups,function(i,group){ select.append($('<option value="'+group+'">'+group+'</option>')); + if(group != 'admin'){ + subadminselect.append($('<option value="'+group+'">'+group+'</option>')); + } }); tr.find('td.groups').append(select); + tr.find('td.subadmins').append(subadminselect); if(tr.find('td.remove img').length==0){ tr.find('td.remove').append($('<img alt="Delete" title="'+t('settings','Delete')+'" class="svg action" src="'+OC.imagePath('core','actions/delete')+'"/>')); } applyMultiplySelect(select); + applyMultiplySelect(subadminselect); + $('#content table tbody').last().append(tr); tr.find('select.quota-user option').attr('selected',null); |