Reputation: 545
I have condition for ng-show if json response ratingStatusKey = RA_RT_EDITABLE show edit button. how i can achieve this using angularjs. So far i tried this..
grid.js
template: '<a href="" ng-click=\'editProcessRtng(this.dataItem)\'>`<span ng-show="{{ratingStatusKey}}!==RA_RT_EDITABLE" class="glyphicon glyphicon-pencil"></span></a>'`
Upvotes: 0
Views: 985
Reputation: 30661
Try removing the mustaches from ng-show
.
ng-show="ratingStatusKey!==RA_RT_EDITABLE"
You shouldn't use them in angular directives - only in regular DOM attributes. Also make sure RA_RT_EDITABLE
is defined in the global scope otherwise the comparison will fail.
Upvotes: 1