|
|
@@ -1,5 +1,6 @@
|
|
1
|
1
|
package api.controller.order;
|
|
2
|
2
|
|
|
|
3
|
+import api.controller.system.WorkroderTypeController;
|
|
3
|
4
|
import api.entity.database.call.CallLog;
|
|
4
|
5
|
import api.entity.database.call.Record;
|
|
5
|
6
|
import api.entity.database.order.WorkOrderOperateLog;
|
|
|
@@ -69,6 +70,9 @@ public class WorkOrderBaseController extends BaseController {
|
|
69
|
70
|
@Autowired
|
|
70
|
71
|
private ISysAccessoriesService sysaccessoriesService;
|
|
71
|
72
|
|
|
|
73
|
+ @Autowired
|
|
|
74
|
+ private IWorkroderTypeService workrodertypeService;
|
|
|
75
|
+
|
|
72
|
76
|
//待交办1 ; 待接单(没有处理人的时候)2; 待处理3; 待审核 4 ;待回访5 ;已完结6;
|
|
73
|
77
|
@ApiOperation("列表 listType 0 综合查询列表 1(处理人)我的待处理;2 待交办;3 已办待审核;4 已办待回访;5 我的回复列表;6 组内工单")
|
|
74
|
78
|
@Log(title = "查询wo_workorderbase列表", businessType = BusinessType.QUERY)
|
|
|
@@ -210,13 +214,20 @@ public class WorkOrderBaseController extends BaseController {
|
|
210
|
214
|
qw.set(CallLog::getWorkordercode, ordercode);
|
|
211
|
215
|
calllogService.updateBatch(qw);
|
|
212
|
216
|
}
|
|
|
217
|
+
|
|
|
218
|
+ String dealContent="";
|
|
|
219
|
+ if(!StringHelper.isEmpty(input.getResult())){
|
|
|
220
|
+ dealContent=",回复内容:"+input.getResult();
|
|
|
221
|
+
|
|
|
222
|
+ }
|
|
213
|
223
|
if (result) {
|
|
214
|
224
|
//添加操作日志
|
|
215
|
225
|
if (input.getIsend() == 0) {
|
|
216
|
226
|
boolean logresult = addlog("创建了工单", "创建", CurrentUser().getUserName(), input.getWorkordercode(), CurrentUser().getNickName(), "");
|
|
217
|
227
|
} else {
|
|
218
|
228
|
//结束了 已完成
|
|
219
|
|
- boolean logresult = addlog("创建并完成了工单", "创建并完成", CurrentUser().getUserName(), input.getWorkordercode(), CurrentUser().getNickName(), "");
|
|
|
229
|
+
|
|
|
230
|
+ boolean logresult = addlog("创建并完成了工单"+dealContent, "创建并完成", CurrentUser().getUserName(), input.getWorkordercode(), CurrentUser().getNickName(), "");
|
|
220
|
231
|
}
|
|
221
|
232
|
|
|
222
|
233
|
//判断手机号存在不customer,不存在就添加新用户
|
|
|
@@ -291,10 +302,14 @@ public class WorkOrderBaseController extends BaseController {
|
|
291
|
302
|
qw.set(WorkOrderBase::getFile,input.getFile());
|
|
292
|
303
|
|
|
293
|
304
|
}
|
|
|
305
|
+ String dealContent="";
|
|
|
306
|
+ if(!StringHelper.isEmpty(input.getResult())){
|
|
|
307
|
+ dealContent=",回复内容:"+input.getResult();
|
|
294
|
308
|
|
|
|
309
|
+ }
|
|
295
|
310
|
boolean result = workorderbaseService.updateBatch(qw);
|
|
296
|
311
|
if (result) {
|
|
297
|
|
- boolean logresult = addlog("处理了工单," + input.getResult(), "处理", CurrentUser().getUserName(), orderBase.getWorkordercode(), CurrentUser().getNickName(), input.getFile());
|
|
|
312
|
+ boolean logresult = addlog("处理了工单," + dealContent, "处理", CurrentUser().getUserName(), orderBase.getWorkordercode(), CurrentUser().getNickName(), input.getFile());
|
|
298
|
313
|
|
|
299
|
314
|
return Success("处理成功");
|
|
300
|
315
|
} else {
|
|
|
@@ -415,8 +430,11 @@ public class WorkOrderBaseController extends BaseController {
|
|
415
|
430
|
ov.setProjectname(dicdata.getDictLabel());
|
|
416
|
431
|
}
|
|
417
|
432
|
if (orderBase.getWorkordercate() > 0) {
|
|
418
|
|
- DictData dicdata = dictDataService.getEntity(orderBase.getWorkordercate());
|
|
419
|
|
- ov.setWorkordercatename(dicdata.getDictLabel());
|
|
|
433
|
+ WorkroderType ordertype = workrodertypeService.getEntity(orderBase.getWorkordercate() );
|
|
|
434
|
+ if(ordertype!=null){
|
|
|
435
|
+ ov.setWorkordercatename(ordertype.getTypeName());
|
|
|
436
|
+ }
|
|
|
437
|
+
|
|
420
|
438
|
}
|
|
421
|
439
|
//待交办1 ; 待接单(没有处理人的时候)2; 待处理3; 待审核 4 ;待回访5 ;已完结6;
|
|
422
|
440
|
|
|
|
@@ -466,6 +484,7 @@ public class WorkOrderBaseController extends BaseController {
|
|
466
|
484
|
@ApiOperation("交办 Dealuser不是必填,Dealdept 必填")
|
|
467
|
485
|
@Log(title = "转派wo_workorderbase", businessType = BusinessType.UPDATE)
|
|
468
|
486
|
@PutMapping("/transfer")
|
|
|
487
|
+ @Anonymous
|
|
469
|
488
|
public AjaxResult transfer(@RequestBody TransOrderInput input) {
|
|
470
|
489
|
Date currentDate = new Date(System.currentTimeMillis());
|
|
471
|
490
|
|
|
|
@@ -688,7 +707,10 @@ public class WorkOrderBaseController extends BaseController {
|
|
688
|
707
|
//工单状态改成交办1
|
|
689
|
708
|
qw.set(WorkOrderBase::getWorkorderstate, 3);
|
|
690
|
709
|
qw.set(WorkOrderBase::getDealuser, CurrentUser().getUserName());
|
|
691
|
|
- qw.set(WorkOrderBase::getDealdept, CurrentUser().getDeptId());
|
|
|
710
|
+
|
|
|
711
|
+ qw.set(WorkOrderBase::getDealusername, CurrentUser().getNickName());
|
|
|
712
|
+
|
|
|
713
|
+
|
|
692
|
714
|
boolean update = workorderbaseService.updateBatch(qw);
|
|
693
|
715
|
if (update) {
|
|
694
|
716
|
|