Merge remote-tracking branch 'xfsg/cc_partner_init' into cc_partner_init
This commit is contained in:
@@ -10,6 +10,13 @@ public enum MessageEnum {
|
|||||||
|
|
||||||
MESSAGE_1("您有一份加盟意向申请,请查收。", "##### 加盟商姓名:{0}\n##### 意向加盟区域:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
MESSAGE_1("您有一份加盟意向申请,请查收。", "##### 加盟商姓名:{0}\n##### 意向加盟区域:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
MESSAGE_2("您有一份邀约面谈预约,请查收。", "##### 加盟商姓名:{0}\n##### 意向加盟区域:{1}\n##### 预约面谈时间:{2}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
MESSAGE_2("您有一份邀约面谈预约,请查收。", "##### 加盟商姓名:{0}\n##### 意向加盟区域:{1}\n##### 预约面谈时间:{2}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_3("您收到一份邀约面谈预约,请查收", "##### 加盟商姓名:{0}\n##### 预约时间:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_4("您收到一份一次面审预约,请查收", "##### 加盟商姓名:{0}\n##### 预约时间:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_5("您收到一份二次面审预约,请查收", "##### 加盟商姓名:{0}\n##### 预约时间:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_6("您有线索未通过面审,请查收", "##### 加盟商姓名:{0}\n##### 面审时间:{1}\n##### 面审官:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_7("您的铺位已审核通过,请查收", "##### 铺位名称:{0}\n##### 铺位地址:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_8("您有一个铺位需要审核,请查收", "##### 铺位名称:{0}\n##### 铺位地址:{1}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
MESSAGE_9("已为您分配一位加盟商,请查收", "##### 加盟商姓名:{0}\n##### 手机号码:{1}\n##### 意向加盟区域:{2}\n", "https://oss.coolcollege.cn/53c11d2f4ec94d4fa7edd7a96e40e2d6.png"),
|
||||||
|
|
||||||
|
|
||||||
;
|
;
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ package com.cool.store.enums;
|
|||||||
public enum SMSMsgEnum {
|
public enum SMSMsgEnum {
|
||||||
|
|
||||||
MODIFY_INTERVIEW_TIME("修改面审时间","", "SMS_464760909"),
|
MODIFY_INTERVIEW_TIME("修改面审时间","", "SMS_464760909"),
|
||||||
|
SECOND_INTERVIEW_PASS("二审面试通过","", "SMS_464760909"),
|
||||||
;
|
;
|
||||||
|
|
||||||
private String title;
|
private String title;
|
||||||
|
|||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.cool.store.dto.decoration;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Auther: WangShuo
|
||||||
|
* @Date: 2024/04/28/下午5:37
|
||||||
|
* @Version 1.0
|
||||||
|
* @注释:
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class ProjectDTO {
|
||||||
|
private String projectId;
|
||||||
|
private String clientCode;
|
||||||
|
private String clientName;
|
||||||
|
private String pCode;
|
||||||
|
private String address;
|
||||||
|
}
|
||||||
@@ -1,11 +1,8 @@
|
|||||||
package com.cool.store.entity;
|
package com.cool.store.entity;
|
||||||
|
|
||||||
import com.alibaba.fastjson.JSONArray;
|
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.cool.store.dto.point.AuditNodeDTO;
|
|
||||||
import com.cool.store.enums.AuditStatusEnum;
|
import com.cool.store.enums.AuditStatusEnum;
|
||||||
import com.cool.store.enums.NodeNoEnum;
|
import com.cool.store.enums.NodeNoEnum;
|
||||||
import com.cool.store.request.PointAuditRequest;
|
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
package com.cool.store.entity;
|
package com.cool.store.entity;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.cool.store.enums.point.*;
|
import com.cool.store.enums.point.*;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
@@ -589,6 +591,23 @@ public class PointDetailInfoDO {
|
|||||||
if(Objects.isNull(this.pictureObj) || StringUtils.isBlank(this.pictureObj)){
|
if(Objects.isNull(this.pictureObj) || StringUtils.isBlank(this.pictureObj)){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(this.pictureObj);
|
||||||
|
JSONArray front = jsonObject.getJSONArray("front");
|
||||||
|
if(Objects.isNull(front) || front.isEmpty()){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
JSONArray leftSide = jsonObject.getJSONArray("leftSide");
|
||||||
|
if(Objects.isNull(leftSide) || leftSide.isEmpty()){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
JSONArray rightSide = jsonObject.getJSONArray("rightSide");
|
||||||
|
if(Objects.isNull(rightSide) || rightSide.isEmpty()){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
JSONArray video = jsonObject.getJSONArray("video");
|
||||||
|
if(Objects.isNull(video) || video.isEmpty()){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -21,4 +21,10 @@ public class ShopStageAcceptanceRequest {
|
|||||||
@ApiModelProperty("是否合格 0:不合格 1:合格")
|
@ApiModelProperty("是否合格 0:不合格 1:合格")
|
||||||
private Boolean result;
|
private Boolean result;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 店铺id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty("店铺id")
|
||||||
|
private Long shopId;
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.cool.store.vo;
|
||||||
|
|
||||||
|
import com.cool.store.vo.log.DesignLogVo;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Auther: WangShuo
|
||||||
|
* @Date: 2024/04/28/下午3:37
|
||||||
|
* @Version 1.0
|
||||||
|
* @注释:设计阶段信息
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class DesignInfoVo {
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
private Integer resultType;
|
||||||
|
private String planTime;
|
||||||
|
private List<DesignLogVo> logs;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.cool.store.vo.log;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Auther: WangShuo
|
||||||
|
* @Date: 2024/04/28/下午4:02
|
||||||
|
* @Version 1.0
|
||||||
|
* @注释:设计阶段跟踪日志
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class DesignLogVo {
|
||||||
|
|
||||||
|
private String logTime;
|
||||||
|
private String name;
|
||||||
|
private String description;
|
||||||
|
private String planTime;
|
||||||
|
private String finishTime;
|
||||||
|
private List<String> attachmentUrl;
|
||||||
|
}
|
||||||
@@ -25,19 +25,7 @@ public interface CoolStoreStartFlowService {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
ResponseResult franchiseAgreement(FranchiseAgreementRequest request,Integer type);
|
ResponseResult franchiseAgreement(FranchiseAgreementRequest request,Integer type);
|
||||||
/**
|
|
||||||
* @Auther: wangshuo
|
|
||||||
* @Date: 2024/4/25
|
|
||||||
* @description:项目列表
|
|
||||||
*/
|
|
||||||
ResponseResult getProjectList(String shopCode);
|
|
||||||
/**
|
|
||||||
* @Auther: wangshuo
|
|
||||||
* @Date: 2024/4/25
|
|
||||||
* @description:项目详情
|
|
||||||
* @Param projectId:项目主键,clientCode:客户编号,pCode:项目编号
|
|
||||||
*/
|
|
||||||
ResponseResult getStoreDetail(Long projectId,String clientCode,String pCode);
|
|
||||||
/**
|
/**
|
||||||
* @Auther: wangshuo
|
* @Auther: wangshuo
|
||||||
* @Date: 2024/4/25
|
* @Date: 2024/4/25
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.cool.store.service;
|
||||||
|
|
||||||
|
import com.cool.store.vo.DesignInfoVo;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Auther: WangShuo
|
||||||
|
* @Date: 2024/04/28/下午4:45
|
||||||
|
* @Version 1.0
|
||||||
|
* @注释:
|
||||||
|
*/
|
||||||
|
public interface DecorationService {
|
||||||
|
/**
|
||||||
|
* @Auther: wangshuo
|
||||||
|
* @Date: 2024/4/28
|
||||||
|
* @description:获取装修阶段子阶段信息
|
||||||
|
*/
|
||||||
|
List<DesignInfoVo> decorations();
|
||||||
|
/**
|
||||||
|
* @Auther: wangshuo
|
||||||
|
* @Date: 2024/4/28
|
||||||
|
* @description:设计阶段信息
|
||||||
|
*/
|
||||||
|
List<DesignInfoVo> DesignInfo(String shopCode);
|
||||||
|
}
|
||||||
@@ -2,6 +2,7 @@ package com.cool.store.service;
|
|||||||
|
|
||||||
import com.cool.store.request.OpenAcceptanceRequest;
|
import com.cool.store.request.OpenAcceptanceRequest;
|
||||||
import com.cool.store.request.ShopAcceptanceRequest;
|
import com.cool.store.request.ShopAcceptanceRequest;
|
||||||
|
import com.cool.store.request.ShopStageAcceptanceRequest;
|
||||||
import com.cool.store.vo.OpenAcceptanceInfoListVO;
|
import com.cool.store.vo.OpenAcceptanceInfoListVO;
|
||||||
import com.cool.store.vo.ShopAcceptanceVO;
|
import com.cool.store.vo.ShopAcceptanceVO;
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
@@ -31,4 +32,6 @@ public interface OpenAcceptanceInfoService {
|
|||||||
* @param shopAcceptanceRequest
|
* @param shopAcceptanceRequest
|
||||||
*/
|
*/
|
||||||
void acceptance(ShopAcceptanceRequest shopAcceptanceRequest, String userId);
|
void acceptance(ShopAcceptanceRequest shopAcceptanceRequest, String userId);
|
||||||
|
|
||||||
|
void acceptanceOne(ShopStageAcceptanceRequest shopStageAcceptanceRequest);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,4 +13,11 @@ public interface YlfService {
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
DecorationDTO getDecoration(Long id) ;
|
DecorationDTO getDecoration(Long id) ;
|
||||||
|
/**
|
||||||
|
* @Auther: wangshuo
|
||||||
|
* @Date: 2024/4/25
|
||||||
|
* @description:项目列表
|
||||||
|
*/
|
||||||
|
String getProjectList(String shopCode);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ public class CommonService {
|
|||||||
return (AuditResultService) applicationContext.getBean(auditEnum.getClazz());
|
return (AuditResultService) applicationContext.getBean(auditEnum.getClazz());
|
||||||
}
|
}
|
||||||
|
|
||||||
public void sendMessage(List<String> userIds, Long lineId, MessageEnum message, String... param){
|
public void sendMessage(List<String> userIds, MessageEnum message, String... param){
|
||||||
if(CollectionUtils.isEmpty(userIds)){
|
if(CollectionUtils.isEmpty(userIds)){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -83,7 +83,7 @@ public class CommonService {
|
|||||||
if(CollectionUtils.isEmpty(userIds)){
|
if(CollectionUtils.isEmpty(userIds)){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
String mobileParam = MessageFormat.format("{0}&eid={1}&corpId={2}&appType=dingding2&lineId={3}", "", enterpriseId, dingCorpId, String.valueOf(lineId));
|
String mobileParam = MessageFormat.format("{0}&eid={1}&corpId={2}&appType=dingding2&lineId={3}", "", enterpriseId, dingCorpId, null);
|
||||||
try {
|
try {
|
||||||
String messageUrl = coolStoreDomainUrl + "dd-noticemsg?miniAppId={0}&appId={1}&corpId={2}&appUrl=" + URLEncoder.encode("pages/common-web-view/index?routerUrl=notice&target=" + mobileParam, StandardCharsets.UTF_8.name());
|
String messageUrl = coolStoreDomainUrl + "dd-noticemsg?miniAppId={0}&appId={1}&corpId={2}&appUrl=" + URLEncoder.encode("pages/common-web-view/index?routerUrl=notice&target=" + mobileParam, StandardCharsets.UTF_8.name());
|
||||||
SendMessageDTO messageDTO = new SendMessageDTO();
|
SendMessageDTO messageDTO = new SendMessageDTO();
|
||||||
@@ -131,8 +131,10 @@ public class CommonService {
|
|||||||
.phoneNumberJson(JSONObject.toJSONString(poneNumbers))
|
.phoneNumberJson(JSONObject.toJSONString(poneNumbers))
|
||||||
.signNameJson(JSONObject.toJSONString(Arrays.asList(signName)))
|
.signNameJson(JSONObject.toJSONString(Arrays.asList(signName)))
|
||||||
.templateCode(templateCode.getTemplateCode())
|
.templateCode(templateCode.getTemplateCode())
|
||||||
.templateParamJson(templateParam.toJSONString())
|
|
||||||
.build();
|
.build();
|
||||||
|
if(Objects.nonNull(templateParam)){
|
||||||
|
sendBatchSmsRequest.toBuilder().templateParamJson(templateParam.toJSONString());
|
||||||
|
}
|
||||||
CompletableFuture<SendBatchSmsResponse> response = client.sendBatchSms(sendBatchSmsRequest);
|
CompletableFuture<SendBatchSmsResponse> response = client.sendBatchSms(sendBatchSmsRequest);
|
||||||
SendBatchSmsResponse resp = response.get();
|
SendBatchSmsResponse resp = response.get();
|
||||||
log.info("短信发送response:{}", JSONObject.toJSONString(resp));
|
log.info("短信发送response:{}", JSONObject.toJSONString(resp));
|
||||||
|
|||||||
@@ -57,7 +57,6 @@ public class CoolStoreStartFlowServiceImpl implements CoolStoreStartFlowService
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ResponseResult franchiseAgreement(FranchiseAgreementRequest request, Integer type) {
|
public ResponseResult franchiseAgreement(FranchiseAgreementRequest request, Integer type) {
|
||||||
log.info("newStore param:{}", JSONObject.toJSONString(request));
|
log.info("newStore param:{}", JSONObject.toJSONString(request));
|
||||||
@@ -81,53 +80,6 @@ public class CoolStoreStartFlowServiceImpl implements CoolStoreStartFlowService
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public ResponseResult getProjectList(String shopCode) {
|
|
||||||
log.info("getProjectList param:{}", shopCode);
|
|
||||||
if (Objects.isNull(shopCode)) {
|
|
||||||
throw new ServiceException(ErrorCodeEnum.PARAMS_VALIDATE_ERROR);
|
|
||||||
}
|
|
||||||
String url = String.format(Constants.GET_PROJECT_LIST, shopCode);
|
|
||||||
log.info("CoolStoreStartFlowServiceImpl#getOrder, url:{}", url);
|
|
||||||
try {
|
|
||||||
JSONObject jsonObject = httpRestTemplateService.getForObject(url, JSONObject.class, new HashMap<>());
|
|
||||||
log.info("CoolStoreStartFlowServiceImpl#getOrder,jsonObject:{}", jsonObject.toJSONString());
|
|
||||||
if (jsonObject.get("status").equals(Constants.SUCCESS)) {
|
|
||||||
return new ResponseResult(200, jsonObject.get("data").toString(), jsonObject.get("msg").toString());
|
|
||||||
} else {
|
|
||||||
return new ResponseResult(500, jsonObject.get("msg").toString());
|
|
||||||
}
|
|
||||||
} catch (Exception e) {
|
|
||||||
log.info("调用鲜丰服务异常,getProjectList error:{}", e);
|
|
||||||
throw new ServiceException(ErrorCodeEnum.XFSG_SERVICE_ERROR);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public ResponseResult getStoreDetail(Long projectId, String clientCode, String pCode) {
|
|
||||||
log.info("getStoreList projectId:{},clientCode:{},pCode:{}", projectId, clientCode, pCode);
|
|
||||||
if (Objects.isNull(projectId) && Objects.isNull(clientCode) && Objects.isNull(pCode)) {
|
|
||||||
throw new ServiceException(ErrorCodeEnum.PARAMS_VALIDATE_ERROR);
|
|
||||||
}
|
|
||||||
HashMap requestMap = new HashMap();
|
|
||||||
requestMap.put("projectId", projectId);
|
|
||||||
requestMap.put("clientCode", clientCode);
|
|
||||||
requestMap.put("pCode", pCode);
|
|
||||||
try {
|
|
||||||
JSONObject jsonObject = httpRestTemplateService.getForObject(Constants.GET_PROJECT_DETAIL, JSONObject.class, requestMap);
|
|
||||||
log.info("FirstOrderServiceImp#getStoreDetail, jsonObject:{}", jsonObject.toJSONString());
|
|
||||||
if (jsonObject.get("status").equals(Constants.SUCCESS)) {
|
|
||||||
return new ResponseResult(200, jsonObject.get("data").toString(), jsonObject.get("msg").toString());
|
|
||||||
} else {
|
|
||||||
return new ResponseResult(500, jsonObject.get("msg").toString());
|
|
||||||
}
|
|
||||||
} catch (Exception e) {
|
|
||||||
log.info("调用鲜丰服务异常,getProjectList error:{}", e);
|
|
||||||
throw new ServiceException(ErrorCodeEnum.XFSG_SERVICE_ERROR);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Boolean getFirstOrder(String shopCode) {
|
public Boolean getFirstOrder(String shopCode) {
|
||||||
@@ -156,4 +108,5 @@ public class CoolStoreStartFlowServiceImpl implements CoolStoreStartFlowService
|
|||||||
requestMap.put("timestamp", timestamp);
|
requestMap.put("timestamp", timestamp);
|
||||||
requestMap.put("signature", signature);
|
requestMap.put("signature", signature);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
package com.cool.store.service.impl;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.cool.store.dto.decoration.DecorationDTO;
|
||||||
|
import com.cool.store.service.DecorationService;
|
||||||
|
import com.cool.store.service.YlfService;
|
||||||
|
import com.cool.store.vo.DesignInfoVo;
|
||||||
|
import org.apache.poi.ss.formula.functions.T;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.Collections;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Auther: WangShuo
|
||||||
|
* @Date: 2024/04/28/下午4:46
|
||||||
|
* @Version 1.0
|
||||||
|
* @注释:
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class DecorationServiceImpl implements DecorationService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private YlfService ylfService;
|
||||||
|
@Override
|
||||||
|
public List<DesignInfoVo> decorations() {
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DesignInfoVo> DesignInfo(String shopCode) {
|
||||||
|
String projectId = ylfService.getProjectList(shopCode);
|
||||||
|
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -156,7 +156,7 @@ public class LineInterviewServiceImpl extends LineFlowService implements LineInt
|
|||||||
}
|
}
|
||||||
LineInterviewDO addInterview = LineInterviewDO.convertDO(lineInfo, startTime, endTime, UUIDUtils.get8UUID(), interviewerUserId, interviewType.getCode(), eventId);
|
LineInterviewDO addInterview = LineInterviewDO.convertDO(lineInfo, startTime, endTime, UUIDUtils.get8UUID(), interviewerUserId, interviewType.getCode(), eventId);
|
||||||
lineInterviewDAO.addInterviewInfo(addInterview);
|
lineInterviewDAO.addInterviewInfo(addInterview);
|
||||||
commonService.sendMessage(Arrays.asList(interviewerUserId), lineInfo.getId(), MessageEnum.MESSAGE_2, lineInfo.getUsername(), hyOpenAreaInfoDAO.selectNameMapById(lineInfo.getWantShopAreaId()), DateUtils.parseDateToStr(DateUtils.YYYY_MM_DD_HH_MM, startTime));
|
commonService.sendMessage(Arrays.asList(interviewerUserId), MessageEnum.MESSAGE_2, lineInfo.getUsername(), hyOpenAreaInfoDAO.selectNameMapById(lineInfo.getWantShopAreaId()), DateUtils.parseDateToStr(DateUtils.YYYY_MM_DD_HH_MM, startTime));
|
||||||
return Boolean.TRUE;
|
return Boolean.TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -428,6 +428,8 @@ public class LineInterviewServiceImpl extends LineFlowService implements LineInt
|
|||||||
shopService.initShop(lineInfo);
|
shopService.initShop(lineInfo);
|
||||||
//二审稽核
|
//二审稽核
|
||||||
auditStatusService.insert(lineInfo.getId(),interviewInfo.getId(),auditId,AuditStageEnum.TWO.getCode());
|
auditStatusService.insert(lineInfo.getId(),interviewInfo.getId(),auditId,AuditStageEnum.TWO.getCode());
|
||||||
|
//发送短信
|
||||||
|
commonService.sendSms(lineInfo.getMobile(), SMSMsgEnum.SECOND_INTERVIEW_PASS, null);
|
||||||
}
|
}
|
||||||
return lineInterviewDAO.updateInterviewInfo(updateInterviewInfo) > 0;
|
return lineInterviewDAO.updateInterviewInfo(updateInterviewInfo) > 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ import com.cool.store.enums.point.ShopSubStageFieldEnum;
|
|||||||
import com.cool.store.exception.ServiceException;
|
import com.cool.store.exception.ServiceException;
|
||||||
import com.cool.store.request.OpenAcceptanceRequest;
|
import com.cool.store.request.OpenAcceptanceRequest;
|
||||||
import com.cool.store.request.ShopAcceptanceRequest;
|
import com.cool.store.request.ShopAcceptanceRequest;
|
||||||
|
import com.cool.store.request.ShopStageAcceptanceRequest;
|
||||||
import com.cool.store.service.OpenAcceptanceInfoService;
|
import com.cool.store.service.OpenAcceptanceInfoService;
|
||||||
import com.cool.store.service.RegionService;
|
import com.cool.store.service.RegionService;
|
||||||
import com.cool.store.utils.CoolDateUtils;
|
import com.cool.store.utils.CoolDateUtils;
|
||||||
@@ -141,4 +142,21 @@ public class OpenAcceptanceInfoServiceImpl implements OpenAcceptanceInfoService
|
|||||||
shopInfoDO.setPlanOpenTime(shopAcceptanceRequest.getPlanOpenTime());
|
shopInfoDO.setPlanOpenTime(shopAcceptanceRequest.getPlanOpenTime());
|
||||||
shopInfoDAO.updateShopInfo(shopInfoDO);
|
shopInfoDAO.updateShopInfo(shopInfoDO);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void acceptanceOne(ShopStageAcceptanceRequest shopStageAcceptanceRequest) {
|
||||||
|
OpenAcceptanceInfoDO openAcceptanceInfoDO = openAcceptanceInfoDAO.selectOne(OpenAcceptanceInfoDO.builder().shopId(shopStageAcceptanceRequest.getShopId()).build());
|
||||||
|
if (openAcceptanceInfoDO == null) {
|
||||||
|
throw new ServiceException("该店铺不存在");
|
||||||
|
}
|
||||||
|
if (openAcceptanceInfoDO.getAcceptanceStatus() != null && openAcceptanceInfoDO.getAcceptanceStatus() == 1) {
|
||||||
|
throw new ServiceException("该店铺已验收完成,不能再次验收");
|
||||||
|
}
|
||||||
|
|
||||||
|
ShopSubStageFieldEnum shopSubStageFieldEnum = ShopSubStageFieldEnum.getByShopSubStage(shopStageAcceptanceRequest.getShopSubStage());
|
||||||
|
if (shopSubStageFieldEnum != null) {
|
||||||
|
ReflectUtil.setFieldValue(openAcceptanceInfoDO, shopSubStageFieldEnum.getFiled(), shopStageAcceptanceRequest.getResult());
|
||||||
|
}
|
||||||
|
openAcceptanceInfoDAO.updateByPrimaryKeySelective(openAcceptanceInfoDO);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -198,7 +198,7 @@ public class OpeningOperationPlanImpl implements OpeningOperationPlanService {
|
|||||||
equals(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_152.getShopSubStageStatus())) {
|
equals(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_152.getShopSubStageStatus())) {
|
||||||
// ShopInfoDO shopInfo = shopService.getShopInfo(shopId);
|
// ShopInfoDO shopInfo = shopService.getShopInfo(shopId);
|
||||||
// String shopCode = shopInfo.getShopCode();
|
// String shopCode = shopInfo.getShopCode();
|
||||||
// Boolean firstOrder = coolStoreStartFlowService.getFirstOrder(shopCode);
|
//Boolean firstOrder = coolStoreStartFlowService.getFirstOrder(shopCode);
|
||||||
Boolean firstOrder =Boolean.TRUE;
|
Boolean firstOrder =Boolean.TRUE;
|
||||||
log.info("saveOrder,flag:{}", firstOrder);
|
log.info("saveOrder,flag:{}", firstOrder);
|
||||||
if (firstOrder) {
|
if (firstOrder) {
|
||||||
|
|||||||
@@ -81,6 +81,8 @@ public class PointServiceImpl implements PointService {
|
|||||||
private ShopAuditInfoDAO shopAuditInfoDAO;
|
private ShopAuditInfoDAO shopAuditInfoDAO;
|
||||||
@Resource
|
@Resource
|
||||||
private SysRoleService sysRoleService;
|
private SysRoleService sysRoleService;
|
||||||
|
@Resource
|
||||||
|
private CommonService commonService;
|
||||||
@Value("${mybatis.configuration.variables.enterpriseId}")
|
@Value("${mybatis.configuration.variables.enterpriseId}")
|
||||||
private String enterpriseId;
|
private String enterpriseId;
|
||||||
|
|
||||||
@@ -351,6 +353,7 @@ public class PointServiceImpl implements PointService {
|
|||||||
if(SelectStatusEnum.SELECT_STATUS_1.getCode().equals(pointInfo.getSelectStatus())){
|
if(SelectStatusEnum.SELECT_STATUS_1.getCode().equals(pointInfo.getSelectStatus())){
|
||||||
shopStageInfoDAO.batchUpdateShopStageStatus(pointInfo.getShopId(), Arrays.asList(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_12, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_20));
|
shopStageInfoDAO.batchUpdateShopStageStatus(pointInfo.getShopId(), Arrays.asList(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_12, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_20));
|
||||||
}
|
}
|
||||||
|
commonService.sendMessage(Arrays.asList(pointInfo.getDevelopmentManager()), MessageEnum.MESSAGE_7, pointInfo.getPointName(), pointInfo.getAddress());
|
||||||
}
|
}
|
||||||
return pointInfoDAO.updatePointInfo(updatePoint);
|
return pointInfoDAO.updatePointInfo(updatePoint);
|
||||||
}
|
}
|
||||||
@@ -400,6 +403,8 @@ public class PointServiceImpl implements PointService {
|
|||||||
if(Objects.nonNull(nextAuditRecord)){
|
if(Objects.nonNull(nextAuditRecord)){
|
||||||
//更新下一阶段任务的收到任务时间
|
//更新下一阶段任务的收到任务时间
|
||||||
pointAuditRecordDAO.updatePointAuditRecord(PointAuditRecordDO.convert(nextAuditRecord.getId(), new Date()));
|
pointAuditRecordDAO.updatePointAuditRecord(PointAuditRecordDO.convert(nextAuditRecord.getId(), new Date()));
|
||||||
|
List<String> sendMessageUserIds = JSONObject.parseArray(nextAuditRecord.getHandlerUserIds(), String.class);
|
||||||
|
commonService.sendMessage(sendMessageUserIds, MessageEnum.MESSAGE_8, pointInfo.getPointName(), pointInfo.getAddress());
|
||||||
//审批通过的情况下 生成下一个节点的待办数据
|
//审批通过的情况下 生成下一个节点的待办数据
|
||||||
return pointTodoInfoDAO.addPointTodoInfo(PointAuditRecordDO.convertTODO(nextAuditRecord));
|
return pointTodoInfoDAO.addPointTodoInfo(PointAuditRecordDO.convertTODO(nextAuditRecord));
|
||||||
}
|
}
|
||||||
@@ -408,8 +413,8 @@ public class PointServiceImpl implements PointService {
|
|||||||
pointInfoUpdate.setPointStatus(PointStatusEnum.POINT_STATUS_5.getCode());
|
pointInfoUpdate.setPointStatus(PointStatusEnum.POINT_STATUS_5.getCode());
|
||||||
if(SelectStatusEnum.SELECT_STATUS_1.getCode().equals(pointInfo.getSelectStatus())){
|
if(SelectStatusEnum.SELECT_STATUS_1.getCode().equals(pointInfo.getSelectStatus())){
|
||||||
shopStageInfoDAO.batchUpdateShopStageStatus(pointInfo.getShopId(), Arrays.asList(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_12, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_20));
|
shopStageInfoDAO.batchUpdateShopStageStatus(pointInfo.getShopId(), Arrays.asList(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_12, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_20));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
commonService.sendMessage(Arrays.asList(pointInfo.getDevelopmentManager()), MessageEnum.MESSAGE_7, pointInfo.getPointName(), pointInfo.getAddress());
|
||||||
return pointInfoDAO.updatePointInfo(pointInfoUpdate);
|
return pointInfoDAO.updatePointInfo(pointInfoUpdate);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,10 +2,12 @@ package com.cool.store.service.impl;
|
|||||||
|
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.cool.store.dto.decoration.DecorationDTO;
|
import com.cool.store.dto.decoration.DecorationDTO;
|
||||||
|
import com.cool.store.dto.decoration.ProjectDTO;
|
||||||
import com.cool.store.enums.ErrorCodeEnum;
|
import com.cool.store.enums.ErrorCodeEnum;
|
||||||
import com.cool.store.exception.ServiceException;
|
import com.cool.store.exception.ServiceException;
|
||||||
import com.cool.store.mq.util.HttpRestTemplateService;
|
import com.cool.store.mq.util.HttpRestTemplateService;
|
||||||
import com.cool.store.service.YlfService;
|
import com.cool.store.service.YlfService;
|
||||||
|
import com.cool.store.utils.poi.constant.Constants;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
@@ -13,6 +15,7 @@ import org.springframework.stereotype.Service;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Objects;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Author suzhuhong
|
* @Author suzhuhong
|
||||||
@@ -23,27 +26,27 @@ import java.util.List;
|
|||||||
@Slf4j
|
@Slf4j
|
||||||
public class YlfServiceImpl implements YlfService {
|
public class YlfServiceImpl implements YlfService {
|
||||||
|
|
||||||
static String url = "https://hzly.cloudcubic.net/ajaxHandle/synchronization/JCallBackSynchronizationHandler.ashx?action=app&controller=GetProjectDetails&projectid=";
|
static String url = "https://hzly.cloudcubic.net/ajaxHandle/synchronization/JCallBackSynchronizationHandler.ashx?action=app&controller=GetProjectDetails&projectid=";
|
||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
private HttpRestTemplateService httpRestTemplateService;
|
private HttpRestTemplateService httpRestTemplateService;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public DecorationDTO getDecoration(Long id) {
|
public DecorationDTO getDecoration(Long id) {
|
||||||
String detailUrl = String.format("%s%d", url, id);
|
String detailUrl = String.format("%s%d", url, id);
|
||||||
try {
|
try {
|
||||||
String forObject = httpRestTemplateService.getForObject(detailUrl, String.class, new HashMap<>());
|
String forObject = httpRestTemplateService.getForObject(detailUrl, String.class, new HashMap<>());
|
||||||
Integer status = (Integer) JSONObject.parseObject(forObject, JSONObject.class).get("status");
|
Integer status = (Integer) JSONObject.parseObject(forObject, JSONObject.class).get("status");
|
||||||
if (status != 200){
|
if (status != 200) {
|
||||||
log.info("获取云立方装修公司信息失败,id:{}",id);
|
log.info("获取云立方装修公司信息失败,id:{}", id);
|
||||||
throw new ServiceException(ErrorCodeEnum.YLF_ERROR);
|
throw new ServiceException(ErrorCodeEnum.YLF_ERROR);
|
||||||
}
|
}
|
||||||
Object data = JSONObject.parseObject(forObject, JSONObject.class).get("data");
|
Object data = JSONObject.parseObject(forObject, JSONObject.class).get("data");
|
||||||
if (data == null){
|
if (data == null) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
List<DecorationDTO> list = (List<DecorationDTO>) ((JSONObject) JSONObject.parseObject(forObject, JSONObject.class).get("data")).get("rows");
|
List<DecorationDTO> list = (List<DecorationDTO>) ((JSONObject) JSONObject.parseObject(forObject, JSONObject.class).get("data")).get("rows");
|
||||||
if (CollectionUtils.isNotEmpty(list)){
|
if (CollectionUtils.isNotEmpty(list)) {
|
||||||
return list.get(0);
|
return list.get(0);
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
@@ -52,11 +55,36 @@ public class YlfServiceImpl implements YlfService {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getProjectList(String shopCode) {
|
||||||
|
log.info("getProjectList param:{}", shopCode);
|
||||||
|
if (Objects.isNull(shopCode)) {
|
||||||
|
throw new ServiceException(ErrorCodeEnum.PARAMS_VALIDATE_ERROR);
|
||||||
|
}
|
||||||
|
String url = String.format(Constants.GET_PROJECT_LIST, shopCode);
|
||||||
|
log.info("CoolStoreStartFlowServiceImpl#getOrder, url:{}", url);
|
||||||
|
try {
|
||||||
|
String jsonString = httpRestTemplateService.getForObject(url, String.class, new HashMap<>());
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(jsonString);
|
||||||
|
log.info("CoolStoreStartFlowServiceImpl#getOrder,jsonObject:{}", jsonObject);
|
||||||
|
if (jsonObject.get("status").equals(Constants.SUCCESS)) {
|
||||||
|
if (jsonObject.get("data").toString() == null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
List<ProjectDTO> projectDTOS = (List<ProjectDTO>) ((JSONObject) JSONObject.parseObject(jsonString, JSONObject.class).get("data")).get("rows");
|
||||||
|
|
||||||
|
return ((ProjectDTO)projectDTOS.get(0)).getProjectId();
|
||||||
|
} else {
|
||||||
|
log.info("获取云立方装修公司信息失败,shopCode:{}", shopCode);
|
||||||
|
throw new ServiceException(ErrorCodeEnum.YLF_ERROR);
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.info("调用云立方获取项目列表异常,getProjectList error:{}", e);
|
||||||
|
throw new ServiceException(ErrorCodeEnum.XFSG_SERVICE_ERROR);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,11 +3,11 @@ package com.cool.store.controller.webb;
|
|||||||
import com.cool.store.context.CurrentUserHolder;
|
import com.cool.store.context.CurrentUserHolder;
|
||||||
import com.cool.store.request.OpenAcceptanceRequest;
|
import com.cool.store.request.OpenAcceptanceRequest;
|
||||||
import com.cool.store.request.ShopAcceptanceRequest;
|
import com.cool.store.request.ShopAcceptanceRequest;
|
||||||
|
import com.cool.store.request.ShopStageAcceptanceRequest;
|
||||||
import com.cool.store.response.ResponseResult;
|
import com.cool.store.response.ResponseResult;
|
||||||
import com.cool.store.service.OpenAcceptanceInfoService;
|
import com.cool.store.service.OpenAcceptanceInfoService;
|
||||||
import com.cool.store.vo.OpenAcceptanceInfoListVO;
|
import com.cool.store.vo.OpenAcceptanceInfoListVO;
|
||||||
import com.cool.store.vo.ShopAcceptanceVO;
|
import com.cool.store.vo.ShopAcceptanceVO;
|
||||||
import com.cool.store.vo.ShopStageAcceptanceVO;
|
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiImplicitParam;
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
@@ -16,7 +16,6 @@ import io.swagger.annotations.ApiOperation;
|
|||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Author byd
|
* @Author byd
|
||||||
@@ -54,4 +53,11 @@ public class OpenAcceptanceInfoController {
|
|||||||
return ResponseResult.success(Boolean.TRUE);
|
return ResponseResult.success(Boolean.TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation("开业验收-单项")
|
||||||
|
@PostMapping(path = "/acceptanceOne")
|
||||||
|
public ResponseResult<Boolean> acceptanceOne(@RequestBody ShopStageAcceptanceRequest shopStageAcceptanceRequest) {
|
||||||
|
openAcceptanceInfoService.acceptanceOne(shopStageAcceptanceRequest);
|
||||||
|
return ResponseResult.success(Boolean.TRUE);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,33 @@
|
|||||||
|
package com.cool.store.controller.webb;
|
||||||
|
|
||||||
|
import com.cool.store.response.ResponseResult;
|
||||||
|
import com.cool.store.service.CoolStoreStartFlowService;
|
||||||
|
import com.cool.store.service.YlfService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Auther: WangShuo
|
||||||
|
* @Date: 2024/04/28/下午4:19
|
||||||
|
* @Version 1.0
|
||||||
|
* @注释:
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/pc/decoration")
|
||||||
|
@Api(tags = "PC装修阶段")
|
||||||
|
@Slf4j
|
||||||
|
public class PCDecorationController {
|
||||||
|
@Resource
|
||||||
|
private YlfService ylfService;
|
||||||
|
@GetMapping("/get")
|
||||||
|
private ResponseResult get(){
|
||||||
|
String shopCode = "31310383";
|
||||||
|
return new ResponseResult<>(200,ylfService.getProjectList(shopCode)) ;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -35,7 +35,7 @@ public class PCTestController {
|
|||||||
|
|
||||||
@GetMapping("/sendMessage")
|
@GetMapping("/sendMessage")
|
||||||
public ResponseResult<Boolean> sendMessage(){
|
public ResponseResult<Boolean> sendMessage(){
|
||||||
commonService.sendMessage(Arrays.asList("123836131931284423"), 1L, MessageEnum.MESSAGE_1, "张三", "浙江-杭州");
|
commonService.sendMessage(Arrays.asList("123836131931284423"), MessageEnum.MESSAGE_1, "张三", "浙江-杭州");
|
||||||
return ResponseResult.success(Boolean.FALSE);
|
return ResponseResult.success(Boolean.FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,6 @@ package com.cool.store.controller.webb;
|
|||||||
|
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.cool.store.context.CurrentUserHolder;
|
import com.cool.store.context.CurrentUserHolder;
|
||||||
import com.cool.store.context.PartnerUserHolder;
|
|
||||||
import com.cool.store.request.*;
|
import com.cool.store.request.*;
|
||||||
import com.cool.store.response.ResponseResult;
|
import com.cool.store.response.ResponseResult;
|
||||||
import com.cool.store.service.PointService;
|
import com.cool.store.service.PointService;
|
||||||
|
|||||||
Reference in New Issue
Block a user