mirror of
https://github.com/ansible/awx.git
synced 2026-05-17 06:17:36 -02:30
Merge pull request #5678 from jaredevantabor/read-role
filtering out READ roles from the RBAC modal
This commit is contained in:
@@ -18,7 +18,9 @@ export default ['$rootScope', '$scope', 'GetBasePath', 'Rest', '$q', 'Wait', 'Pr
|
|||||||
// the object permissions are being added to
|
// the object permissions are being added to
|
||||||
scope.object = scope.resourceData.data;
|
scope.object = scope.resourceData.data;
|
||||||
// array for all possible roles for the object
|
// array for all possible roles for the object
|
||||||
scope.roles = scope.object.summary_fields.object_roles;
|
scope.roles = _.omit(scope.object.summary_fields.object_roles, (key) => {
|
||||||
|
return key.name === 'Read';
|
||||||
|
});
|
||||||
|
|
||||||
// TODO: get working with api
|
// TODO: get working with api
|
||||||
// array w roles and descriptions for key
|
// array w roles and descriptions for key
|
||||||
|
|||||||
@@ -16,7 +16,6 @@ export default
|
|||||||
roles: '=',
|
roles: '=',
|
||||||
model: '='
|
model: '='
|
||||||
},
|
},
|
||||||
// @issue why is the read-only role ommited from this selection?
|
|
||||||
template: '<select ng-cloak class="AddPermissions-selectHide roleSelect2 form-control" ng-model="model" ng-options="role.name for role in roles track by role.id" multiple required></select>',
|
template: '<select ng-cloak class="AddPermissions-selectHide roleSelect2 form-control" ng-model="model" ng-options="role.name for role in roles track by role.id" multiple required></select>',
|
||||||
link: function(scope, element, attrs, ctrl) {
|
link: function(scope, element, attrs, ctrl) {
|
||||||
CreateSelect2({
|
CreateSelect2({
|
||||||
|
|||||||
Reference in New Issue
Block a user