|
@@ -198,6 +198,8 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
//日志资料
|
|
|
return this.queryTheLogFileBusinessData(taskApprovalVO.getFormDataId());
|
|
|
case 8:
|
|
|
+ case 9:
|
|
|
+ case 10:
|
|
|
//委拖单
|
|
|
return this.queryProcessSubmitBusinessData(taskApprovalVO.getFormDataId(), false);
|
|
|
default:
|
|
@@ -444,8 +446,19 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
this.update(Wrappers.<Task>lambdaUpdate().set(Task::getStatus, 3).eq(Task::getId, task.getId()));
|
|
|
//修改业务数据状态为未上报
|
|
|
// this.updateBusinessDataByFormDataId(task, 0, null);
|
|
|
- this.updateBusinessDataByFormDataId(task, 0, null, -1L);
|
|
|
-
|
|
|
+ this.updateBusinessDataByFormDataId(task, 3, null, -1L);
|
|
|
+ List<InformationQuery> informationQueries = this.informationQueryService.getBaseMapper().selectBatchIds(Arrays.asList(task.getFormDataId().split(",")));
|
|
|
+ if (informationQueries != null && !informationQueries.isEmpty()) {
|
|
|
+ for (InformationQuery informationQuery : informationQueries) {
|
|
|
+ informationQuery.setStatus(0);
|
|
|
+ informationQuery.setId(SnowFlakeUtil.getId());
|
|
|
+ informationQuery.setEVisaPdfUrl(null);
|
|
|
+ informationQuery.setReportNumber(null);
|
|
|
+ informationQuery.setAuditUserIdAndName(null);
|
|
|
+ informationQuery.setTaskId(null);
|
|
|
+ }
|
|
|
+ this.informationQueryService.saveBatch(informationQueries);
|
|
|
+ }
|
|
|
return true;
|
|
|
}
|
|
|
|
|
@@ -677,11 +690,34 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
jdbcTemplate.execute(up_task);
|
|
|
|
|
|
if(taskApp.getApprovalType() == 3){
|
|
|
- jdbcTemplate.execute("update u_contract_log set status=0 where id='"+taskApp.getFormDataId()+"'");
|
|
|
+ jdbcTemplate.execute("update u_contract_log set status=3 where id='"+taskApp.getFormDataId()+"'");
|
|
|
}else if (taskApp.getApprovalType()==8) {
|
|
|
this.jdbcTemplate.execute("update u_entrust_info set status=1 where id=(SELECT wbs_id from u_information_query where id='"+taskApp.getFormDataId()+"')");
|
|
|
}else {
|
|
|
jdbcTemplate.execute("update u_information_query set e_visa_pdf_url='',status=3 where id='"+taskApp.getFormDataId()+"'");
|
|
|
+ InformationQuery informationQuery = informationQueryService.getById(taskApp.getFormDataId());
|
|
|
+ Long primaryKeyId = informationQuery.getWbsId();
|
|
|
+ informationQuery.setStatus(0);
|
|
|
+ informationQuery.setId(SnowFlakeUtil.getId());
|
|
|
+ informationQuery.setEVisaPdfUrl(null);
|
|
|
+ informationQuery.setReportNumber(null);
|
|
|
+ informationQuery.setAuditUserIdAndName(null);
|
|
|
+ informationQuery.setTaskId(null);
|
|
|
+ informationQueryService.save(informationQuery);
|
|
|
+ if (taskApp.getApprovalType() == 9 && primaryKeyId != null) {
|
|
|
+ //修改试验任务状态为未上报
|
|
|
+ String sql = "update u_trial_self_inspection_record set task_status = '未上报' where id=" + primaryKeyId;
|
|
|
+ String sql1 = "SELECT e.* from u_entrust_info e left join u_trial_self_inspection_record t on t.entrust_id=e.id where t.id=" + primaryKeyId;
|
|
|
+ jdbcTemplate.execute(sql);
|
|
|
+ List<EntrustInfo> query = jdbcTemplate.query(sql1, new BeanPropertyRowMapper<>(EntrustInfo.class));
|
|
|
+ if (!query.isEmpty()) {
|
|
|
+ String[] idss = query.stream()
|
|
|
+ .map(item -> String.valueOf(item.getId()))
|
|
|
+ .toArray(String[]::new);
|
|
|
+ String update = "update u_entrust_info set status=3 where id in(" + String.join(",", idss) + ")";
|
|
|
+ jdbcTemplate.execute(update);
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -1546,6 +1582,10 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
//日志文件
|
|
|
this.updateContractLogBusinessDataStatus(task.getFormDataId(), status, newFileUrl);
|
|
|
break;
|
|
|
+ case 9:
|
|
|
+ case 10:
|
|
|
+ this.updateWriteBusinessDataStatus(task.getFormDataId(), status, newFileUrl, UserId);
|
|
|
+ break;
|
|
|
default:
|
|
|
break;
|
|
|
}
|
|
@@ -1558,8 +1598,8 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
public void updateContractLogBusinessDataStatus(String formDataId, Integer status, String newFileUrl) {
|
|
|
this.contractLogService.update(Wrappers.<ContractLog>lambdaUpdate().set(ContractLog::getStatus, status)
|
|
|
.set(ContractLog::getEVisaPdfUrl, newFileUrl)
|
|
|
- .set(ContractLog::getAuditUserIdAndName, null)
|
|
|
- .set(ContractLog::getBatch, null)
|
|
|
+// .set(ContractLog::getAuditUserIdAndName, null)
|
|
|
+// .set(ContractLog::getBatch, null)
|
|
|
.in(ContractLog::getId, Arrays.asList(formDataId.split(","))));
|
|
|
}
|
|
|
|
|
@@ -1649,8 +1689,8 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
System.out.println("----- 电签成功--------==修改---=" + dateInfo);
|
|
|
this.informationQueryService.update(Wrappers.<InformationQuery>lambdaUpdate().set(InformationQuery::getStatus, status)
|
|
|
.set(InformationQuery::getEVisaPdfUrl, newFileUrl)
|
|
|
- .set(InformationQuery::getReportNumber, null)
|
|
|
- .set(InformationQuery::getAuditUserIdAndName, null)
|
|
|
+// .set(InformationQuery::getReportNumber, null)
|
|
|
+// .set(InformationQuery::getAuditUserIdAndName, null)
|
|
|
.set(InformationQuery::getEVisaPdfPage, pdfPage)
|
|
|
.set(InformationQuery::getEVisaPdfSize, pdfSize)
|
|
|
.set(InformationQuery::getBusinessTime, dateInfo)
|
|
@@ -1666,8 +1706,8 @@ public class TaskServiceImpl extends BaseServiceImpl<TaskMapper, Task> implement
|
|
|
} catch (Exception e) {
|
|
|
this.informationQueryService.update(Wrappers.<InformationQuery>lambdaUpdate().set(InformationQuery::getStatus, status)
|
|
|
.set(InformationQuery::getEVisaPdfUrl, newFileUrl)
|
|
|
- .set(InformationQuery::getReportNumber, null)
|
|
|
- .set(InformationQuery::getAuditUserIdAndName, null)
|
|
|
+// .set(InformationQuery::getReportNumber, null)
|
|
|
+// .set(InformationQuery::getAuditUserIdAndName, null)
|
|
|
.set(InformationQuery::getEVisaPdfPage, pdfPage)
|
|
|
.set(InformationQuery::getEVisaPdfSize, pdfSize)
|
|
|
.set(InformationQuery::getBusinessTime, dateInfo)
|