Commit 949cdab0 authored by liboyang's avatar liboyang

打印封条

parent 552a0b61
......@@ -870,6 +870,17 @@ angular.module('AvatarCheck.http', ['ngDialog', 'LocalStorageModule'])
}).then(function successCallback(response) {
success(response.data)
})
},
printReceitpData:function(data,success) {
var body = JSON.stringify(data);
$http({
method: 'POST',
url: "../exportExcel/printReceiptExcelData",
data: body,
headers: {'Content-Type': 'application/json'}
}).then(function successCallback(response) {
success(response.data)
})
}
}
});
\ No newline at end of file
......@@ -45,7 +45,7 @@
</thead>
<tbody ng-repeat="item in type.countyList">
<tr style="background-color: #eee">
<td><input type="checkbox" class="checkAllPolice" ng-click="checkAllPolice($event,item.countyCode)"></td>
<td><input type="checkbox" class="checkAllPolice" value="{{item.policeList}}" ng-click="checkAllPolice($event,item.countyCode)"></td>
<td></td>
<td>{{item.countyCode}}</td>
<td style="color: #3c8dbc">{{item.countyName}}</td>
......@@ -55,7 +55,7 @@
</tr>
<tr ng-repeat="police in item.policeList">
<td></td>
<td>{{$index+1}}</td>
<td>{{police.ID}}</td>
<td>{{police.GAJG_DM}}</td>
<td>{{police.GAJG_MC}}</td>
<td>{{police.FINISH_COUNT}}</td>
......@@ -67,9 +67,12 @@
<!-- /.table -->
</div>
<!-- /.table -->
<div class="box-footer" style="text-align: right;">
<button class="btn btn-primary" ng-click="goes()">下发任务单</button>
</div>
<div class="box-footer" ng-if="receitpData.length>0">
<div class="pull-right" style="margin-left: 10px;">
<button class="btn btn-primary" ng-click="printReceitp(type.typeCode)">打印交接单</button>
<button class="btn btn-primary" ng-click="downloadGAinfo()">下载公安网反馈信息</button>
</div>
</div>
</div>
</div>
<div ng-if="receitpData.length==0">
......
......@@ -74,16 +74,21 @@ angular.module('AvatarCheck.receitp', ['ngRoute', 'AvatarCheck.http'])
}
}
// $scope.checkAllPolice = function($event,countyCode) {
// var checkAllPolice = $event.target;
// var checkPolice =$(".checkPolice"+countyCode);
// for (var i=0;i<checkPolice.length;i++){
// if(checkAllPolice.checked) {
// checkPolice[i].checked = true;
// }else {
// checkPolice[i].checked = false;
// }
// }
// }
$scope.printReceitp = function(typeCode) {
var date = $('#datepicker').val();
var json={
type:typeCode,
date:date,
list:[]
}
var checks = $(".checkAllPolice:checked")
for (var i=0;i<checks.length;i++){
for(var j=0;j<JSON.parse(checks[i].value).length;j++){
json.list.push(JSON.parse(checks[i].value)[j].ID)
}
}
console.log(json)
HttpService.printReceitpData(json,function (data) {})
}
});
\ 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