|
@@ -122,58 +122,58 @@ public class TApproveReserveInvoiceController extends BaseController {
|
|
|
TInvoiceBookingworkticket invoice = workService.getById(id);
|
|
|
invoice.setStatus(1L);
|
|
|
workService.updateById(invoice);
|
|
|
- switch (invoice.getWorkArea()){
|
|
|
+ switch (invoice.getWorkArea()) {
|
|
|
case "310裂解区":
|
|
|
case "700开关锅炉":
|
|
|
case "320裂解区":
|
|
|
case "250管廊-700":
|
|
|
// devSupId="20253,20257";
|
|
|
- devSupId="10081,10082";
|
|
|
- break;
|
|
|
+// break;
|
|
|
case "330压缩区":
|
|
|
case "废水处理":
|
|
|
case "600废碱":
|
|
|
case "250管廊-600":
|
|
|
- devSupId="20249,20317";
|
|
|
- break;
|
|
|
+// devSupId="20249,20317";
|
|
|
+// break;
|
|
|
case "380分离区":
|
|
|
case "360分离区":
|
|
|
case "350分离区":
|
|
|
case "340分离区":
|
|
|
- devSupId="20252";
|
|
|
- break;
|
|
|
+// devSupId="20252";
|
|
|
+// break;
|
|
|
case "400汽油加氢":
|
|
|
case "250管廊-400":
|
|
|
- devSupId="20248";
|
|
|
- break;
|
|
|
+// devSupId="20248";
|
|
|
+// break;
|
|
|
case "500芳烃抽提":
|
|
|
case "250管廊-500":
|
|
|
- devSupId="20244";
|
|
|
- break;
|
|
|
+// devSupId="20244";
|
|
|
+// break;
|
|
|
case "D301控制楼":
|
|
|
case " D201变电所":
|
|
|
case " 维修厂房":
|
|
|
case "危废车库":
|
|
|
- devSupId="20332,20250,20276";
|
|
|
+// devSupId="20332,20250,20276";
|
|
|
+ devSupId = "10081,10082";
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
//开始工作流、监听
|
|
|
Map<String, Object> variables = new HashMap<>();
|
|
|
variables.put("applyUser", userid.toString());
|
|
|
- variables.put("yhzgusers", tApproveReserveInvoice.getUserSupId());//用户主管
|
|
|
+ variables.put("yhzgusers", tApproveReserveInvoice.getUserSupId().toString());//用户主管
|
|
|
variables.put("zzzgusers", devSupId);//装置主管
|
|
|
if ("1".equals(tApproveReserveInvoice.getIsToday())) {
|
|
|
- variables.put("zzgcsusers", tApproveReserveInvoice.getDevEngineerId());//装置工程师
|
|
|
+ variables.put("zzgcsusers", tApproveReserveInvoice.getDevEngineerId().toString());//装置工程师
|
|
|
}
|
|
|
if ("1".equals(tApproveReserveInvoice.getIsSpecial())) {
|
|
|
- variables.put("zzjlusers", tApproveReserveInvoice.getManagerconId());//装置经理
|
|
|
+ variables.put("zzjlusers", tApproveReserveInvoice.getManagerconId().toString());//装置经理
|
|
|
}
|
|
|
- variables.put("yhzgTaskCreateListener",new YhzgTaskCreateListener());//用户主管监听发送邮件
|
|
|
- variables.put("zzzgTaskCreateListener",new ZzzgTaskCreateListener());//装置主管监听发送邮件
|
|
|
- variables.put("zzgcsTaskCreateListener",new ZzgcsTaskCreateListener());//装置工程师监听发送邮件
|
|
|
- variables.put("zzjlTaskCreateListener",new ZzjlTaskCreateListener());//装置经理监听发送邮件
|
|
|
- variables.put("invoiceEndSuccessListener",new InvoiceEndSuccessListener());//流程结束监听发送邮件
|
|
|
+ variables.put("yhzgTaskCreateListener", new YhzgTaskCreateListener());//用户主管监听发送邮件
|
|
|
+ variables.put("zzzgTaskCreateListener", new ZzzgTaskCreateListener());//装置主管监听发送邮件
|
|
|
+ variables.put("zzgcsTaskCreateListener", new ZzgcsTaskCreateListener());//装置工程师监听发送邮件
|
|
|
+ variables.put("zzjlTaskCreateListener", new ZzjlTaskCreateListener());//装置经理监听发送邮件
|
|
|
+ variables.put("invoiceEndSuccessListener", new InvoiceEndSuccessListener());//流程结束监听发送邮件
|
|
|
//采用key来启动流程定义并设置流程变量,返回流程实例
|
|
|
ProcessInstance pi = runtimeService.startProcessInstanceByKey("reserveInvoice", String.valueOf(bussniseeKey), variables);
|
|
|
logger.info("流程部署id:" + pi.getDeploymentId());
|
|
@@ -211,12 +211,12 @@ public class TApproveReserveInvoiceController extends BaseController {
|
|
|
Map<String, Object> param = new HashMap<>();
|
|
|
|
|
|
TInvoiceBookingworkticket invoiceBook = workService.getById(invoice.getInvoiceId());
|
|
|
- if (devTask.getCondition().equals("1") && task.getName().equals("装置经理签字确认")) {
|
|
|
- invoiceBook.setStatus(3L);
|
|
|
- } else if (devTask.getCondition().equals("0")) {
|
|
|
- invoiceBook.setStatus(5L);
|
|
|
- }
|
|
|
- workService.updateById(invoiceBook);
|
|
|
+// if (devTask.getCondition().equals("1") && task.getName().equals("装置经理签字确认")) {
|
|
|
+// invoiceBook.setStatus(3L);
|
|
|
+// } else if (devTask.getCondition().equals("0")) {
|
|
|
+// invoiceBook.setStatus(5L);
|
|
|
+// }
|
|
|
+// workService.updateById(invoiceBook);
|
|
|
if (DateUtils.dateTime(invoiceBook.getCreatedate()).equals(DateUtils.dateTime(invoiceBook.getWorkStartTime()))) {
|
|
|
param.put("istoday", "1");
|
|
|
} else {
|
|
@@ -224,7 +224,7 @@ public class TApproveReserveInvoiceController extends BaseController {
|
|
|
}
|
|
|
List<TInvoiceWorkcontent> workcontents = invoiceWorkcontentMapper.selectTInvoiceWorkcontentBybookingticketId(Long.valueOf(invoice.getInvoiceId()));
|
|
|
for (TInvoiceWorkcontent workcontent : workcontents) {
|
|
|
- if (workcontent.getWorkType()==1||workcontent.getWorkType()==2||workcontent.getWorkType()==3||workcontent.getWorkType()==15) {
|
|
|
+ if (workcontent.getWorkType() == 1 || workcontent.getWorkType() == 2 || workcontent.getWorkType() == 3 || workcontent.getWorkType() == 15) {
|
|
|
param.put("isspecial", "1");
|
|
|
break;
|
|
|
} else {
|