Fernando Toress Fernando Toress - 1 year ago 68
AngularJS Question

ng-hide with two condition not working properly

ng-hide="template.created_by == 4 && $cookieStore.get('custom_role') != 4"

The condition not work properly .I couldn't show the button even the both values (template.created_by,$cookieStore.get('custom_role')) are 4.

Answer Source

If both of the values are 4 - then your condition will be resolved to falase. Make sure that you can see template and $cookieStorage from html, like this:


If you don't see them - you will need to adjust your scope.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download