0
我有表包含行,并在一列中我有两个按钮批准和拒绝,问题是拒绝按钮只有在批准按钮后才有效。如果我点击拒绝按钮,它不会在第一时间工作。 这是我的代码。在AngularJS中的第一个按钮点击不起作用
<tr ng-repeat="item in userRequests">
<td style="border: 1px solid #435363;">{{$index + 1 }}</td>
<td style="border: 1px solid #435363;">{{item.email_id}}</td>
<td ng-if="item.request_status == 0 && item.is_active == null" style="border: 1px solid #435363;">valid till: <input type="text" datepicker ng-model="validate" style="vertical-align: top;" /> <span><button type="button" style = "margin-left: 4px;margin-right: 4px;" class="btn btn-primary btn-xs" ng-click="approveUser(item.email_id,validate)">Approve</button></span>
<span><button type="button" class="btn btn-primary btn-xs" ng-click="rejectUser(item.email_id)">Reject</button></span></td>
</tr>
我无法理解哪些东西停止按钮来调用第一次点击的功能。 please see the pic by clicking here the view of table
你可以把console.log放在函数approveUser中,并拒绝用户并评论其余的功能并检查它是否被调用? ,我相信问题是在功能不是这个代码 –
实际上拒绝按钮的作品后,我点击审批按钮 – Rajat
我知道,但你试过我建议,看看它是否点击它是否没有功能回应? –