mirror of
				https://gitee.com/hhyykk/ipms-sjy.git
				synced 2025-10-31 10:18:42 +08:00 
			
		
		
		
	crm:code review 配置管理
This commit is contained in:
		| @@ -5,8 +5,6 @@ import cn.hutool.core.util.NumberUtil; | ||||
| import cn.hutool.core.util.ObjectUtil; | ||||
| import cn.iocoder.yudao.framework.common.pojo.CommonResult; | ||||
| import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||||
| import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils; | ||||
| import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | ||||
| import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | ||||
| import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; | ||||
| import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||||
| @@ -35,6 +33,8 @@ import java.util.stream.Collectors; | ||||
| import java.util.stream.Stream; | ||||
|  | ||||
| import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | ||||
| import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | ||||
| import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; | ||||
| import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||||
| import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | ||||
|  | ||||
| @@ -46,6 +46,7 @@ public class CrmCustomerController { | ||||
|  | ||||
|     @Resource | ||||
|     private CrmCustomerService customerService; | ||||
|  | ||||
|     @Resource | ||||
|     private DeptApi deptApi; | ||||
|     @Resource | ||||
| @@ -103,11 +104,15 @@ public class CrmCustomerController { | ||||
|     @PreAuthorize("@ss.hasPermission('crm:customer:query')") | ||||
|     public CommonResult<PageResult<CrmCustomerRespVO>> getCustomerPage(@Valid CrmCustomerPageReqVO pageVO) { | ||||
|         PageResult<CrmCustomerDO> pageResult = customerService.getCustomerPage(pageVO); | ||||
|         Set<Long> userSet = CollectionUtils.convertSetByFlatMap(pageResult.getList(), i -> Stream.of(NumberUtil.parseLong(i.getCreator()), i.getOwnerUserId())); | ||||
|         Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userSet); | ||||
|         Map<Long, DeptRespDTO> deptMap = deptApi.getDeptMap(userMap.values().stream().map(AdminUserRespDTO::getDeptId).collect(Collectors.toSet())); | ||||
|         PageResult<CrmCustomerRespVO> pageVo = CrmCustomerConvert.INSTANCE.convertPage(pageResult, userMap, deptMap); | ||||
|         return success(pageVo); | ||||
|         if (CollUtil.isEmpty(pageResult.getList())) { | ||||
|             return success(PageResult.empty(pageResult.getTotal())); | ||||
|         } | ||||
|         // 拼接数据 | ||||
|         Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( | ||||
|                 convertSetByFlatMap(pageResult.getList(), user -> Stream.of(NumberUtil.parseLong(user.getCreator()), user.getOwnerUserId()))); | ||||
|         Map<Long, DeptRespDTO> deptMap = deptApi.getDeptMap( | ||||
|                 convertSet(userMap.values(), AdminUserRespDTO::getDeptId)); | ||||
|         return success(CrmCustomerConvert.INSTANCE.convertPage(pageResult, userMap, deptMap)); | ||||
|     } | ||||
|  | ||||
|     @GetMapping("/export-excel") | ||||
|   | ||||
| @@ -1,13 +1,13 @@ | ||||
| package cn.iocoder.yudao.module.crm.controller.admin.customer; | ||||
|  | ||||
| import cn.hutool.core.collection.CollUtil; | ||||
| import cn.iocoder.yudao.framework.common.pojo.CommonResult; | ||||
| import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||||
| import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigCreateReqVO; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigPageReqVO; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigRespVO; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigUpdateReqVO; | ||||
| import cn.iocoder.yudao.module.crm.convert.customerlimitconfig.CrmCustomerLimitConfigConvert; | ||||
| import cn.iocoder.yudao.module.crm.convert.customer.CrmCustomerLimitConfigConvert; | ||||
| import cn.iocoder.yudao.module.crm.dal.dataobject.customerlimitconfig.CrmCustomerLimitConfigDO; | ||||
| import cn.iocoder.yudao.module.crm.service.customerlimitconfig.CrmCustomerLimitConfigService; | ||||
| import cn.iocoder.yudao.module.system.api.dept.DeptApi; | ||||
| @@ -24,12 +24,10 @@ import org.springframework.web.bind.annotation.*; | ||||
| import javax.annotation.Resource; | ||||
| import javax.validation.Valid; | ||||
| import java.util.Collection; | ||||
| import java.util.HashSet; | ||||
| import java.util.Map; | ||||
| import java.util.Set; | ||||
| import java.util.stream.Collectors; | ||||
|  | ||||
| import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | ||||
| import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; | ||||
|  | ||||
| @Tag(name = "管理后台 - 客户限制配置") | ||||
| @RestController | ||||
| @@ -39,6 +37,7 @@ public class CrmCustomerLimitConfigController { | ||||
|  | ||||
|     @Resource | ||||
|     private CrmCustomerLimitConfigService customerLimitConfigService; | ||||
|  | ||||
|     @Resource | ||||
|     private DeptApi deptApi; | ||||
|     @Resource | ||||
| @@ -74,8 +73,9 @@ public class CrmCustomerLimitConfigController { | ||||
|     @PreAuthorize("@ss.hasPermission('crm:customer-limit-config:query')") | ||||
|     public CommonResult<CrmCustomerLimitConfigRespVO> getCustomerLimitConfig(@RequestParam("id") Long id) { | ||||
|         CrmCustomerLimitConfigDO customerLimitConfig = customerLimitConfigService.getCustomerLimitConfig(id); | ||||
|         Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(new HashSet<>(customerLimitConfig.getUserIds())); | ||||
|         Map<Long, DeptRespDTO> deptMap = deptApi.getDeptMap(new HashSet<>(customerLimitConfig.getDeptIds())); | ||||
|         // 拼接数据 | ||||
|         Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(customerLimitConfig.getUserIds()); | ||||
|         Map<Long, DeptRespDTO> deptMap = deptApi.getDeptMap(customerLimitConfig.getDeptIds()); | ||||
|         return success(CrmCustomerLimitConfigConvert.INSTANCE.convert(customerLimitConfig, userMap, deptMap)); | ||||
|     } | ||||
|  | ||||
| @@ -84,10 +84,14 @@ public class CrmCustomerLimitConfigController { | ||||
|     @PreAuthorize("@ss.hasPermission('crm:customer-limit-config:query')") | ||||
|     public CommonResult<PageResult<CrmCustomerLimitConfigRespVO>> getCustomerLimitConfigPage(@Valid CrmCustomerLimitConfigPageReqVO pageVO) { | ||||
|         PageResult<CrmCustomerLimitConfigDO> pageResult = customerLimitConfigService.getCustomerLimitConfigPage(pageVO); | ||||
|         Set<Long> userIds = CollectionUtils.convertSetByFlatMap(pageResult.getList(), CrmCustomerLimitConfigDO::getUserIds, Collection::stream); | ||||
|         Set<Long> deptIds = CollectionUtils.convertSetByFlatMap(pageResult.getList(), CrmCustomerLimitConfigDO::getDeptIds, Collection::stream); | ||||
|         Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); | ||||
|         Map<Long, DeptRespDTO> deptMap = deptApi.getDeptMap(deptIds); | ||||
|         if (CollUtil.isEmpty(pageResult.getList())) { | ||||
|             return success(PageResult.empty(pageResult.getTotal())); | ||||
|         } | ||||
|         // 拼接数据 | ||||
|         Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( | ||||
|                 convertSetByFlatMap(pageResult.getList(), CrmCustomerLimitConfigDO::getUserIds, Collection::stream)); | ||||
|         Map<Long, DeptRespDTO> deptMap = deptApi.getDeptMap( | ||||
|                 convertSetByFlatMap(pageResult.getList(), CrmCustomerLimitConfigDO::getDeptIds, Collection::stream)); | ||||
|         return success(CrmCustomerLimitConfigConvert.INSTANCE.convertPage(pageResult, userMap, deptMap)); | ||||
|     } | ||||
|  | ||||
|   | ||||
| @@ -34,6 +34,7 @@ public class CrmCustomerPoolConfigController { | ||||
|         return success(CrmCustomerConvert.INSTANCE.convert(customerPoolConfig)); | ||||
|     } | ||||
|  | ||||
|     // TODO @wanwan:这个请求,搞成 save 哈; | ||||
|     @PutMapping("/update") | ||||
|     @Operation(summary = "更新客户公海规则设置") | ||||
|     @PreAuthorize("@ss.hasPermission('crm:customer-pool-config:update')") | ||||
| @@ -41,4 +42,5 @@ public class CrmCustomerPoolConfigController { | ||||
|         customerPoolConfigService.updateCustomerPoolConfig(updateReqVO); | ||||
|         return success(true); | ||||
|     } | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -6,6 +6,7 @@ import lombok.Data; | ||||
| import javax.validation.constraints.NotNull; | ||||
| import java.util.List; | ||||
|  | ||||
| // TODO @wanwan:vo 下,可以新建一个 limitconfig,放它的 vo; | ||||
| /** | ||||
|  * 客户限制配置 Base VO,提供给添加、修改、详细的子 VO 使用 | ||||
|  * 如果子 VO 存在差异的字段,请不要添加到这里,影响 Swagger 文档生成 | ||||
|   | ||||
| @@ -12,6 +12,7 @@ import javax.validation.constraints.NotNull; | ||||
| @Data | ||||
| public class CrmCustomerPoolConfigBaseVO { | ||||
|  | ||||
|     // TODO @wanwan:参数校验 | ||||
|     @Schema(description = "是否启用客户公海", requiredMode = Schema.RequiredMode.REQUIRED, example = "true") | ||||
|     @NotNull(message = "是否启用客户公海不能为空") | ||||
|     private Boolean enabled; | ||||
| @@ -27,4 +28,5 @@ public class CrmCustomerPoolConfigBaseVO { | ||||
|  | ||||
|     @Schema(description = "提前提醒天数", example = "2") | ||||
|     private Integer notifyDays; | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -5,6 +5,7 @@ import lombok.Data; | ||||
| import lombok.EqualsAndHashCode; | ||||
| import lombok.ToString; | ||||
|  | ||||
| // TODO @wanwan:vo 下,可以新建一个 poolconfig,放它的 vo; | ||||
| @Schema(description = "管理后台 - CRM 客户公海规则 Response VO") | ||||
| @Data | ||||
| @EqualsAndHashCode(callSuper = true) | ||||
|   | ||||
| @@ -1,6 +1,5 @@ | ||||
| package cn.iocoder.yudao.module.crm.convert.customer; | ||||
|  | ||||
| import cn.hutool.core.lang.tree.Node; | ||||
| import cn.hutool.core.util.NumberUtil; | ||||
| import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||||
| import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | ||||
| @@ -18,8 +17,6 @@ import org.mapstruct.factory.Mappers; | ||||
|  | ||||
| import java.util.List; | ||||
| import java.util.Map; | ||||
| import java.util.Objects; | ||||
| import java.util.Optional; | ||||
|  | ||||
| /** | ||||
|  * 客户 Convert | ||||
| @@ -65,4 +62,5 @@ public interface CrmCustomerConvert { | ||||
|     CrmCustomerPoolConfigRespVO convert(CrmCustomerPoolConfigDO customerPoolConfig); | ||||
|  | ||||
|     CrmCustomerPoolConfigDO convert(CrmCustomerPoolConfigUpdateReqVO updateReqVO); | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| package cn.iocoder.yudao.module.crm.convert.customerlimitconfig; | ||||
| package cn.iocoder.yudao.module.crm.convert.customer; | ||||
| 
 | ||||
| import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigCreateReqVO; | ||||
| @@ -57,9 +57,11 @@ public interface CrmCustomerLimitConfigConvert { | ||||
|      * @param respVo 响应实体 | ||||
|      */ | ||||
|     static void fillNameField(Map<Long, AdminUserRespDTO> userMap, Map<Long, DeptRespDTO> deptMap, CrmCustomerLimitConfigRespVO respVo) { | ||||
|         // TODO wanwan:返回 list,具体怎么拼接叫给前端; | ||||
|         respVo.setUserNames(respVo.getUserIds().stream().map(userMap::get) | ||||
|                 .filter(Objects::nonNull).map(AdminUserRespDTO::getNickname).collect(Collectors.joining(","))); | ||||
|         respVo.setDeptNames(respVo.getDeptIds().stream().map(deptMap::get) | ||||
|                 .filter(Objects::nonNull).map(DeptRespDTO::getName).collect(Collectors.joining(","))); | ||||
|     } | ||||
| 
 | ||||
| } | ||||
| @@ -46,4 +46,5 @@ public class CrmCustomerPoolConfigDO extends BaseDO { | ||||
|      * 提前提醒天数 | ||||
|      */ | ||||
|     private Integer notifyDays; | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -1,4 +0,0 @@ | ||||
| /** | ||||
|  * 客户 | ||||
|  */ | ||||
| package cn.iocoder.yudao.module.crm.dal.dataobject.customer; | ||||
| @@ -32,6 +32,8 @@ public class CrmCustomerLimitConfigDO extends BaseDO { | ||||
|     private Long id; | ||||
|     /** | ||||
|      * 规则类型 | ||||
|      * | ||||
|      * TODO @wanwan:搞个枚举哈; | ||||
|      */ | ||||
|     private Integer type; | ||||
|     /** | ||||
| @@ -49,7 +51,9 @@ public class CrmCustomerLimitConfigDO extends BaseDO { | ||||
|      */ | ||||
|     private Integer maxCount; | ||||
|     /** | ||||
|      * 成交客户是否占有拥有客户数(当 type = 1 时) | ||||
|      * 成交客户是否占有拥有客户数 | ||||
|      * | ||||
|      * 当且仅当 {@link #type} 为 1 时,进行使用 | ||||
|      */ | ||||
|     private Boolean dealCountEnabled; | ||||
|  | ||||
|   | ||||
| @@ -25,4 +25,5 @@ public interface CrmCustomerPoolConfigService { | ||||
|      * @param saveReqVO 更新信息 | ||||
|      */ | ||||
|     void updateCustomerPoolConfig(@Valid CrmCustomerPoolConfigUpdateReqVO saveReqVO); | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -44,6 +44,7 @@ public class CrmCustomerPoolConfigServiceImpl implements CrmCustomerPoolConfigSe | ||||
|      */ | ||||
|     @Override | ||||
|     public void updateCustomerPoolConfig(CrmCustomerPoolConfigUpdateReqVO saveReqVO) { | ||||
|         // TODO @wanwan:看下 @AssertTrue 的逻辑; | ||||
|         if (BooleanUtil.isTrue(saveReqVO.getEnabled()) && (ObjectUtil.hasNull(saveReqVO.getContactExpireDays(), saveReqVO.getDealExpireDays()))) { | ||||
|             throw exception(CUSTOMER_POOL_CONFIG_ERROR); | ||||
|         } | ||||
| @@ -60,4 +61,5 @@ public class CrmCustomerPoolConfigServiceImpl implements CrmCustomerPoolConfigSe | ||||
|         // 不存在,则进行插入 | ||||
|         customerPoolConfigMapper.insert(CrmCustomerConvert.INSTANCE.convert(saveReqVO)); | ||||
|     } | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -4,7 +4,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigCreateReqVO; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigPageReqVO; | ||||
| import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.CrmCustomerLimitConfigUpdateReqVO; | ||||
| import cn.iocoder.yudao.module.crm.convert.customerlimitconfig.CrmCustomerLimitConfigConvert; | ||||
| import cn.iocoder.yudao.module.crm.convert.customer.CrmCustomerLimitConfigConvert; | ||||
| import cn.iocoder.yudao.module.crm.dal.dataobject.customerlimitconfig.CrmCustomerLimitConfigDO; | ||||
| import cn.iocoder.yudao.module.crm.dal.mysql.customerlimitconfig.CrmCustomerLimitConfigMapper; | ||||
| import cn.iocoder.yudao.module.system.api.dept.DeptApi; | ||||
|   | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.business.CrmBusinessMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.businessstatustype.CrmBusinessStatusTypeMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.clue.CrmClueMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.contact.ContactMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.customer.CrmCustomerMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.customer.CrmCustomerPoolConfigMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.customerlimitconfig.CrmCustomerLimitConfigMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.product.ProductMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.productcategory.ProductCategoryMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.receivable.CrmReceivableMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -1,12 +0,0 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||||
| <mapper namespace="cn.iocoder.yudao.module.crm.dal.mysql.receivable.CrmReceivablePlanMapper"> | ||||
|  | ||||
|     <!-- | ||||
|         一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。 | ||||
|         无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。 | ||||
|         代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。 | ||||
|         文档可见:https://www.iocoder.cn/MyBatis/x-plugins/ | ||||
|      --> | ||||
|  | ||||
| </mapper> | ||||
| @@ -20,6 +20,7 @@ import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo; | ||||
| import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.CUSTOMER_LIMIT_CONFIG_NOT_EXISTS; | ||||
| import static org.junit.jupiter.api.Assertions.*; | ||||
|  | ||||
| // TODO 芋艿:单测后面搞 | ||||
| /** | ||||
|  * {@link CrmCustomerLimitConfigServiceImpl} 的单元测试类 | ||||
|  * | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 YunaiV
					YunaiV