我想要在表格中重新排列行的功能(使用拖放操作排序行). 行排列的索引也应该在模型中改变.
我怎样才能做类似的事情:http://jsfiddle.net/tzYbU/1162/ 使用Angular Directive?
我正在生成表格:
<table id="sort" class="table table-striped table-bordered">
<thead>
<tr>
<th class="header-color-green"></th>
<th ng-repeat="titles in Rules.Titles">{{titles.title}}</th>
</tr>
</thead>
<tbody ng-repeat="rule in Rules.data">
<tr>
<td class="center"><span>{{rule.ruleSeq}}</span></td>
<td ng-repeat="data in rule.ruleData">{{statusArr[data.value]}}</td>
</tr>
</tbody>
</table>
Run Code Online (Sandbox Code Playgroud) 我想在表中实现一个功能,用户可以通过单击它来设置单元格的值.可以说3-4个状态,也是附加到它的ng模型.
我在angularjs中查找了切换按钮,但它们仅仅是开/关类型.
简而言之; 单击该按钮将值设置为:活动,非活动,排除寻找具有多个状态的解决方案.任何帮助都非常感谢.