Commit 92d6d24c authored by liboyang's avatar liboyang

分拣转出任务单弹框bug

parent 22e694ae
...@@ -724,58 +724,56 @@ angular.module('AvatarCheck.task', ['ngRoute', 'AvatarCheck.http']) ...@@ -724,58 +724,56 @@ angular.module('AvatarCheck.task', ['ngRoute', 'AvatarCheck.http'])
} }
$scope.goes = function(){ $scope.goes = function(){
var checks = $(".checkOneBox:checked"); $rootScope.selectCount = 0;
if(checks.length>0){ for (var i = 0; i < $scope.selected.length; i++) {
var go = function () { $rootScope.selectCount =$rootScope.selectCount + parseInt($scope.selected[i].countyValidCount-$scope.selected[i].specialCount);
$rootScope.closeBtn(); }
$rootScope.selectCount = 0; console.log("for",$rootScope.selectCount)
for (var i = 0; i < $scope.selected.length; i++) { var go = function () {
$rootScope.selectCount =$rootScope.selectCount + parseInt($scope.selected[i].countyValidCount-$scope.selected[i].specialCount); $rootScope.closeBtn();
} var checks = $(".checkOneBox:checked");
console.log("for",$rootScope.selectCount) if(checks.length>0){
var arr = []; var arr = [];
var failedArr=[]; var failedArr=[];
for (var i=0;i<checks.length;i++){ for (var i=0;i<checks.length;i++){
if(checks[i].value.length<11){ if(checks[i].value.length<11){
failedArr.push(checks[i].value) failedArr.push(checks[i].value)
}else{ }else{
arr.push(checks[i].value) arr.push(checks[i].value)
}
}
var json={
process:$rootScope.loginData.roleList[0].process,
name:$rootScope.loginData.name,
taskIdList:arr,
failedList:failedArr
} }
console.log(json) }
HttpService.updateTaskListProcess(json,function(data){ var json={
$scope.searchTaskList(); process:$rootScope.loginData.roleList[0].process,
$scope.selected=[]; name:$rootScope.loginData.name,
$rootScope.ableBtn(); taskIdList:arr,
$rootScope.closeThis(); failedList:failedArr
}) }
console.log(json)
HttpService.updateTaskListProcess(json,function(data){
$scope.searchTaskList();
$scope.selected=[];
$rootScope.ableBtn();
$rootScope.closeThis();
})
}else{
MessageService.showAlert("请选择转出的任务单");
} }
ngDialog.open({
template: 'dialogs/gotoDistribute.html' + urlTimeStamp(),
width: 800,
cache: false,
closeByDocument:false,
controller: ['$scope', 'HttpService',function ($scope) {
$rootScope.closeThis=$scope.closeThisDialog;
$rootScope.ableBtn = function(){
$(".create").prop("disabled","false");
}
$rootScope.closeBtn = function(){
$(".create").prop("disabled","true");
}
$scope.confirmGoTo = go;
}]
})
}else{
MessageService.showAlert("请选择转出的任务单");
} }
ngDialog.open({
template: 'dialogs/gotoDistribute.html' + urlTimeStamp(),
width: 800,
cache: false,
closeByDocument:false,
controller: ['$scope', 'HttpService',function ($scope) {
$rootScope.closeThis=$scope.closeThisDialog;
$rootScope.ableBtn = function(){
$(".create").prop("disabled","false");
}
$rootScope.closeBtn = function(){
$(".create").prop("disabled","true");
}
$scope.confirmGoTo = go;
}]
})
} }
}) })
\ No newline at end of file
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