permissions_objects.mako
80 lines
| 4.1 KiB
| application/x-mako
|
MakoHtmlLexer
r1282 | <div class="panel panel-default"> | |||
<div class="panel-heading"> | ||||
<h3 class="panel-title">${_('Default Permissions for Repositories, User Groups and Repository Groups.')}</h3> | ||||
</div> | ||||
<div class="panel-body"> | ||||
r2975 | <p> | |||
${_('Default access permissions. This defines permissions for the `default` user from which other users inherit permissions.')} | ||||
<br/> | ||||
${_('Check the overwrite checkbox to force change all previously defined permissions for `default` user to the new selected value.')} | ||||
r1282 | </p> | |||
r2105 | ${h.secure_form(h.route_path('admin_permissions_object_update'), request=request)} | |||
r1282 | <div class="form"> | |||
<div class="fields"> | ||||
<div class="field"> | ||||
<div class="label"> | ||||
<label for="default_repo_perm">${_('Repository')}:</label> | ||||
</div> | ||||
<div class="select"> | ||||
${h.select('default_repo_perm','',c.repo_perms_choices)} | ||||
${h.checkbox('overwrite_default_repo','true')} | ||||
<label for="overwrite_default_repo"> | ||||
<span class="tooltip" title="${h.tooltip(_('All default permissions on each repository will be reset to chosen permission, note that all custom default permission on repositories will be lost'))}"> | ||||
${_('Overwrite Existing Settings')} | ||||
</span> | ||||
</label> | ||||
</div> | ||||
</div> | ||||
<div class="field"> | ||||
<div class="label"> | ||||
<label for="default_group_perm">${_('Repository Groups')}:</label> | ||||
</div> | ||||
<div class="select"> | ||||
${h.select('default_group_perm','',c.group_perms_choices)} | ||||
${h.checkbox('overwrite_default_group','true')} | ||||
<label for="overwrite_default_group"> | ||||
<span class="tooltip" title="${h.tooltip(_('All default permissions on each repository group will be reset to chosen permission, note that all custom default permission on repository groups will be lost'))}"> | ||||
${_('Overwrite Existing Settings')} | ||||
</span> | ||||
</label> | ||||
</div> | ||||
</div> | ||||
<div class="field"> | ||||
<div class="label"> | ||||
<label for="default_group_perm">${_('User Groups')}:</label> | ||||
</div> | ||||
<div class="select"> | ||||
${h.select('default_user_group_perm','',c.user_group_perms_choices)} | ||||
${h.checkbox('overwrite_default_user_group','true')} | ||||
<label for="overwrite_default_user_group"> | ||||
r2975 | <span class="tooltip" title="${h.tooltip(_('All default permissions on each user group will be reset to chosen permission, note that all custom default permission on user groups will be lost'))}"> | |||
r1282 | ${_('Overwrite Existing Settings')} | |||
</span> | ||||
</label> | ||||
</div> | ||||
</div> | ||||
<div class="buttons"> | ||||
${h.submit('save',_('Save'),class_="btn")} | ||||
${h.reset('reset',_('Reset'),class_="btn")} | ||||
</div> | ||||
</div> | ||||
</div> | ||||
${h.end_form()} | ||||
</div> | ||||
</div> | ||||
<script> | ||||
$(document).ready(function(){ | ||||
var select2Options = { | ||||
containerCssClass: 'drop-menu', | ||||
dropdownCssClass: 'drop-menu-dropdown', | ||||
dropdownAutoWidth: true, | ||||
minimumResultsForSearch: -1 | ||||
}; | ||||
$("#default_repo_perm").select2(select2Options); | ||||
$("#default_group_perm").select2(select2Options); | ||||
$("#default_user_group_perm").select2(select2Options); | ||||
}); | ||||
</script> | ||||