我基本上是角度的新手,在这里我寻求帮助。我一直在谷歌周围寻找答案,但我不能。
所以这里是我的代码。
<tr valign="top" ng-repeat="tech in techies.result">
<td>{{tech.user_id}}</td>
<td>{{tech.account}}</td>
<td ng-switch on="tech.ctr">
<div ng-switch-when="1">
<div ng-switch on="tech.account">
<div ng-switch-when="account.account">
<a href="#">Cancel</a>
</div>
</div>
</div>
<div ng-switch-when="0">
<a href="#">Assign</a>
</div>
</td>
</tr>
“取消”链接不会显示在嵌套的 ng-switch 上
ng-switch-when="account.account"
但是当我将“account.account”替换为文字值时会出现
ng-switch-when="A0011"
编辑
我忘了添加一些值
我的桌子是这样的:
当前帐户值为 A00002
TID0001 | | Assign //if account blank, appear assign
TID0002 | | Assign //if account blank, appear assign
TID0003 | A00011 | //no action if already assigned to another account
TID0004 | A00002 | Cancel //should appear here the cancel if the same account value
有什么提示吗?任何帮助深表感谢。
谢谢你。