0

Im new with Angular JS

And im trying to add an attribute to a table if an ng-if is false,

I want to add a "ui:sortable" if my function "onlyRead()" is false.

How can I do it?

Thanks for the help.

030
  • 10,842
  • 12
  • 78
  • 123
Nega developer
  • 259
  • 3
  • 8
  • 19
  • You can look into `ng-attr` with an expression. [Here](http://stackoverflow.com/questions/15696416/what-is-the-best-way-to-conditionally-apply-attributes-in-angular) is an SO post on `ng-attr`. – area28 Jun 22 '15 at 13:08
  • 1
    It would be more easy to answer your question if you show us the valid pieces of your code.. – Guinn Jun 22 '15 at 13:11
  • Yes, I'm sorry, here an example. http://jsfiddle.net/vz6b13zn/1/ I'm just trying to add ui:sortable to the tbody when OnlyRead is false – Nega developer Jun 22 '15 at 13:36

0 Answers0