Просмотр исходного кода

[铜锣湾][修改][预账单]

release_toaliyun_real
luozukai 7 лет назад
committed by Stormeye Wu
Родитель
Сommit
4195ba2523
1 измененных файлов: 18 добавлений и 7 удалений
  1. +18
    -7
      mallinkService/src/main/java/com/iformall/service/impl/WxFlowServiceImpl.java

+ 18
- 7
mallinkService/src/main/java/com/iformall/service/impl/WxFlowServiceImpl.java Просмотреть файл

@@ -179,6 +179,16 @@ public class WxFlowServiceImpl implements WxFlowService {
}
}

public Map<String,Object> mallUserInfoToMap(MallUserInfo userInfo){
Map<String,Object> map = new HashedMap();
if(userInfo != null){
map.put("name",userInfo.getName());
map.put("id",userInfo.getId());
map.put("phone",userInfo.getPhone());
}
return map;
}

@Override
@Transactional(propagation = Propagation.REQUIRED,rollbackFor = {Exception.class})
public ResultData start(Map<String, Object> params,Long userId,String userName,String tenantId) {
@@ -196,7 +206,7 @@ public class WxFlowServiceImpl implements WxFlowService {
}
// map info,设置发起人等信息
MallUserInfo starterInfo = this.mallUserInfoService.getById(userId);
map.put("starter", starterInfo);
map.put("starter", mallUserInfoToMap(starterInfo));
map.put("startTime",new Date().getTime());
map.put("businessId",businessId+"");
map.put("flowType",flowType);
@@ -272,7 +282,8 @@ public class WxFlowServiceImpl implements WxFlowService {
Map<String,Object> taskInfoMap = new HashedMap();
Map<String,Object> mapInfo = taskService.getVariables(task.getId());
if(mapInfo!=null){
taskInfoMap.put("starter",((MallUserInfo)mapInfo.get("starter")).getName());
Map<String,Object> userMap = (Map<String,Object>)mapInfo.get("starter");
taskInfoMap.put("starter",userMap!=null?userMap.get("name"):"");
taskInfoMap.put("startTime",mapInfo.get("startTime"));
taskInfoMap.put("processInstanceId",task.getProcessInstanceId());
taskInfoMap.put("taskId",task.getId());
@@ -442,7 +453,7 @@ public class WxFlowServiceImpl implements WxFlowService {
Map<String,String> msgReplaceMap = new HashedMap();
WxMsgValidationcode wxMsgValidationcode = new WxMsgValidationcode();
wxMsgValidationcode.setTenantId(tenantId);
MallUserInfo starter = (MallUserInfo)mapInfo.get("starter");
Map<String,Object> userMap = (Map<String,Object>)mapInfo.get("starter");
List<Map<String,String>> taskAssigneeList = (List)mapInfo.get("taskAssignee");
Long businessId = Long.parseLong(mapInfo.get("businessId").toString());

@@ -470,7 +481,7 @@ public class WxFlowServiceImpl implements WxFlowService {
msgReplaceMap.put("toUserName",assignee.trim());

wxMsgValidationcode = new WxMsgValidationcode();
wxMsgValidationcode.setPhone(starter.getPhone());
wxMsgValidationcode.setPhone(userMap!=null?(String)userMap.get("phone"):"");
wxMsgValidationcode.setType(EnumMsgModel.FLOW_APPLY_NODIFY.getCode());
wxMsgValidationcodeService.sendWorkFlowNodify(wxMsgValidationcode,msgReplaceMap);
return false;
@@ -486,7 +497,7 @@ public class WxFlowServiceImpl implements WxFlowService {
msgReplaceMap.put("contract",businessId+"");
msgReplaceMap.put("page",Constant.adminPage);
wxMsgValidationcode = new WxMsgValidationcode();
wxMsgValidationcode.setPhone(starter.getPhone());
wxMsgValidationcode.setPhone(userMap!=null?(String)userMap.get("phone"):"");
wxMsgValidationcode.setType(EnumMsgModel.FLOW_PASS_NODIFY.getCode());
wxMsgValidationcodeService.sendWorkFlowNodify(wxMsgValidationcode,msgReplaceMap);
return true;
@@ -528,7 +539,7 @@ public class WxFlowServiceImpl implements WxFlowService {
Map<String,Object> mapInfo = taskService.getVariables(task.getId());
Long businessId = Long.parseLong(mapInfo.get("businessId").toString());
Integer flowType = (Integer)mapInfo.get("flowType");
MallUserInfo starter = (MallUserInfo)mapInfo.get("starter");
Map<String,Object> userMap = (Map<String,Object>)mapInfo.get("starter");

String taskName;
String taskKey;
@@ -568,7 +579,7 @@ public class WxFlowServiceImpl implements WxFlowService {
msgReplaceMap.put("page",Constant.adminPage);

wxMsgValidationcode = new WxMsgValidationcode();
wxMsgValidationcode.setPhone(starter.getPhone());
wxMsgValidationcode.setPhone(userMap!=null?(String)userMap.get("phone"):"");
wxMsgValidationcode.setType(EnumMsgModel.FLOW_REJECT_NODIFY.getCode());
wxMsgValidationcodeService.sendWorkFlowNodify(wxMsgValidationcode,msgReplaceMap);
return new ResultData();


Загрузка…
Отмена
Сохранить