1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-01 08:21:15 +03:00

Merge pull request #2678 from leigh-johnson/2676

Restyle read-only labels, apply read-only label styles when user cannot edit job template
This commit is contained in:
Leigh Johnson 2016-06-29 09:23:19 -04:00 committed by GitHub
commit 6a6081dcf7
2 changed files with 6 additions and 4 deletions

View File

@ -18,8 +18,8 @@
padding: 2px 10px;
margin: 4px 0px;
font-size: 12px;
color: @default-bg;
background-color: @default-link;
color: @default-interface-txt;
background-color: @default-list-header-bg;
margin-right: 5px;
max-width: 100%;
white-space: nowrap;
@ -42,6 +42,8 @@
}
.LabelList-tag--deletable {
color: @default-bg;
background-color: @default-link;
margin-right: 0px;
border-top-left-radius: 0px;
border-bottom-left-radius: 0px;

View File

@ -1,10 +1,10 @@
<div class="LabelList-tagContainer" ng-repeat="label in labels">
<div class="LabelList-deleteContainer"
ng-click="deleteLabel(job_template.id, job_template.name, label.id, label.name)"
ng-show="showDelete">
ng-show="showDelete && job_template.summary_fields.can_edit">
<i class="fa fa-times LabelList-tagDelete"></i>
</div>
<div class="LabelList-tag" ng-class="{'LabelList-tag--deletable' : showDelete}">
<div class="LabelList-tag" ng-class="{'LabelList-tag--deletable' : (showDelete && job_template.summary_fields.can_edit)}">
<span class="LabelList-name">{{ label.name }}</span>
</div>
</div>