check for permissions before displaying trigger button
This commit is contained in:
parent
cb01f58f4d
commit
b79b711e40
|
@ -53,9 +53,13 @@ BranchRowComponent = Ember.Component.extend
|
||||||
|
|
||||||
canTrigger: (->
|
canTrigger: (->
|
||||||
if !@get('auth.signedIn')
|
if !@get('auth.signedIn')
|
||||||
return false
|
false
|
||||||
else
|
else
|
||||||
|
permissions = @get('auth.currentUser.permissions')
|
||||||
|
if permissions.contains parseInt(@get('build.repository.id'))
|
||||||
true
|
true
|
||||||
|
else
|
||||||
|
false
|
||||||
).property()
|
).property()
|
||||||
|
|
||||||
triggerBuild: (->
|
triggerBuild: (->
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
.build-status a,
|
.build-status a,
|
||||||
.tile-header,
|
.tile-header,
|
||||||
.tile-header a,
|
.tile-header a,
|
||||||
a
|
.tile-title a
|
||||||
color: $color
|
color: $color
|
||||||
|
|
||||||
@include colorStatusIcons($color, $status)
|
@include colorStatusIcons($color, $status)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user