Commit 08e23a7dc4b40897c4da67e83f53ab9ba65e61ed

Authored by dhb52
1 parent 4bd97c4b

wip: style-fix

yudao-module-crm/yudao-module-crm-api/src/main/java/cn/iocoder/yudao/module/crm/enums/ErrorCodeConstants.java
@@ -85,6 +85,6 @@ public interface ErrorCodeConstants { @@ -85,6 +85,6 @@ public interface ErrorCodeConstants {
85 ErrorCode FOLLOW_UP_RECORD_NOT_EXISTS = new ErrorCode(1_020_013_000, "跟进记录不存在"); 85 ErrorCode FOLLOW_UP_RECORD_NOT_EXISTS = new ErrorCode(1_020_013_000, "跟进记录不存在");
86 86
87 // ========== 待办消息 1_020_014_000 ========== 87 // ========== 待办消息 1_020_014_000 ==========
88 - ErrorCode BACKLOG_CONTACT_STATUS_ERROR = new ErrorCode(1_020_014_000, "客户联系状态有误"); 88 + ErrorCode BACKLOG_CONTACT_STATUS_INVALID = new ErrorCode(1_020_014_000, "客户联系状态有误");
89 89
90 } 90 }
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/dal/mysql/customer/CrmCustomerMapper.java
@@ -7,23 +7,19 @@ import cn.iocoder.yudao.framework.mybatis.core.query.MPJLambdaWrapperX; @@ -7,23 +7,19 @@ import cn.iocoder.yudao.framework.mybatis.core.query.MPJLambdaWrapperX;
7 import cn.iocoder.yudao.module.crm.controller.admin.backlog.vo.CrmTodayCustomerPageReqVO; 7 import cn.iocoder.yudao.module.crm.controller.admin.backlog.vo.CrmTodayCustomerPageReqVO;
8 import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerPageReqVO; 8 import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerPageReqVO;
9 import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerDO; 9 import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerDO;
10 -import cn.iocoder.yudao.module.crm.dal.dataobject.followup.CrmFollowUpRecordDO;  
11 import cn.iocoder.yudao.module.crm.enums.common.CrmBizTypeEnum; 10 import cn.iocoder.yudao.module.crm.enums.common.CrmBizTypeEnum;
12 import cn.iocoder.yudao.module.crm.util.CrmQueryWrapperUtils; 11 import cn.iocoder.yudao.module.crm.util.CrmQueryWrapperUtils;
13 import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; 12 import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
14 import org.apache.ibatis.annotations.Mapper; 13 import org.apache.ibatis.annotations.Mapper;
15 import org.springframework.lang.Nullable; 14 import org.springframework.lang.Nullable;
16 15
17 -import java.time.LocalDate;  
18 import java.time.LocalDateTime; 16 import java.time.LocalDateTime;
19 import java.time.LocalTime; 17 import java.time.LocalTime;
20 -import java.time.temporal.TemporalUnit;  
21 import java.util.Collection; 18 import java.util.Collection;
22 import java.util.List; 19 import java.util.List;
23 -import java.util.concurrent.TimeUnit;  
24 20
25 import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; 21 import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
26 -import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.BACKLOG_CONTACT_STATUS_ERROR; 22 +import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.BACKLOG_CONTACT_STATUS_INVALID;
27 23
28 /** 24 /**
29 * 客户 Mapper 25 * 客户 Mapper
@@ -89,8 +85,8 @@ public interface CrmCustomerMapper extends BaseMapperX<CrmCustomerDO> { @@ -89,8 +85,8 @@ public interface CrmCustomerMapper extends BaseMapperX<CrmCustomerDO> {
89 query.selectAll(CrmCustomerDO.class); 85 query.selectAll(CrmCustomerDO.class);
90 86
91 // 拼接自身的查询条件 87 // 拼接自身的查询条件
92 - LocalDateTime beginOfToday = LocalDateTime.now().toLocalDate().atTime(LocalTime.MIN);  
93 - LocalDateTime endOfToday = LocalDateTime.now().toLocalDate().atTime(LocalTime.MAX); 88 + LocalDateTime beginOfToday = LocalDateTime.now().toLocalDate().atTime(LocalTime.MIN);
  89 + LocalDateTime endOfToday = LocalDateTime.now().toLocalDate().atTime(LocalTime.MAX);
94 if (pageReqVO.getContactStatus().equals(CrmTodayCustomerPageReqVO.CONTACT_TODAY)) { 90 if (pageReqVO.getContactStatus().equals(CrmTodayCustomerPageReqVO.CONTACT_TODAY)) {
95 // 今天需联系 91 // 今天需联系
96 query.between(CrmCustomerDO::getContactNextTime, beginOfToday, endOfToday); 92 query.between(CrmCustomerDO::getContactNextTime, beginOfToday, endOfToday);
@@ -101,7 +97,7 @@ public interface CrmCustomerMapper extends BaseMapperX<CrmCustomerDO> { @@ -101,7 +97,7 @@ public interface CrmCustomerMapper extends BaseMapperX<CrmCustomerDO> {
101 // 已联系 97 // 已联系
102 query.between(CrmCustomerDO::getContactLastTime, beginOfToday, endOfToday); 98 query.between(CrmCustomerDO::getContactLastTime, beginOfToday, endOfToday);
103 } else { 99 } else {
104 - throw exception(BACKLOG_CONTACT_STATUS_ERROR); 100 + throw exception(BACKLOG_CONTACT_STATUS_INVALID);
105 } 101 }
106 102
107 return selectJoinPage(pageReqVO, CrmCustomerDO.class, query); 103 return selectJoinPage(pageReqVO, CrmCustomerDO.class, query);