Commit 082587cf authored by liboyang's avatar liboyang

二次确认身份加限制

parent d32f0593
......@@ -17,6 +17,10 @@
<td ng-if="item.SEX_NO==1"></td>
<td ng-if="item.SEX_NO==2"></td>
<td ng-if="item.SEX_NO==-1">错误</td>
<td ng-if="item.SPECIAL_TYPE==2">快证</td>
<td ng-if="item.SPECIAL_TYPE==1">余证</td>
<td ng-if="item.SPECIAL_TYPE==0">废证</td>
<td ng-if="item.SPECIAL_TYPE==3">退证</td>
</tr>
</tbody>
</table>
......
......@@ -8,6 +8,7 @@
<th>身份证号</th>
<th>姓名</th>
<th>性别</th>
<th>类型</th>
</thead>
<tbody>
<tr ng-repeat="item in personInfo">
......@@ -17,6 +18,10 @@
<td ng-if="item.SEX_NO==1"></td>
<td ng-if="item.SEX_NO==2"></td>
<td ng-if="item.SEX_NO==-1">错误</td>
<td ng-if="item.SPECIAL_TYPE==2">快证</td>
<td ng-if="item.SPECIAL_TYPE==1">余证</td>
<td ng-if="item.SPECIAL_TYPE==0">废证</td>
<td ng-if="item.SPECIAL_TYPE==3">退证</td>
</tr>
</tbody>
</table>
......
......@@ -17,6 +17,10 @@
<td ng-if="item.SEX_NO==1"></td>
<td ng-if="item.SEX_NO==2"></td>
<td ng-if="item.SEX_NO==-1">错误</td>
<td ng-if="item.SPECIAL_TYPE==2">快证</td>
<td ng-if="item.SPECIAL_TYPE==1">余证</td>
<td ng-if="item.SPECIAL_TYPE==0">废证</td>
<td ng-if="item.SPECIAL_TYPE==3">退证</td>
</tr>
</tbody>
</table>
......
......@@ -32,7 +32,7 @@ angular.module('AvatarCheck', [
$qProvider.errorOnUnhandledRejections(false)
}])
.controller('appCtrl', function ($scope, $location, $rootScope, HttpService, localStorageService, DebugService) {
.controller('appCtrl', function ($scope, $location, $rootScope, HttpService, localStorageService, DebugService,MessageService) {
DebugService.debug("appCtrl:" + "AvatarCheck initial.")
......@@ -172,6 +172,7 @@ angular.module('AvatarCheck', [
}else{
HttpService.searchCards(searchInput, function (data) {
if(data==''){
$scope.msg="";
$scope.alertMsg = "暂无数据";
}else{
$scope.searchResult = data;
......@@ -203,33 +204,79 @@ angular.module('AvatarCheck', [
}
$scope.addQuickCardAccu = function(){
var idx = $(".accu:checked").val();
var check = idx.split("+");
var json={};
json.acceptNo=check[0];
json.cardType=check[2];
json.countyCode=check[1];
json.name=$rootScope.loginData.name;
console.log(json)
HttpService.addSpecialCard(json,function (data) {
console.log($scope.searchInput)
$scope.doSearch($scope.searchInput)
})
if($(".accu:checked").length>0){
var idx = $(".accu:checked").val();
var check = idx.split("+");
var json={};
json.acceptNo=check[0];
json.cardType=check[2];
json.countyCode=check[1];
json.name=$rootScope.loginData.name;
console.log(json)
HttpService.addSpecialCard(json,function (data) {
MessageService.showAlert(data.msg)
$scope.doSearch($scope.searchInput)
})
}else{
MessageService.showAlert("请选择要添加的信息")
}
}
$scope.addQuickCardProd = function(){
var idx = $(".prod:checked").val();
var check = idx.split("+");
console.log(idx,check)
var json={};
json.acceptNo=check[0];
json.cardType=check[2];
json.countyCode=check[1];
json.name=$rootScope.loginData.name;
console.log(json)
HttpService.addSpecialCard(json,function (data) {
console.log($scope.searchInput)
$scope.doSearch($scope.searchInput)
})
if($(".prod:checked").length>0){
var idx = $(".prod:checked").val();
var check = idx.split("+");
console.log(idx,check)
var json={};
json.acceptNo=check[0];
json.cardType=check[2];
json.countyCode=check[1];
json.name=$rootScope.loginData.name;
console.log(json)
HttpService.addSpecialCard(json,function (data) {
MessageService.showAlert(data.msg)
$scope.doSearch($scope.searchInput)
})
}else{
MessageService.showAlert("请选择要添加快证的信息")
}
}
$scope.giveBackCardAccu = function () {
if($(".accu:checked").length>0){
var idx = $(".accu:checked").val();
var check = idx.split("+");
var json={};
json.acceptNo=check[0];
json.taskId=$scope.searchResult.workOrderDate[0].TASK_ID;
json.name=$rootScope.loginData.name;
console.log(json)
HttpService.giveBackCard(json,function (data) {
console.log(data)
MessageService.showAlert(data.msg)
$scope.doSearch($scope.searchInput)
})
}else{
MessageService.showAlert("请选择要退证的信息")
}
}
$scope.giveBackCardProd = function () {
if($(".prod:checked").length>0){
var idx = $(".prod:checked").val();
var check = idx.split("+");
var json={};
json.acceptNo=check[0];
json.taskId=$scope.searchResult.workOrderDate[0].TASK_ID;
json.name=$rootScope.loginData.name;
console.log(json)
HttpService.giveBackCard(json,function (data) {
console.log(data)
MessageService.showAlert(data.msg)
$scope.doSearch($scope.searchInput)
})
}else{
MessageService.showAlert("请选择要退证的信息")
}
}
......
......@@ -827,6 +827,17 @@ angular.module('AvatarCheck.http', ['ngDialog', 'LocalStorageModule'])
}).then(function successCallback(response) {
success(response.data)
})
},
giveBackCard:function(data,success) {
var body = JSON.stringify(data);
$http({
method: 'POST',
url: "../TaskList/addBackCard",
data: body,
headers: {'Content-Type': 'application/json'}
}).then(function successCallback(response) {
success(response.data)
})
}
}
});
\ No newline at end of file
......@@ -82,7 +82,7 @@ angular.module('AvatarCheck.addFailed', ['ngRoute', 'AvatarCheck.http'])
$scope.personInfo = data;
$scope.can = false;
for(var i=0;i<$scope.personInfo.length;i++){
if($scope.personInfo[i].SEX_NO==-1){
if($scope.personInfo[i].SEX_NO==-1||$scope.personInfo[i].SPECIAL_TYPE==0||$scope.personInfo[i].SPECIAL_TYPE==1||$scope.personInfo[i].SPECIAL_TYPE==2||$scope.personInfo[i].SPECIAL_TYPE==3){
$scope.can = true;
}
}
......
......@@ -58,7 +58,7 @@ angular.module('AvatarCheck.addRest', ['ngRoute', 'AvatarCheck.http'])
$scope.personInfo = data;
$scope.can = false;
for(var i=0;i<$scope.personInfo.length;i++){
if($scope.personInfo[i].SEX_NO==-1){
if($scope.personInfo[i].SEX_NO==-1||$scope.personInfo[i].SPECIAL_TYPE==0||$scope.personInfo[i].SPECIAL_TYPE==1||$scope.personInfo[i].SPECIAL_TYPE==2||$scope.personInfo[i].SPECIAL_TYPE==3){
$scope.can = true;
}
}
......
......@@ -75,7 +75,7 @@ angular.module('AvatarCheck.addTag', ['ngRoute', 'AvatarCheck.http'])
$scope.personInfo = data;
$scope.can = false;
for(var i=0;i<$scope.personInfo.length;i++){
if($scope.personInfo[i].SEX_NO==-1){
if($scope.personInfo[i].SEX_NO==-1||$scope.personInfo[i].SPECIAL_TYPE==0||$scope.personInfo[i].SPECIAL_TYPE==1||$scope.personInfo[i].SPECIAL_TYPE==2||$scope.personInfo[i].SPECIAL_TYPE==3){
$scope.can = true;
}
}
......
......@@ -76,7 +76,7 @@
</thead>
<tbody>
<tr ng-repeat="item in searchResult.ACCdata">
<td><input type="checkbox" value="{{item.ACCEPT_NO}}+{{item.COUNTY_CODE}}+{{item.CARD_TYPE_ID}}" class="accu"></td>
<td><input ng-checked="searchResult.ACCdata.length==1" type="checkbox" value="{{item.ACCEPT_NO}}+{{item.COUNTY_CODE}}+{{item.CARD_TYPE_ID}}" class="accu"></td>
<td>{{item.ACCEPT_NO}}</td>
<td>{{item.COUNTYNAME}}</td>
<td>{{item.NAME}}</td>
......@@ -96,7 +96,7 @@
</div>
<div style="text-align:right;padding: 10px;padding-top: 0;">
<button class="btn btn-info" ng-click="addQuickCardAccu()">添加快证</button>
<button class="btn btn-danger">退证</button>
<button class="btn btn-danger" ng-click="giveBackCardAccu()">退证</button>
</div>
</div>
<!--制证库-->
......@@ -127,7 +127,7 @@
</thead>
<tbody>
<tr ng-repeat="item in searchResult.PRODData">
<td><input type="checkbox" value="{{item.ACCEPT_NO}}+{{item.COUNTY_CODE}}+{{item.CARD_TYPE_ID}}" class="prod"></td>
<td><input ng-checked="searchResult.PRODData.length==1" type="checkbox" value="{{item.ACCEPT_NO}}+{{item.COUNTY_CODE}}+{{item.CARD_TYPE_ID}}" class="prod"></td>
<td>{{item.ACCEPT_NO}}</td>
<td>{{item.COUNTYNAME}}</td>
<td>{{item.NAME}}</td>
......@@ -147,14 +147,9 @@
</div>
<div style="text-align:right;padding: 10px;padding-top: 0;">
<button class="btn btn-info" ng-click="addQuickCardProd()">添加快证</button>
<button class="btn btn-danger">退证</button>
<button class="btn btn-danger" ng-click="giveBackCardAccu()">退证</button>
</div>
</div>
<h4>{{searchResult.workOrderDate}}</h4>
<h4>{{searchResult.workOrderDate.length}}</h4>
<h4>{{searchResult.ACCdata.length}}</h4>
<h4>{{searchResult.PRODData.length}}</h4>
<div ng-if="searchResult.workOrderDate.length==0&&searchResult.ACCdata.length==0&&searchResult.PRODData.length==0">
<h4>没有查询到相关信息</h4>
</div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment