在ng-repeat時,對於不同狀態的表格,會有顯示不同顏色的需求,使用ng-style即可,具體操作如下:
<td ng-style="{'color':room.State == '在線' ?'green':''}">{{room.State}}</td>
在這裏要注意的是:
- ng-style的內容要用{}包圍着
- color等屬性要加單引號‘’
- 屬性值也要加單引號‘’
在ng-repeat時,對於不同狀態的表格,會有顯示不同顏色的需求,使用ng-style即可,具體操作如下:
<td ng-style="{'color':room.State == '在線' ?'green':''}">{{room.State}}</td>
在這裏要注意的是:
## spring security https://github.com/jitwxs/blog-sample/tree/master
https://blog.csdn.net/zhuizhufanxin123/article/details/103982940