|
@@ -54,11 +54,16 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
54
|
54
|
}
|
55
|
55
|
})
|
56
|
56
|
// -----------------分割线 end----------------
|
57
|
|
- // 是否逾期seimin
|
|
57
|
+ // 是否逾期
|
58
|
58
|
$scope.selectType = [
|
59
|
59
|
{ id: '2', name: '是' },
|
60
|
60
|
{ id: '0', name: '否' }
|
61
|
61
|
];
|
|
62
|
+ // 是否直接处理
|
|
63
|
+ $scope.directProcess = [
|
|
64
|
+ { id: '1', name: '是' },
|
|
65
|
+ { id: '0', name: '否' }
|
|
66
|
+ ];
|
62
|
67
|
// /是否逾期
|
63
|
68
|
$scope.langs = i18nService.getAllLangs();
|
64
|
69
|
$scope.lang = 'zh-cn';
|
|
@@ -100,6 +105,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
100
|
105
|
|
101
|
106
|
$scope.gridOptions = {};
|
102
|
107
|
$scope.gridOptions.data = 'myData';
|
|
108
|
+ $scope.gridOptions.rowHeight = 54;
|
103
|
109
|
$scope.gridOptions.enableColumnResizing = true;
|
104
|
110
|
$scope.gridOptions.enableFiltering = false;
|
105
|
111
|
$scope.gridOptions.enableGridMenu = true;
|
|
@@ -217,77 +223,86 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
217
|
223
|
},
|
218
|
224
|
{
|
219
|
225
|
name: 'incidentsign',
|
220
|
|
- displayName: '事件单号',
|
|
226
|
+ displayName: '单号|源',
|
221
|
227
|
width: 120,
|
222
|
228
|
cellTemplate: '<div>' +
|
223
|
|
- '<div class="ui-grid-cell-contents">{{row.entity.incidentsign}}</div>' +
|
|
229
|
+ '<div class="ui-grid-cell-contents">{{row.entity.incidentsign||"无"}}<br>{{row.entity.source?row.entity.source.name:"无"}}</div>' +
|
224
|
230
|
'</div>'
|
225
|
231
|
},
|
226
|
232
|
{
|
227
|
233
|
name: 'requester.name',
|
228
|
234
|
displayName: '报修人',
|
229
|
|
- width: '6%',
|
230
|
|
- minWidth: '90',
|
231
|
|
- enableSorting: false,
|
232
|
|
- cellTemplate: '<div>' +
|
233
|
|
- '<div class="ui-grid-cell-contents" >{{row.entity.requester.name}}</div>' +
|
234
|
|
- '</div>'
|
235
|
|
- },
|
236
|
|
- {
|
237
|
|
- name: 'requester.account',
|
238
|
|
- displayName: '学工号',
|
239
|
|
- width: '6%',
|
|
235
|
+ width: '7%',
|
240
|
236
|
minWidth: '90',
|
241
|
237
|
enableSorting: false,
|
242
|
238
|
cellTemplate: '<div>' +
|
243
|
|
- '<div class="ui-grid-cell-contents" >{{row.entity.requester.account}}</div>' +
|
|
239
|
+ '<div class="ui-grid-cell-contents" >{{row.entity.requester?row.entity.requester.name:"无"}}<br>{{row.entity.requester?row.entity.requester.account:"无"}}</div>' +
|
244
|
240
|
'</div>'
|
245
|
241
|
},
|
|
242
|
+ // {
|
|
243
|
+ // name: 'requester.account',
|
|
244
|
+ // displayName: '学工号',
|
|
245
|
+ // width: '6%',
|
|
246
|
+ // minWidth: '90',
|
|
247
|
+ // enableSorting: false,
|
|
248
|
+ // cellTemplate: '<div>' +
|
|
249
|
+ // '<div class="ui-grid-cell-contents" >{{row.entity.requester.account}}</div>' +
|
|
250
|
+ // '</div>'
|
|
251
|
+ // },
|
246
|
252
|
{
|
247
|
253
|
name: 'contactsInformation',
|
248
|
|
- displayName: '联系电话',
|
249
|
|
- width: '105',
|
|
254
|
+ displayName: '联系人',
|
|
255
|
+ width: '12%',
|
250
|
256
|
cellTemplate: '<div>' +
|
251
|
|
- '<div class="ui-grid-cell-contents">{{row.entity.contactsInformation}}</div>' +
|
|
257
|
+ '<div class="ui-grid-cell-contents">{{row.entity.contacts||"无"}}<br>{{row.entity.contactsInformation||"无"}}</div>' +
|
252
|
258
|
'</div>'
|
253
|
259
|
},
|
254
|
260
|
{
|
255
|
261
|
name: 'category',
|
256
|
|
- displayName: '事件分类',
|
257
|
|
- width: '10%',
|
|
262
|
+ displayName: '分类|区域点',
|
|
263
|
+ width: '20%',
|
258
|
264
|
enableSorting: false,
|
259
|
265
|
cellTemplate: '<div>' +
|
260
|
|
- '<div class="ui-grid-cell-contents">{{row.entity.category.category}}</div>' +
|
|
266
|
+ '<div class="ui-grid-cell-contents">{{row.entity.allCategory||"无"}}<br>{{grid.appScope.areaplace(row.entity)}}</div>' +
|
261
|
267
|
'</div>'
|
262
|
268
|
},
|
263
|
|
- {
|
264
|
|
- name: 'houseNumber',
|
265
|
|
- displayName: '区域地点',
|
266
|
|
- width: '14%',
|
267
|
|
- enableFiltering: false,
|
268
|
|
- cellTemplate: '<div><div class="ui-grid-cell-contents">{{grid.appScope.areaplace(row.entity)}}</div></div>'
|
269
|
|
- },
|
|
269
|
+ // {{row.entity.category.category}}
|
|
270
|
+ // {
|
|
271
|
+ // name: 'houseNumber',
|
|
272
|
+ // displayName: '区域地点',
|
|
273
|
+ // width: '14%',
|
|
274
|
+ // enableFiltering: false,
|
|
275
|
+ // cellTemplate: '<div><div class="ui-grid-cell-contents">{{grid.appScope.areaplace(row.entity)}}</div></div>'
|
|
276
|
+ // },
|
270
|
277
|
{
|
271
|
278
|
name: 'acceptUser.name',
|
272
|
|
- displayName: '受理人',
|
|
279
|
+ displayName: '受理|处理人',
|
273
|
280
|
width: '7%',
|
274
|
281
|
minWidth: '80',
|
275
|
282
|
enableSorting: false,
|
276
|
283
|
cellTemplate: '<div>' +
|
277
|
|
- '<div class="ui-grid-cell-contents" >{{row.entity.acceptUser.name}}</div>' +
|
|
284
|
+ '<div class="ui-grid-cell-contents" >{{row.entity.acceptUser?row.entity.acceptUser.name:"无"}}<br>{{row.entity.handlingPersonnelUser?row.entity.handlingPersonnelUser.name:"无"}}</div>' +
|
278
|
285
|
'</div>'
|
279
|
286
|
},
|
280
|
287
|
{
|
281
|
288
|
name: 'acceptDate',
|
282
|
|
- displayName: '登记时间',
|
|
289
|
+ displayName: '登记|接单时间',
|
283
|
290
|
width: '10%',
|
284
|
291
|
minWidth: '140',
|
285
|
292
|
enableFiltering: false,
|
286
|
|
- cellTemplate: '<div><div class="ui-grid-cell-contents">{{grid.appScope.transferTime(row.entity.acceptDate)}}</div></div>'
|
|
293
|
+ cellTemplate: '<div><div class="ui-grid-cell-contents">{{grid.appScope.transferTime(row.entity.acceptDate)}}<br>{{row.entity.responseHandleTime||"无"}}</div></div>'
|
|
294
|
+ },
|
|
295
|
+ {
|
|
296
|
+ name: 'acceptDate1',
|
|
297
|
+ displayName: '解决时间',
|
|
298
|
+ width: '10%',
|
|
299
|
+ minWidth: '140',
|
|
300
|
+ enableFiltering: false,
|
|
301
|
+ cellTemplate: '<div><div class="ui-grid-cell-contents">{{row.entity.handleTime||"无"}}</div></div>'
|
287
|
302
|
},
|
288
|
303
|
{
|
289
|
304
|
name: 'groupORHandlerUser',
|
290
|
|
- displayName: '处理人/组',
|
|
305
|
+ displayName: '时时处理',
|
291
|
306
|
width: '10%',
|
292
|
307
|
enableFiltering: false,
|
293
|
308
|
cellTemplate: '<div>' +
|
|
@@ -298,7 +313,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
298
|
313
|
{
|
299
|
314
|
name: 'state.name',
|
300
|
315
|
displayName: '状态',
|
301
|
|
- width: '7%',
|
|
316
|
+ width: '5%',
|
302
|
317
|
minWidth: '70',
|
303
|
318
|
enableSorting: false,
|
304
|
319
|
cellTemplate: '<div>' +
|
|
@@ -308,13 +323,13 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
308
|
323
|
{
|
309
|
324
|
name: '操作',
|
310
|
325
|
enableSorting: false,
|
311
|
|
- width: 500,
|
|
326
|
+ width: 300,
|
312
|
327
|
cellTemplate: '<incidentoperator style="background-color:{{row.entity.colourInfo.rgb}}" item="row.entity" colobject="col">',
|
313
|
328
|
enableFiltering: false
|
314
|
329
|
},
|
315
|
330
|
];
|
316
|
331
|
if($scope.wxIncidentWithCmdb==1){
|
317
|
|
- let index = $scope.gridOptions.columnDefs.findIndex(v=>v.name == 'contactsInformation');
|
|
332
|
+ let index = $scope.gridOptions.columnDefs.findIndex(v=>v.name == 'category');
|
318
|
333
|
$scope.gridOptions.columnDefs.splice(index,0,{
|
319
|
334
|
name: 'assetId',
|
320
|
335
|
displayName: '资产',
|
|
@@ -846,6 +861,27 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
846
|
861
|
}
|
847
|
862
|
}
|
848
|
863
|
})
|
|
864
|
+ //事件来源 liaomingming
|
|
865
|
+ $scope.source = [];
|
|
866
|
+ api_wechatfile.getDictionary({
|
|
867
|
+ "type": "list",
|
|
868
|
+ "key": "incident_source"
|
|
869
|
+ }).then(function (response) {
|
|
870
|
+ if (response) {
|
|
871
|
+ if (response.status = 200) {
|
|
872
|
+ $scope.source = response;
|
|
873
|
+ if (sessionStorage.searchincident && JSON.parse(sessionStorage.getItem("searchincident")).incident && JSON.parse(sessionStorage.getItem("searchincident")).incident.source) {
|
|
874
|
+ angular.forEach($scope.source, function (item) {
|
|
875
|
+ if (item.id == JSON.parse(sessionStorage.getItem("searchincident")).incident.source.id) {
|
|
876
|
+ $scope.othcode = {
|
|
877
|
+ "source": item
|
|
878
|
+ };
|
|
879
|
+ }
|
|
880
|
+ })
|
|
881
|
+ }
|
|
882
|
+ }
|
|
883
|
+ }
|
|
884
|
+ })
|
849
|
885
|
if (sessionStorage.searchincident && JSON.parse(sessionStorage.getItem("searchincident")).incident) {
|
850
|
886
|
// angular.forEach($scope.state, function(item) {
|
851
|
887
|
// if (item.code == JSON.parse(sessionStorage.getItem("searchincident")).incident.statusId) {
|
|
@@ -906,12 +942,17 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
906
|
942
|
|
907
|
943
|
}
|
908
|
944
|
// 搜索
|
909
|
|
- $scope.chiceIncident = function (item, stateid) {
|
|
945
|
+ $scope.chiceIncident = function (item, stateid, sourceid) {
|
910
|
946
|
if (stateid && stateid.id) {
|
911
|
947
|
item.statusId = stateid.id;
|
912
|
948
|
} else {
|
913
|
949
|
item.statusId = undefined;
|
914
|
950
|
}
|
|
951
|
+ if (sourceid) {
|
|
952
|
+ item.source = sourceid;
|
|
953
|
+ } else {
|
|
954
|
+ item.source = undefined;
|
|
955
|
+ }
|
915
|
956
|
console.log(item)
|
916
|
957
|
|
917
|
958
|
var fildata = {};
|
|
@@ -954,10 +995,14 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
954
|
995
|
if(fildata.searchType === 'all'){
|
955
|
996
|
if(fildata.incident&&fildata.incident.selectType){
|
956
|
997
|
fildata.incident.selectType = fildata.incident.selectType.id;
|
|
998
|
+ }else if(fildata.incident&&fildata.incident.directProcess){
|
|
999
|
+ fildata.incident.directProcess = fildata.incident.directProcess.id;
|
957
|
1000
|
}
|
958
|
1001
|
}else{
|
959
|
1002
|
if(fildata.incident&&fildata.incident.selectType){
|
960
|
1003
|
delete fildata.incident.selectType;
|
|
1004
|
+ }else if(fildata.incident&&fildata.incident.directProcess){
|
|
1005
|
+ delete fildata.incident.directProcess;
|
961
|
1006
|
}
|
962
|
1007
|
}
|
963
|
1008
|
// /seimin
|
|
@@ -992,7 +1037,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
992
|
1037
|
getRequester();
|
993
|
1038
|
|
994
|
1039
|
//受理人,处理人
|
995
|
|
- var getUser = function (fieldatas, it) {
|
|
1040
|
+ function getUser(fieldatas, it) {
|
996
|
1041
|
api_user_data.fetchDataList('user', fieldatas).then(function (data) {
|
997
|
1042
|
// console.log(data);
|
998
|
1043
|
if (it == 1) {
|
|
@@ -1073,7 +1118,11 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
1073
|
1118
|
str += ' ' + (data.place ? (data.place.area ? data.place.area.area : ' ') : ' ');
|
1074
|
1119
|
str += ' ' + (data.place ? (data.place.place ? data.place.place : ' ') : ' ');
|
1075
|
1120
|
str += ' ' + (data.houseNumber ? data.houseNumber : ' ');
|
1076
|
|
- return str;
|
|
1121
|
+ if(str.trim()){
|
|
1122
|
+ return str;
|
|
1123
|
+ }else{
|
|
1124
|
+ return '无'
|
|
1125
|
+ }
|
1077
|
1126
|
// } else {
|
1078
|
1127
|
// return data.area.area + ' ' + data.place.place;
|
1079
|
1128
|
// }
|
|
@@ -2570,7 +2619,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2570
|
2619
|
$scope.isDisabledState = false;
|
2571
|
2620
|
}
|
2572
|
2621
|
$scope.searchstate = searchType;
|
2573
|
|
- $scope.chiceIncident($scope.searchkeys,$scope.othcode.state);
|
|
2622
|
+ $scope.chiceIncident($scope.searchkeys,$scope.othcode.state,$scope.othcode.source);
|
2574
|
2623
|
// console.log(defaultFilterData,'fanbu')
|
2575
|
2624
|
// if(defaultFilterData.incident){
|
2576
|
2625
|
// var lsObject = defaultFilterData.incident;
|
|
@@ -2609,16 +2658,15 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2609
|
2658
|
// $scope.jry_refresh()
|
2610
|
2659
|
// }, $rootScope.refreshTime);
|
2611
|
2660
|
}
|
2612
|
|
- // 是否逾期下拉框选择seimin
|
|
2661
|
+ // 是否逾期下拉框选择
|
2613
|
2662
|
$scope.selectTypeChange = function(){
|
2614
|
2663
|
console.log($scope.searchkeys.selectType,66666);
|
2615
|
2664
|
if(window.sessionStorage.getItem('isGoyuqi') == 'yes'){
|
2616
|
2665
|
$scope.searchkeys.selectType = {id:'2',name:'是'};
|
2617
|
|
- // window.sessionStorage.removeItem('isGoyuqi');//seimin
|
2618
|
2666
|
}
|
2619
|
2667
|
var ids = $scope.searchkeys.selectType.id
|
2620
|
2668
|
if(defaultFilterData.incident){
|
2621
|
|
- defaultFilterData.incident.selectType = ids;//seimin
|
|
2669
|
+ defaultFilterData.incident.selectType = ids;
|
2622
|
2670
|
}else{
|
2623
|
2671
|
defaultFilterData.incident = {
|
2624
|
2672
|
selectType:ids
|
|
@@ -2628,8 +2676,26 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2628
|
2676
|
console.log(defaultFilterData,2222)
|
2629
|
2677
|
$scope.onChange('all');
|
2630
|
2678
|
}
|
|
2679
|
+ // 是否直接解决下拉框选择
|
|
2680
|
+ $scope.selectDirectProcess = function(){
|
|
2681
|
+ console.log($scope.searchkeys.directProcess,66666);
|
|
2682
|
+ if(window.sessionStorage.getItem('isZhiJie') == 'yes'){
|
|
2683
|
+ $scope.searchkeys.directProcess = {id:'1',name:'是'};
|
|
2684
|
+ }
|
|
2685
|
+ var ids = $scope.searchkeys.directProcess.id
|
|
2686
|
+ if(defaultFilterData.incident){
|
|
2687
|
+ defaultFilterData.incident.directProcess = ids;
|
|
2688
|
+ }else{
|
|
2689
|
+ defaultFilterData.incident = {
|
|
2690
|
+ directProcess:ids
|
|
2691
|
+ };
|
|
2692
|
+ }
|
|
2693
|
+ defaultFilterData.searchType = 'all';
|
|
2694
|
+ console.log(defaultFilterData,2222)
|
|
2695
|
+ $scope.onChange('all');
|
|
2696
|
+ }
|
2631
|
2697
|
//获取列表数据
|
2632
|
|
- $scope.refreshData = function (style, filterData) {
|
|
2698
|
+ $scope.refreshData = async function (style, filterData) {
|
2633
|
2699
|
console.log(filterData,9090)
|
2634
|
2700
|
if (filterData && filterData.incident && filterData.incident.area) {
|
2635
|
2701
|
filterData.incident.place = {
|
|
@@ -2659,6 +2725,28 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2659
|
2725
|
$scope.searchkeys.acceptDateEnd = new Date();
|
2660
|
2726
|
filterData.incident = {acceptDate:moment().format('YYYY-MM-DD 00:00:00'),acceptDateEnd:moment().format('YYYY-MM-DD 23:59:59')};
|
2661
|
2727
|
sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2728
|
+ }else if($state.params.date.includes('to')){
|
|
2729
|
+ var startAndEndDate = $state.params.date.split('to');
|
|
2730
|
+ $scope.othcode = {};
|
|
2731
|
+ $scope.searchkeys.acceptDate = new Date(startAndEndDate[0]);
|
|
2732
|
+ $scope.searchkeys.acceptDateEnd = new Date(startAndEndDate[1]);
|
|
2733
|
+ filterData.incident = {acceptDate:startAndEndDate[0] + ' 00:00:00',acceptDateEnd: startAndEndDate[1] + ' 23:59:59'};
|
|
2734
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2735
|
+ }
|
|
2736
|
+ if($state.params.handUserId){
|
|
2737
|
+ delete $scope.searchkeys.handlingPersonnelUser;
|
|
2738
|
+ let response = await api_bpm_data.fetchData('user', $state.params.handUserId);
|
|
2739
|
+ if (response.status == 200) {
|
|
2740
|
+ $scope.handlingPersonnelUser = [response.data];
|
|
2741
|
+ $scope.searchkeys.handlingPersonnelUser = {id:response.data.id, name:response.data.name};
|
|
2742
|
+ filterData.incident.handlingPersonnelUser = {id:response.data.id, name:response.data.name};
|
|
2743
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2744
|
+ }else{
|
|
2745
|
+ $scope.handlingPersonnelUser = [];
|
|
2746
|
+ delete $scope.searchkeys.handlingPersonnelUser;
|
|
2747
|
+ delete filterData.incident.handlingPersonnelUser;
|
|
2748
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2749
|
+ }
|
2662
|
2750
|
}
|
2663
|
2751
|
if($state.params.state){
|
2664
|
2752
|
$scope.searchkeys.acceptDate = null;
|
|
@@ -2692,6 +2780,28 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2692
|
2780
|
$scope.searchkeys.acceptDateEnd = new Date();
|
2693
|
2781
|
filterData.incident = {acceptDate:moment().format('YYYY-MM-DD 00:00:00'),acceptDateEnd:moment().format('YYYY-MM-DD 23:59:59')};
|
2694
|
2782
|
sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2783
|
+ }else if($state.params.date.includes('to')){
|
|
2784
|
+ var startAndEndDate = $state.params.date.split('to');
|
|
2785
|
+ $scope.othcode = {};
|
|
2786
|
+ $scope.searchkeys.acceptDate = new Date(startAndEndDate[0]);
|
|
2787
|
+ $scope.searchkeys.acceptDateEnd = new Date(startAndEndDate[1]);
|
|
2788
|
+ filterData.incident = {acceptDate:startAndEndDate[0] + ' 00:00:00',acceptDateEnd: startAndEndDate[1] + ' 23:59:59'};
|
|
2789
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2790
|
+ }
|
|
2791
|
+ if($state.params.handUserId){
|
|
2792
|
+ delete $scope.searchkeys.handlingPersonnelUser;
|
|
2793
|
+ let response = await api_bpm_data.fetchData('user', $state.params.handUserId);
|
|
2794
|
+ if (response.status == 200) {
|
|
2795
|
+ $scope.handlingPersonnelUser = [response.data];
|
|
2796
|
+ $scope.searchkeys.handlingPersonnelUser = {id:response.data.id, name:response.data.name};
|
|
2797
|
+ filterData.incident.handlingPersonnelUser = {id:response.data.id, name:response.data.name};
|
|
2798
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2799
|
+ }else{
|
|
2800
|
+ $scope.handlingPersonnelUser = [];
|
|
2801
|
+ delete $scope.searchkeys.handlingPersonnelUser;
|
|
2802
|
+ delete filterData.incident.handlingPersonnelUser;
|
|
2803
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2804
|
+ }
|
2695
|
2805
|
}
|
2696
|
2806
|
if($state.params.state){
|
2697
|
2807
|
$scope.searchkeys.acceptDate = null;
|
|
@@ -2722,7 +2832,18 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2722
|
2832
|
selectType : '2'
|
2723
|
2833
|
}
|
2724
|
2834
|
}
|
2725
|
|
- window.sessionStorage.removeItem('isGoyuqi');//seimin
|
|
2835
|
+ window.sessionStorage.removeItem('isGoyuqi');
|
|
2836
|
+ }
|
|
2837
|
+ if(window.sessionStorage.getItem('isZhiJie') == 'yes'){
|
|
2838
|
+ $scope.searchkeys.directProcess = {id:'21',name:'是'};
|
|
2839
|
+ if(filterData.incident&&filterData.incident.directProcess){
|
|
2840
|
+ filterData.incident.directProcess = '1';
|
|
2841
|
+ }else{
|
|
2842
|
+ filterData.incident = {
|
|
2843
|
+ directProcess : '1'
|
|
2844
|
+ }
|
|
2845
|
+ }
|
|
2846
|
+ window.sessionStorage.removeItem('isZhiJie');
|
2726
|
2847
|
}
|
2727
|
2848
|
$scope.myData = [];
|
2728
|
2849
|
sessionStorage['searchincident'] = angular.copy(JSON.stringify(filterData));
|
|
@@ -2759,7 +2880,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2759
|
2880
|
$scope.ldloading[style.replace('-', '_')] = false;
|
2760
|
2881
|
});
|
2761
|
2882
|
};
|
2762
|
|
- $scope.refreshData2 = function (style, filterData) {
|
|
2883
|
+ $scope.refreshData2 = async function (style, filterData) {
|
2763
|
2884
|
$scope.ldloading[style.replace('-', '_')] = true;
|
2764
|
2885
|
if (angular.isUndefined(filterData)) {
|
2765
|
2886
|
if (sessionStorage.searchincident) {
|
|
@@ -2782,6 +2903,28 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2782
|
2903
|
$scope.searchkeys.acceptDateEnd = new Date();
|
2783
|
2904
|
filterData.incident = {acceptDate:moment().format('YYYY-MM-DD 00:00:00'),acceptDateEnd:moment().format('YYYY-MM-DD 23:59:59')};
|
2784
|
2905
|
sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2906
|
+ }else if($state.params.date.includes('to')){
|
|
2907
|
+ var startAndEndDate = $state.params.date.split('to');
|
|
2908
|
+ $scope.othcode = {};
|
|
2909
|
+ $scope.searchkeys.acceptDate = new Date(startAndEndDate[0]);
|
|
2910
|
+ $scope.searchkeys.acceptDateEnd = new Date(startAndEndDate[1]);
|
|
2911
|
+ filterData.incident = {acceptDate:startAndEndDate[0] + ' 00:00:00',acceptDateEnd: startAndEndDate[1] + ' 23:59:59'};
|
|
2912
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2913
|
+ }
|
|
2914
|
+ if($state.params.handUserId){
|
|
2915
|
+ delete $scope.searchkeys.handlingPersonnelUser;
|
|
2916
|
+ let response = await api_bpm_data.fetchData('user', $state.params.handUserId);
|
|
2917
|
+ if (response.status == 200) {
|
|
2918
|
+ $scope.handlingPersonnelUser = [response.data];
|
|
2919
|
+ $scope.searchkeys.handlingPersonnelUser = {id:response.data.id, name:response.data.name};
|
|
2920
|
+ filterData.incident.handlingPersonnelUser = {id:response.data.id, name:response.data.name};
|
|
2921
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2922
|
+ }else{
|
|
2923
|
+ $scope.handlingPersonnelUser = [];
|
|
2924
|
+ delete $scope.searchkeys.handlingPersonnelUser;
|
|
2925
|
+ delete filterData.incident.handlingPersonnelUser;
|
|
2926
|
+ sessionStorage.setItem("searchincident",JSON.stringify(filterData));
|
|
2927
|
+ }
|
2785
|
2928
|
}
|
2786
|
2929
|
if($state.params.state){
|
2787
|
2930
|
$scope.searchkeys.acceptDate = null;
|
|
@@ -2854,9 +2997,20 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
|
2854
|
2997
|
$scope.searchkeys.selectType = {id:'0',name:'否'};
|
2855
|
2998
|
}
|
2856
|
2999
|
}
|
|
3000
|
+ if(varLin.incident&&varLin.incident.directProcess){
|
|
3001
|
+ if(varLin.incident.directProcess == '1'){
|
|
3002
|
+ console.log(defaultFilterData)
|
|
3003
|
+ $scope.searchkeys.directProcess = {id:'1',name:'是'};
|
|
3004
|
+ }else if(varLin.incident.directProcess == '0'){
|
|
3005
|
+ console.log(defaultFilterData)
|
|
3006
|
+ $scope.searchkeys.directProcess = {id:'0',name:'否'};
|
|
3007
|
+ }
|
|
3008
|
+ }
|
2857
|
3009
|
}
|
2858
|
3010
|
if(window.sessionStorage.getItem('isGoyuqi') === 'yes'){
|
2859
|
3011
|
$scope.selectTypeChange();
|
|
3012
|
+ }else if(window.sessionStorage.getItem('isZhiJie') === 'yes'){
|
|
3013
|
+ $scope.selectDirectProcess();
|
2860
|
3014
|
}else{
|
2861
|
3015
|
if(sessionStorage.getItem("searchincident")){
|
2862
|
3016
|
var ss = JSON.parse(sessionStorage.getItem("searchincident"));
|
|
@@ -2878,7 +3032,7 @@ app.controller('IncidentOperCtrl', ['$rootScope', '$http', '$scope', '$modal', '
|
2878
|
3032
|
// console.log('$rootScope.user3='+JSON.stringify($scope.item));
|
2879
|
3033
|
// console.log($scope.item)
|
2880
|
3034
|
var loginUser = $rootScope.user;
|
2881
|
|
- console.log(loginUser.role)
|
|
3035
|
+ // console.log(loginUser.role)
|
2882
|
3036
|
$scope.chuli = false;
|
2883
|
3037
|
$scope.qiangdan = false;
|
2884
|
3038
|
$scope.dayin = false;
|
|
@@ -2958,7 +3112,7 @@ app.controller('IncidentOperCtrl', ['$rootScope', '$http', '$scope', '$modal', '
|
2958
|
3112
|
|
2959
|
3113
|
//修改页面显示判断
|
2960
|
3114
|
$scope.jry_modify = function (item) {
|
2961
|
|
- console.log(item)
|
|
3115
|
+ // console.log(item)
|
2962
|
3116
|
// var jry_role = false;
|
2963
|
3117
|
// for (var i = 0; i < $rootScope.user.role.length; i++) {
|
2964
|
3118
|
// if ($rootScope.user.role[i].rolecode == "call center") {
|
|
@@ -3122,17 +3276,17 @@ app.directive('incidentoperator', function () {
|
3122
|
3276
|
colobject: '='
|
3123
|
3277
|
},
|
3124
|
3278
|
controller: 'IncidentOperCtrl',
|
3125
|
|
- template: '<div><div class="cl-effect-1 ui-grid-cell-contents pull-left" >' +
|
|
3279
|
+ template: '<div><div class="cl-effect-1 ui-grid-cell-contents pull-left" style="text-align:left;" >' +
|
3126
|
3280
|
// '<a ng-click="look()" tooltip="查看" tooltip-placement="left"><i class="ti-eye"></i></a>'+
|
3127
|
3281
|
'<a ng-click="toDetail(item)" class="bianjifont" >查看</a>' +
|
3128
|
|
- '<a ng-click="edit()" ng-show="{{item.chaozuoPower&&chuli}}" class="bianjifont">处理</a>' +
|
|
3282
|
+ '<a ng-click="changeCenter()" ng-show="jry_modify(item)" class="luyinfont">编辑</a>' +
|
|
3283
|
+ '<a ng-click="print()" ng-show="dayin" class="bianjifont" >打印</a>' +
|
|
3284
|
+ '<a ng-click="delSj()" ng-show="{{delFlag&&item.state.value!== \'deleted\'}}" class="assign" >删除</a>' +
|
|
3285
|
+ '<a ng-click="edit()" ng-show="{{item.chaozuoPower&&chuli}}" class="bianjifont">处理</a><br>' +
|
3129
|
3286
|
'<a ng-click="handler()" ng-show="{{item.state.id != 1546 &&!item.handlerUser&&item.tiquPower&&qiangdan}}" class="bianjifont" >抢单</a>' +
|
3130
|
3287
|
'<a ng-click="visit()" ng-show="{{item.huifang&&huifang}}" class="bianjifont">回访</a>' +
|
3131
|
|
- '<a ng-click="changeCenter()" ng-show="jry_modify(item)" class="luyinfont">编辑</a>' +
|
3132
|
3288
|
'<a ng-click="toAssign()" ng-show="{{(item.state.id==1543||item.state.id==1544)&&assignFlag&&item.assignee}}" class="assign" >指派</a>' +
|
3133
|
3289
|
'<a ng-click="toHandlerLog()" ng-show="{{item.state.id==1544}}" class="assign" >新增处理日志</a>' +
|
3134
|
|
- '<a ng-click="delSj()" ng-show="{{delFlag&&item.state.value!== \'deleted\'}}" class="assign" >删除</a>' +
|
3135
|
|
- '<a ng-click="print()" ng-show="dayin" class="bianjifont" >打印</a>' +
|
3136
|
3290
|
// '<a ng-click="jry_evaluate()" ng-show="jry_evaluateShow()" class="luyinfont" >评价</a>' +
|
3137
|
3291
|
// '<a ng-click="record()" ng-show="{{item.listen}}" class="luyinfont" >录音</a>' +
|
3138
|
3292
|
// '<a ng-click="rotate()" ng-show="{{item.state.id==4}}" class="rotate" >转派</a>' +
|