|
|
|
@@ -89,10 +89,9 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
* @param contractType 1租赁合同 2点位合同wx_rent_contract 3物业wx_property_contract 4点位物业合同 |
|
|
|
* @param applyStatus 状态 |
|
|
|
* @param supplement 是否补录 |
|
|
|
* @param instId 实例id |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
public void updateBusinessStatus(Long businessId,Integer flowType,Integer contractType,Integer applyStatus,Boolean supplement,String instId){ |
|
|
|
public void updateBusinessStatus(Long businessId,Integer flowType,Integer contractType,Integer applyStatus,Boolean supplement){ |
|
|
|
logger.info("businessId:{},supplement:{}",businessId.toString(),supplement); |
|
|
|
if(1 == flowType){ |
|
|
|
if(contractType.intValue() == 1 || contractType.intValue() == 2){ |
|
|
|
@@ -144,8 +143,6 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
//修改记录表当前状态 |
|
|
|
wxFlowRecordMapper.updateCurrStatus(new WxFlowRecord(instId,applyStatus)); |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
@@ -182,7 +179,7 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
if(StringUtils.isNotBlank(str)){ |
|
|
|
contractType = Integer.parseInt(str); |
|
|
|
} |
|
|
|
updateBusinessStatus(businessId,flowType,contractType,EnumRentContractAppStatus.APPLYING.getCode(),supplement,processInstance.getId()); |
|
|
|
updateBusinessStatus(businessId,flowType,contractType,EnumRentContractAppStatus.APPLYING.getCode(),supplement); |
|
|
|
|
|
|
|
// 保存wx_flow_record表审批记录 |
|
|
|
WxFlowRecord wxFlowRecord = new WxFlowRecord(); |
|
|
|
@@ -194,6 +191,7 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
wxFlowRecord.setUserName(userName); |
|
|
|
wxFlowRecord.setStatus(EnumFlowRecordStatus.NEW.getCode()); |
|
|
|
wxFlowRecord.setTaskName("发起"); |
|
|
|
wxFlowRecord.setCurrStatus(EnumFlowRecordStatus.NEW.getCode()); |
|
|
|
wxFlowRecordService.saveOrUpdate(wxFlowRecord); |
|
|
|
|
|
|
|
// 给审批人发送代办通知短信 |
|
|
|
@@ -382,6 +380,8 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
wxFlowRecord.setTaskName(taskName); |
|
|
|
wxFlowRecord.setTaskKey(taskKey); |
|
|
|
wxFlowRecordService.saveOrUpdate(wxFlowRecord); |
|
|
|
//修改记录表当前状态 |
|
|
|
wxFlowRecordMapper.updateCurrStatus(new WxFlowRecord(processInstanceId,EnumFlowRecordStatus.APPLY.getCode())); |
|
|
|
|
|
|
|
return new ResultData(); |
|
|
|
} |
|
|
|
@@ -442,7 +442,7 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
if(StringUtils.isNotBlank(str)){ |
|
|
|
contractType = Integer.parseInt(str); |
|
|
|
} |
|
|
|
updateBusinessStatus(businessId,flowType,contractType,EnumRentContractAppStatus.FINISH.getCode(),supplement,processInstanceId); |
|
|
|
updateBusinessStatus(businessId,flowType,contractType,EnumRentContractAppStatus.FINISH.getCode(),supplement); |
|
|
|
|
|
|
|
// 给发起人发送审批通过消息 |
|
|
|
msgReplaceMap = new HashedMap(); |
|
|
|
@@ -511,7 +511,7 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
if(StringUtils.isNotBlank(str)){ |
|
|
|
contractType = Integer.parseInt(str); |
|
|
|
} |
|
|
|
updateBusinessStatus(businessId,flowType,contractType,EnumRentContractAppStatus.REJECT.getCode(),supplement,processInstanceId); |
|
|
|
updateBusinessStatus(businessId,flowType,contractType,EnumRentContractAppStatus.REJECT.getCode(),supplement); |
|
|
|
|
|
|
|
//保存wx_flow_record表审批记录 |
|
|
|
WxFlowRecord wxFlowRecord = new WxFlowRecord(); |
|
|
|
@@ -526,6 +526,8 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
wxFlowRecord.setTaskKey(taskKey); |
|
|
|
wxFlowRecord.setTaskName(taskName); |
|
|
|
wxFlowRecordService.saveOrUpdate(wxFlowRecord); |
|
|
|
//修改记录表当前状态 |
|
|
|
wxFlowRecordMapper.updateCurrStatus(new WxFlowRecord(processInstanceId,EnumFlowRecordStatus.REJECT.getCode())); |
|
|
|
|
|
|
|
// 给发起人发送驳回消息 |
|
|
|
Map<String,String> msgReplaceMap = new HashedMap(); |
|
|
|
@@ -605,6 +607,7 @@ public class WxFlowServiceImpl implements WxFlowService { |
|
|
|
PageHelper.startPage(pageNum, pageSize); |
|
|
|
WxFlowRecord flowRecord = new WxFlowRecord(); |
|
|
|
flowRecord.setUserId(userId); |
|
|
|
flowRecord.setStatus(EnumFlowRecordStatus.NEW.getCode()); |
|
|
|
List<WxFlowRecord> recordList = wxFlowRecordMapper.findList(flowRecord); |
|
|
|
return new ResultData(recordList); |
|
|
|
} |
|
|
|
|