message
This commit is contained in:
@@ -38,6 +38,8 @@ public enum MessageEnum {
|
||||
MESSAGE_20("您有一个门店的加盟合同审核未通过,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),
|
||||
MESSAGE_21("加盟商已登记一位员工,请及时安排培训", "##### 员工姓名:【${userName}】,员工手机号码:【${mobile}】,登记时间:【${registerTime}】"),
|
||||
MESSAGE_22("您收到一位员工由您带教,请查收", "##### 员工姓名:【${userName}】,员工手机号码:【${mobile}】,登记时间:【${registerTime}】"),
|
||||
MESSAGE_23("您有一个门店待发布加盟费/保证金账单,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),
|
||||
|
||||
;
|
||||
|
||||
private String title;
|
||||
@@ -78,7 +80,6 @@ public enum MessageEnum {
|
||||
switch (this) {
|
||||
case MESSAGE_1:
|
||||
case MESSAGE_2:
|
||||
case MESSAGE_3:
|
||||
case MESSAGE_4:
|
||||
case MESSAGE_5:
|
||||
case MESSAGE_6:
|
||||
@@ -87,6 +88,7 @@ public enum MessageEnum {
|
||||
case MESSAGE_9:
|
||||
return domainUrl + "/dd-noticemsg?appId=" + appId + "&corpId="+ corpId + "&appUrl=" +
|
||||
URLEncoder.encode("pages/common-web-view/index?noticeType=xfsg&routerUrl=notice&target=clue×tamp="+System.currentTimeMillis()+"&lineId=" + paramMap.get("lineId"), StandardCharsets.UTF_8.name());
|
||||
case MESSAGE_3:
|
||||
case MESSAGE_10:
|
||||
return domainUrl + "/dd-noticemsg?appId=" + appId + "&corpId="+ corpId + "&appUrl=" +
|
||||
URLEncoder.encode("pages/common-web-view/index?noticeType=xfsg&routerUrl=notice&target=interview×tamp="+System.currentTimeMillis()+"&lineId=" + paramMap.get("lineId"), StandardCharsets.UTF_8.name());
|
||||
@@ -102,10 +104,15 @@ public enum MessageEnum {
|
||||
URLEncoder.encode("pages/common-web-view/index?noticeType=xfsg&routerUrl=notice&target=pointPush×tamp="+System.currentTimeMillis()+"&lineId="+ paramMap.get("lineId"), StandardCharsets.UTF_8.name());
|
||||
case MESSAGE_15:
|
||||
case MESSAGE_16:
|
||||
case MESSAGE_17:
|
||||
case MESSAGE_18:
|
||||
case MESSAGE_19:
|
||||
case MESSAGE_20:
|
||||
case MESSAGE_23:
|
||||
return "dingtalk://dingtalkclient/action/open_micro_app?appId="+appId+"&corpId="+corpId+"&page=" +
|
||||
URLEncoder.encode("pages/common-web-view/index?noticeType=xfsg&routerUrl=notice&target=franchiseeDetails×tamp="+System.currentTimeMillis()+"&lineId="+ paramMap.get("lineId"), StandardCharsets.UTF_8.name());
|
||||
case MESSAGE_17:
|
||||
return "dingtalk://dingtalkclient/action/open_micro_app?appId="+appId+"&corpId="+corpId+"&page=" +
|
||||
URLEncoder.encode("pages/common-web-view/index?noticeType=xfsg&routerUrl=notice&target=license×tamp="+System.currentTimeMillis()+"&shopId="+ paramMap.get("shopId"), StandardCharsets.UTF_8.name());
|
||||
case MESSAGE_21:
|
||||
case MESSAGE_22:
|
||||
return "dingtalk://dingtalkclient/action/open_micro_app?appId="+appId+"&corpId="+corpId+"&page=" +
|
||||
|
||||
@@ -7,10 +7,7 @@ import com.cool.store.dao.EnterpriseUserDAO;
|
||||
import com.cool.store.dao.RegionDao;
|
||||
import com.cool.store.dao.ShopStageInfoDAO;
|
||||
import com.cool.store.entity.*;
|
||||
import com.cool.store.enums.AuditTypeEnum;
|
||||
import com.cool.store.enums.ErrorCodeEnum;
|
||||
import com.cool.store.enums.SMSMsgEnum;
|
||||
import com.cool.store.enums.UserRoleEnum;
|
||||
import com.cool.store.enums.*;
|
||||
import com.cool.store.enums.point.ShopSubStageStatusEnum;
|
||||
import com.cool.store.exception.ServiceException;
|
||||
import com.cool.store.mapper.*;
|
||||
@@ -85,6 +82,7 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
|
||||
@Resource
|
||||
LineInfoMapper lineInfoMapper;
|
||||
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean submitLicense(SubmitLicenseRequest request, PartnerUserInfoVO user) {
|
||||
@@ -108,6 +106,14 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
|
||||
shopAuditInfoDO.setDataType(0);
|
||||
shopAuditInfoMapper.insertSelective(shopAuditInfoDO);
|
||||
shopStageInfoDAO.updateShopStageAndAuditInfo(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_41, null);
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(request.getShopId());
|
||||
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
Map<String, String> requestMap = new HashMap<>();
|
||||
requestMap.put("shopId",String.valueOf(request.getShopId()));
|
||||
requestMap.put("storeName",shopInfoDO.getShopName());
|
||||
requestMap.put("partnerName,",lineInfoDO.getUsername());
|
||||
requestMap.put("partnerMobile",lineInfoDO.getMobile());
|
||||
commonService.sendMessage(Arrays.asList(shopInfoDO.getSupervisorUserId()), MessageEnum.MESSAGE_17,requestMap);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import com.cool.store.context.LoginUserInfo;
|
||||
import com.cool.store.dao.ShopStageInfoDAO;
|
||||
import com.cool.store.entity.*;
|
||||
import com.cool.store.enums.AuditTypeEnum;
|
||||
import com.cool.store.enums.MessageEnum;
|
||||
import com.cool.store.enums.SMSMsgEnum;
|
||||
import com.cool.store.enums.point.ShopSubStageStatusEnum;
|
||||
import com.cool.store.mapper.*;
|
||||
@@ -20,6 +21,9 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.math.BigInteger;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
|
||||
@Service
|
||||
@@ -116,6 +120,15 @@ public class FranchiseFeeServiceImpl implements FranchiseFeeService {
|
||||
FranchiseFeeDO franchiseFeeDO = franchiseFeeMapper.selectByPrimaryKey(request.getId());
|
||||
franchiseFeeDO.setAuditId(shopAuditInfoDO.getId());
|
||||
franchiseFeeMapper.updateByPrimaryKeySelective(franchiseFeeDO);
|
||||
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(request.getShopId());
|
||||
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
Map<String, String> requestMap = new HashMap<>();
|
||||
requestMap.put("storeName",shopInfoDO.getShopName());
|
||||
requestMap.put("partnerName",lineInfoDO.getUsername());
|
||||
requestMap.put("partnerMobile",lineInfoDO.getMobile());
|
||||
requestMap.put("lineId",String.valueOf(lineInfoDO.getId()));
|
||||
commonService.sendMessage(Arrays.asList(lineInfoDO.getInvestmentManager()), MessageEnum.MESSAGE_18,requestMap);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,11 +6,9 @@ import com.cool.store.dao.HyPartnerUserInfoDAO;
|
||||
import com.cool.store.dao.LineInfoDAO;
|
||||
import com.cool.store.dao.LinePayDAO;
|
||||
import com.cool.store.dao.ShopStageInfoDAO;
|
||||
import com.cool.store.entity.FranchiseFeeDO;
|
||||
import com.cool.store.entity.HyPartnerUserInfoDO;
|
||||
import com.cool.store.entity.LineInfoDO;
|
||||
import com.cool.store.entity.LinePayDO;
|
||||
import com.cool.store.entity.*;
|
||||
import com.cool.store.enums.ErrorCodeEnum;
|
||||
import com.cool.store.enums.MessageEnum;
|
||||
import com.cool.store.enums.WorkflowSubStageEnum;
|
||||
import com.cool.store.enums.WorkflowSubStageStatusEnum;
|
||||
import com.cool.store.enums.point.PayBusinessTypeEnum;
|
||||
@@ -19,6 +17,7 @@ import com.cool.store.enums.point.ShopSubStageStatusEnum;
|
||||
import com.cool.store.exception.ServiceException;
|
||||
import com.cool.store.mapper.FranchiseFeeMapper;
|
||||
import com.cool.store.mapper.LineInfoMapper;
|
||||
import com.cool.store.mapper.ShopInfoMapper;
|
||||
import com.cool.store.request.LinePaySubmitRequest;
|
||||
import com.cool.store.service.LinePayService;
|
||||
import com.cool.store.utils.poi.StringUtils;
|
||||
@@ -31,9 +30,7 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @Author wxp
|
||||
@@ -56,6 +53,12 @@ public class LinePayServiceImpl implements LinePayService {
|
||||
@Resource
|
||||
ShopStageInfoDAO shopStageInfoDAO;
|
||||
|
||||
@Resource
|
||||
CommonService commonService;
|
||||
|
||||
@Resource
|
||||
ShopInfoMapper shopInfoMapper;
|
||||
|
||||
@Override
|
||||
public LinePayVO getLinePayInfo(Long lineId, Integer businessType, Long shopId) {
|
||||
LinePayVO result = null;
|
||||
@@ -87,6 +90,14 @@ public class LinePayServiceImpl implements LinePayService {
|
||||
}
|
||||
franchiseFeeDO.setPayId(payId);
|
||||
franchiseFeeMapper.updateByPrimaryKeySelective(franchiseFeeDO);
|
||||
shopStageInfoDAO.updateShopStageInfo(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_72);
|
||||
Map<String, String> requestMap = new HashMap<>();
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(request.getShopId());
|
||||
requestMap.put("storeName",shopInfoDO.getShopName());
|
||||
requestMap.put("partnerName",lineInfo.getUsername());
|
||||
requestMap.put("partnerMobile",lineInfo.getMobile());
|
||||
requestMap.put("lineId",String.valueOf(lineInfo.getId()));
|
||||
commonService.sendMessage(Arrays.asList(lineInfo.getInvestmentManager()), MessageEnum.MESSAGE_20,requestMap);
|
||||
}
|
||||
if (PayBusinessTypeEnum.INTENT_MONEY.getCode().equals(request.getPayBusinessType())) {
|
||||
lineInfo.setWorkflowSubStage(WorkflowSubStageEnum.PAY_DEPOSIT.getCode());
|
||||
|
||||
@@ -958,7 +958,10 @@ public class PointServiceImpl implements PointService {
|
||||
commonService.sendSms(lineInfo.getMobile(),SMSMsgEnum.LICENSE_SUBMITTED);
|
||||
//发送工作通知
|
||||
Map<String, String> requestMap = new HashMap<>();
|
||||
//todo requestMap参数
|
||||
requestMap.put("storeName",shopInfo.getShopName());
|
||||
requestMap.put("partnerName",lineInfo.getUsername());
|
||||
requestMap.put("partnerMobile",lineInfo.getMobile());
|
||||
requestMap.put("lineId",String.valueOf(lineInfo.getId()));
|
||||
commonService.sendMessage(Arrays.asList(lineInfo.getInvestmentManager()),MessageEnum.MESSAGE_16,requestMap);
|
||||
}
|
||||
return shopStageInfoDAO.updateShopStageAndAuditInfo(shopId, subStageStatus, auditId);
|
||||
|
||||
@@ -78,6 +78,9 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
@Resource
|
||||
PreparationService preparationService;
|
||||
|
||||
@Resource
|
||||
CommonService commonService;
|
||||
|
||||
@Override
|
||||
public Boolean auditResult(AuditResultRequest request) {
|
||||
log.info("SignFranchiseServiceImpl auditResult request:{}", JSONObject.toJSONString(request));
|
||||
@@ -96,6 +99,14 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
if (request.getAuditResult() == Constants.ZERO_INTEGER){
|
||||
shopAuditInfoDO.setResultType(Constants.ONE_INTEGER);
|
||||
shopAuditInfoDO.setRejectReason(request.getCause());
|
||||
Map<String, String> requestMap = new HashMap<>();
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
|
||||
LineInfoDO lineInfo = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
requestMap.put("storeName",shopInfoDO.getShopName());
|
||||
requestMap.put("partnerName",lineInfo.getUsername());
|
||||
requestMap.put("partnerMobile",lineInfo.getMobile());
|
||||
requestMap.put("lineId",String.valueOf(lineInfo.getId()));
|
||||
commonService.sendMessage(Arrays.asList(lineInfo.getInvestmentManager()), MessageEnum.MESSAGE_19,requestMap);
|
||||
}else if (request.getAuditResult() == Constants.ONE_INTEGER){
|
||||
shopAuditInfoDO.setResultType(Constants.ZERO_INTEGER);
|
||||
shopAuditInfoDO.setPassReason(request.getCause());
|
||||
|
||||
Reference in New Issue
Block a user