Commit f942e2c7f27529ddda2728e131559507b85fcc07
1 parent
56b59cf3
code review:CRM 回款计划的逻辑
Showing
11 changed files
with
140 additions
and
131 deletions
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/ReceivableController.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable; |
| 2 | 2 | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | +import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||
| 4 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 5 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 5 | import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | 6 | import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; |
| 6 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; | 7 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; |
| @@ -18,9 +19,8 @@ import javax.annotation.Resource; | @@ -18,9 +19,8 @@ import javax.annotation.Resource; | ||
| 18 | import javax.servlet.http.HttpServletResponse; | 19 | import javax.servlet.http.HttpServletResponse; |
| 19 | import javax.validation.Valid; | 20 | import javax.validation.Valid; |
| 20 | import java.io.IOException; | 21 | import java.io.IOException; |
| 21 | -import java.util.Collection; | ||
| 22 | import java.util.List; | 22 | import java.util.List; |
| 23 | -import cn.iocoder.yudao.framework.common.pojo.PageResult; | 23 | + |
| 24 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 24 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 25 | import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | 25 | import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; |
| 26 | 26 | ||
| @@ -69,15 +69,6 @@ public class ReceivableController { | @@ -69,15 +69,6 @@ public class ReceivableController { | ||
| 69 | return success(ReceivableConvert.INSTANCE.convert(receivable)); | 69 | return success(ReceivableConvert.INSTANCE.convert(receivable)); |
| 70 | } | 70 | } |
| 71 | 71 | ||
| 72 | - @GetMapping("/list") | ||
| 73 | - @Operation(summary = "获得回款管理列表") | ||
| 74 | - @Parameter(name = "ids", description = "编号列表", required = true, example = "1024,2048") | ||
| 75 | - @PreAuthorize("@ss.hasPermission('crm:receivable:query')") | ||
| 76 | - public CommonResult<List<ReceivableRespVO>> getReceivableList(@RequestParam("ids") Collection<Long> ids) { | ||
| 77 | - List<ReceivableDO> list = receivableService.getReceivableList(ids); | ||
| 78 | - return success(ReceivableConvert.INSTANCE.convertList(list)); | ||
| 79 | - } | ||
| 80 | - | ||
| 81 | @GetMapping("/page") | 72 | @GetMapping("/page") |
| 82 | @Operation(summary = "获得回款管理分页") | 73 | @Operation(summary = "获得回款管理分页") |
| 83 | @PreAuthorize("@ss.hasPermission('crm:receivable:query')") | 74 | @PreAuthorize("@ss.hasPermission('crm:receivable:query')") |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/ReceivablePlanController.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable; |
| 2 | 2 | ||
| 3 | -import org.springframework.web.bind.annotation.*; | ||
| 4 | -import javax.annotation.Resource; | ||
| 5 | -import org.springframework.validation.annotation.Validated; | ||
| 6 | -import org.springframework.security.access.prepost.PreAuthorize; | ||
| 7 | -import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 8 | -import io.swagger.v3.oas.annotations.Parameter; | ||
| 9 | -import io.swagger.v3.oas.annotations.Operation; | ||
| 10 | - | ||
| 11 | -import javax.validation.constraints.*; | ||
| 12 | -import javax.validation.*; | ||
| 13 | -import javax.servlet.http.*; | ||
| 14 | -import java.util.*; | ||
| 15 | -import java.io.IOException; | ||
| 16 | - | ||
| 17 | -import cn.iocoder.yudao.framework.common.pojo.PageResult; | ||
| 18 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 19 | -import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | ||
| 20 | - | 4 | +import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 21 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 5 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 22 | - | ||
| 23 | import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | 6 | import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; |
| 24 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.*; | ||
| 25 | - | ||
| 26 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; | 7 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; |
| 27 | -import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivablePlanDO; | ||
| 28 | import cn.iocoder.yudao.module.crm.convert.receivable.ReceivablePlanConvert; | 8 | import cn.iocoder.yudao.module.crm.convert.receivable.ReceivablePlanConvert; |
| 9 | +import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivablePlanDO; | ||
| 29 | import cn.iocoder.yudao.module.crm.service.receivable.ReceivablePlanService; | 10 | import cn.iocoder.yudao.module.crm.service.receivable.ReceivablePlanService; |
| 11 | +import io.swagger.v3.oas.annotations.Operation; | ||
| 12 | +import io.swagger.v3.oas.annotations.Parameter; | ||
| 13 | +import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 14 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 15 | +import org.springframework.validation.annotation.Validated; | ||
| 16 | +import org.springframework.web.bind.annotation.*; | ||
| 17 | + | ||
| 18 | +import javax.annotation.Resource; | ||
| 19 | +import javax.servlet.http.HttpServletResponse; | ||
| 20 | +import javax.validation.Valid; | ||
| 21 | +import java.io.IOException; | ||
| 22 | +import java.util.List; | ||
| 23 | + | ||
| 24 | +import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | ||
| 25 | +import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 30 | 26 | ||
| 31 | /** | 27 | /** |
| 32 | * @author 赤焰 | 28 | * @author 赤焰 |
| @@ -73,15 +69,6 @@ public class ReceivablePlanController { | @@ -73,15 +69,6 @@ public class ReceivablePlanController { | ||
| 73 | return success(ReceivablePlanConvert.INSTANCE.convert(receivablePlan)); | 69 | return success(ReceivablePlanConvert.INSTANCE.convert(receivablePlan)); |
| 74 | } | 70 | } |
| 75 | 71 | ||
| 76 | - @GetMapping("/list") | ||
| 77 | - @Operation(summary = "获得回款计划列表") | ||
| 78 | - @Parameter(name = "ids", description = "编号列表", required = true, example = "1024,2048") | ||
| 79 | - @PreAuthorize("@ss.hasPermission('crm:receivable-plan:query')") | ||
| 80 | - public CommonResult<List<ReceivablePlanRespVO>> getReceivablePlanList(@RequestParam("ids") Collection<Long> ids) { | ||
| 81 | - List<ReceivablePlanDO> list = receivablePlanService.getReceivablePlanList(ids); | ||
| 82 | - return success(ReceivablePlanConvert.INSTANCE.convertList(list)); | ||
| 83 | - } | ||
| 84 | - | ||
| 85 | @GetMapping("/page") | 72 | @GetMapping("/page") |
| 86 | @Operation(summary = "获得回款计划分页") | 73 | @Operation(summary = "获得回款计划分页") |
| 87 | @PreAuthorize("@ss.hasPermission('crm:receivable-plan:query')") | 74 | @PreAuthorize("@ss.hasPermission('crm:receivable-plan:query')") |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/ReceivableBaseVO.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; |
| 2 | 2 | ||
| 3 | import io.swagger.v3.oas.annotations.media.Schema; | 3 | import io.swagger.v3.oas.annotations.media.Schema; |
| 4 | -import lombok.*; | ||
| 5 | -import java.util.*; | ||
| 6 | -import java.time.LocalDateTime; | 4 | +import lombok.Data; |
| 5 | +import org.springframework.format.annotation.DateTimeFormat; | ||
| 6 | + | ||
| 7 | +import javax.validation.constraints.NotNull; | ||
| 7 | import java.math.BigDecimal; | 8 | import java.math.BigDecimal; |
| 8 | import java.time.LocalDateTime; | 9 | import java.time.LocalDateTime; |
| 9 | -import java.time.LocalDateTime; | ||
| 10 | -import javax.validation.constraints.*; | ||
| 11 | -import org.springframework.format.annotation.DateTimeFormat; | ||
| 12 | 10 | ||
| 13 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; | 11 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| 14 | 12 | ||
| @@ -19,9 +17,13 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | @@ -19,9 +17,13 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | ||
| 19 | @Data | 17 | @Data |
| 20 | public class ReceivableBaseVO { | 18 | public class ReceivableBaseVO { |
| 21 | 19 | ||
| 20 | + // TODO @liuhongfeng:部分缺少 example 的字段,要补充下; | ||
| 21 | + // TODO @liuhongfeng:部分字段,需要必传,要写 requiredMode = Schema.RequiredMode.REQUIRED,以及对应的 validator 非空校验 | ||
| 22 | + | ||
| 22 | @Schema(description = "回款编号") | 23 | @Schema(description = "回款编号") |
| 23 | private String no; | 24 | private String no; |
| 24 | 25 | ||
| 26 | + // TODO @liuhongfeng:中英文之间,有个空格,这样更干净; | ||
| 25 | @Schema(description = "回款计划ID", example = "31177") | 27 | @Schema(description = "回款计划ID", example = "31177") |
| 26 | private Long planId; | 28 | private Long planId; |
| 27 | 29 | ||
| @@ -31,9 +33,12 @@ public class ReceivableBaseVO { | @@ -31,9 +33,12 @@ public class ReceivableBaseVO { | ||
| 31 | @Schema(description = "合同ID", example = "30305") | 33 | @Schema(description = "合同ID", example = "30305") |
| 32 | private Long contractId; | 34 | private Long contractId; |
| 33 | 35 | ||
| 36 | + // TODO @liuhongfeng:这个字段,可以写个枚举,然后 InEnum 去校验下; | ||
| 37 | + // TODO @liuhongfeng:这个字段,应该不是前端传递的噢,而是后端自己生成的 | ||
| 34 | @Schema(description = "审批状态", example = "1") | 38 | @Schema(description = "审批状态", example = "1") |
| 35 | private Integer checkStatus; | 39 | private Integer checkStatus; |
| 36 | 40 | ||
| 41 | + // TODO @liuhongfeng:这个字段,应该不是前端传递的噢,而是后端自己生成的,所以不适合放在 base 里面; | ||
| 37 | @Schema(description = "工作流编号", example = "16568") | 42 | @Schema(description = "工作流编号", example = "16568") |
| 38 | private Long processInstanceId; | 43 | private Long processInstanceId; |
| 39 | 44 | ||
| @@ -44,6 +49,7 @@ public class ReceivableBaseVO { | @@ -44,6 +49,7 @@ public class ReceivableBaseVO { | ||
| 44 | @Schema(description = "回款方式", example = "2") | 49 | @Schema(description = "回款方式", example = "2") |
| 45 | private String returnType; | 50 | private String returnType; |
| 46 | 51 | ||
| 52 | + // TODO @liuhongfeng:使用 Int 哈,分; | ||
| 47 | @Schema(description = "回款金额", example = "31859") | 53 | @Schema(description = "回款金额", example = "31859") |
| 48 | private BigDecimal price; | 54 | private BigDecimal price; |
| 49 | 55 | ||
| @@ -56,12 +62,14 @@ public class ReceivableBaseVO { | @@ -56,12 +62,14 @@ public class ReceivableBaseVO { | ||
| 56 | @Schema(description = "显示顺序") | 62 | @Schema(description = "显示顺序") |
| 57 | private Integer sort; | 63 | private Integer sort; |
| 58 | 64 | ||
| 65 | + // TODO @芋艿:这个字段在看看;dataScope、dataScopeDeptIds | ||
| 59 | @Schema(description = "数据范围(1:全部数据权限 2:自定数据权限 3:本部门数据权限 4:本部门及以下数据权限)") | 66 | @Schema(description = "数据范围(1:全部数据权限 2:自定数据权限 3:本部门数据权限 4:本部门及以下数据权限)") |
| 60 | private Integer dataScope; | 67 | private Integer dataScope; |
| 61 | 68 | ||
| 62 | @Schema(description = "数据范围(指定部门数组)") | 69 | @Schema(description = "数据范围(指定部门数组)") |
| 63 | private String dataScopeDeptIds; | 70 | private String dataScopeDeptIds; |
| 64 | 71 | ||
| 72 | + // TODO @liuhongfeng:这个字段,这个字段,应该不是前端传递的噢,而是后端自己生成的,所以不适合放在 base 里面; | ||
| 65 | @Schema(description = "状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") | 73 | @Schema(description = "状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| 66 | @NotNull(message = "状态不能为空") | 74 | @NotNull(message = "状态不能为空") |
| 67 | private Integer status; | 75 | private Integer status; |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/ReceivablePageReqVO.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; |
| 2 | 2 | ||
| 3 | -import lombok.*; | ||
| 4 | - | ||
| 5 | -import java.math.BigDecimal; | ||
| 6 | -import java.util.*; | ||
| 7 | -import io.swagger.v3.oas.annotations.media.Schema; | ||
| 8 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 3 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 4 | +import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | +import lombok.Data; | ||
| 6 | +import lombok.EqualsAndHashCode; | ||
| 7 | +import lombok.ToString; | ||
| 9 | import org.springframework.format.annotation.DateTimeFormat; | 8 | import org.springframework.format.annotation.DateTimeFormat; |
| 9 | + | ||
| 10 | +import java.math.BigDecimal; | ||
| 10 | import java.time.LocalDateTime; | 11 | import java.time.LocalDateTime; |
| 11 | 12 | ||
| 12 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; | 13 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| @@ -17,6 +18,7 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | @@ -17,6 +18,7 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | ||
| 17 | @ToString(callSuper = true) | 18 | @ToString(callSuper = true) |
| 18 | public class ReceivablePageReqVO extends PageParam { | 19 | public class ReceivablePageReqVO extends PageParam { |
| 19 | 20 | ||
| 21 | + // TODO @liuhongfeng:目前就使用 no 检索即可; | ||
| 20 | @Schema(description = "回款编号") | 22 | @Schema(description = "回款编号") |
| 21 | private String no; | 23 | private String no; |
| 22 | 24 |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/ReceivablePlanBaseVO.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; |
| 2 | 2 | ||
| 3 | import io.swagger.v3.oas.annotations.media.Schema; | 3 | import io.swagger.v3.oas.annotations.media.Schema; |
| 4 | -import lombok.*; | ||
| 5 | -import java.util.*; | 4 | +import lombok.Data; |
| 5 | +import org.springframework.format.annotation.DateTimeFormat; | ||
| 6 | + | ||
| 6 | import java.math.BigDecimal; | 7 | import java.math.BigDecimal; |
| 7 | import java.time.LocalDateTime; | 8 | import java.time.LocalDateTime; |
| 8 | -import java.time.LocalDateTime; | ||
| 9 | -import java.time.LocalDateTime; | ||
| 10 | -import java.time.LocalDateTime; | ||
| 11 | -import javax.validation.constraints.*; | ||
| 12 | -import org.springframework.format.annotation.DateTimeFormat; | ||
| 13 | 9 | ||
| 14 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; | 10 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| 15 | 11 | ||
| @@ -20,9 +16,11 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | @@ -20,9 +16,11 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | ||
| 20 | @Data | 16 | @Data |
| 21 | public class ReceivablePlanBaseVO { | 17 | public class ReceivablePlanBaseVO { |
| 22 | 18 | ||
| 19 | + // TODO 芋艿:这个字段,在想想命名; | ||
| 23 | @Schema(description = "期数") | 20 | @Schema(description = "期数") |
| 24 | private Long indexNo; | 21 | private Long indexNo; |
| 25 | 22 | ||
| 23 | + // TODO @liuhongfeng:中英文之间,有个空格,这样更干净; | ||
| 26 | @Schema(description = "回款ID", example = "19852") | 24 | @Schema(description = "回款ID", example = "19852") |
| 27 | private Long receivableId; | 25 | private Long receivableId; |
| 28 | 26 | ||
| @@ -30,12 +28,16 @@ public class ReceivablePlanBaseVO { | @@ -30,12 +28,16 @@ public class ReceivablePlanBaseVO { | ||
| 30 | //@NotNull(message = "完成状态不能为空") | 28 | //@NotNull(message = "完成状态不能为空") |
| 31 | private Integer status; | 29 | private Integer status; |
| 32 | 30 | ||
| 31 | + // TODO @liuhongfeng:这个字段,可以写个枚举,然后 InEnum 去校验下; | ||
| 32 | + // TODO @liuhongfeng:这个字段,应该不是前端传递的噢,而是后端自己生成的 | ||
| 33 | @Schema(description = "审批状态", example = "1") | 33 | @Schema(description = "审批状态", example = "1") |
| 34 | private String checkStatus; | 34 | private String checkStatus; |
| 35 | 35 | ||
| 36 | + // TODO @liuhongfeng:这个字段,应该不是前端传递的噢,而是后端自己生成的,所以不适合放在 base 里面; | ||
| 36 | @Schema(description = "工作流编号", example = "8909") | 37 | @Schema(description = "工作流编号", example = "8909") |
| 37 | private Long processInstanceId; | 38 | private Long processInstanceId; |
| 38 | 39 | ||
| 40 | + // TODO @liuhongfeng:使用 Int 哈,分; | ||
| 39 | @Schema(description = "计划回款金额", example = "29675") | 41 | @Schema(description = "计划回款金额", example = "29675") |
| 40 | private BigDecimal price; | 42 | private BigDecimal price; |
| 41 | 43 | ||
| @@ -43,6 +45,7 @@ public class ReceivablePlanBaseVO { | @@ -43,6 +45,7 @@ public class ReceivablePlanBaseVO { | ||
| 43 | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) | 45 | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| 44 | private LocalDateTime returnTime; | 46 | private LocalDateTime returnTime; |
| 45 | 47 | ||
| 48 | + // TODO @liuhongfeng:这个字段,Integer | ||
| 46 | @Schema(description = "提前几天提醒") | 49 | @Schema(description = "提前几天提醒") |
| 47 | private Long remindDays; | 50 | private Long remindDays; |
| 48 | 51 | ||
| @@ -56,6 +59,7 @@ public class ReceivablePlanBaseVO { | @@ -56,6 +59,7 @@ public class ReceivablePlanBaseVO { | ||
| 56 | @Schema(description = "合同ID", example = "3473") | 59 | @Schema(description = "合同ID", example = "3473") |
| 57 | private Long contractId; | 60 | private Long contractId; |
| 58 | 61 | ||
| 62 | + // TODO @liuhongfeng:这个字段,应该不是前端传递的噢,而是后端自己生成的,所以不适合放在 base 里面; | ||
| 59 | @Schema(description = "负责人", example = "17828") | 63 | @Schema(description = "负责人", example = "17828") |
| 60 | private Long ownerUserId; | 64 | private Long ownerUserId; |
| 61 | 65 |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/ReceivablePlanPageReqVO.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo; |
| 2 | 2 | ||
| 3 | -import lombok.*; | ||
| 4 | -import java.util.*; | ||
| 5 | -import io.swagger.v3.oas.annotations.media.Schema; | ||
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 3 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 4 | +import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | +import lombok.Data; | ||
| 6 | +import lombok.EqualsAndHashCode; | ||
| 7 | +import lombok.ToString; | ||
| 7 | import org.springframework.format.annotation.DateTimeFormat; | 8 | import org.springframework.format.annotation.DateTimeFormat; |
| 9 | + | ||
| 8 | import java.time.LocalDateTime; | 10 | import java.time.LocalDateTime; |
| 9 | 11 | ||
| 10 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; | 12 | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| @@ -15,6 +17,8 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | @@ -15,6 +17,8 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_ | ||
| 15 | @ToString(callSuper = true) | 17 | @ToString(callSuper = true) |
| 16 | public class ReceivablePlanPageReqVO extends PageParam { | 18 | public class ReceivablePlanPageReqVO extends PageParam { |
| 17 | 19 | ||
| 20 | + // TODO 芋艿:筛选字段,需要去掉几个,在想想; | ||
| 21 | + | ||
| 18 | @Schema(description = "期数") | 22 | @Schema(description = "期数") |
| 19 | private Long indexNo; | 23 | private Long indexNo; |
| 20 | 24 |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/dal/dataobject/receivable/ReceivableDO.java
| 1 | package cn.iocoder.yudao.module.crm.dal.dataobject.receivable; | 1 | package cn.iocoder.yudao.module.crm.dal.dataobject.receivable; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; | ||
| 4 | +import com.baomidou.mybatisplus.annotation.KeySequence; | ||
| 5 | +import com.baomidou.mybatisplus.annotation.TableId; | ||
| 6 | +import com.baomidou.mybatisplus.annotation.TableName; | ||
| 3 | import lombok.*; | 7 | import lombok.*; |
| 4 | -import java.util.*; | ||
| 5 | -import java.time.LocalDateTime; | 8 | + |
| 6 | import java.math.BigDecimal; | 9 | import java.math.BigDecimal; |
| 7 | import java.time.LocalDateTime; | 10 | import java.time.LocalDateTime; |
| 8 | -import java.time.LocalDateTime; | ||
| 9 | -import com.baomidou.mybatisplus.annotation.*; | ||
| 10 | -import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; | ||
| 11 | 11 | ||
| 12 | /** | 12 | /** |
| 13 | * 回款管理 DO | 13 | * 回款管理 DO |
| @@ -35,14 +35,20 @@ public class ReceivableDO extends BaseDO { | @@ -35,14 +35,20 @@ public class ReceivableDO extends BaseDO { | ||
| 35 | private String no; | 35 | private String no; |
| 36 | /** | 36 | /** |
| 37 | * 回款计划ID | 37 | * 回款计划ID |
| 38 | + * | ||
| 39 | + * TODO @liuhongfeng:这个字段,后续要写下关联的实体哈 | ||
| 38 | */ | 40 | */ |
| 39 | private Long planId; | 41 | private Long planId; |
| 40 | /** | 42 | /** |
| 41 | * 客户ID | 43 | * 客户ID |
| 44 | + * | ||
| 45 | + * TODO @liuhongfeng:这个字段,后续要写下关联的实体哈 | ||
| 42 | */ | 46 | */ |
| 43 | private Long customerId; | 47 | private Long customerId; |
| 44 | /** | 48 | /** |
| 45 | * 合同ID | 49 | * 合同ID |
| 50 | + * | ||
| 51 | + * TODO @liuhongfeng:这个字段,后续要写下关联的实体哈 | ||
| 46 | */ | 52 | */ |
| 47 | private Long contractId; | 53 | private Long contractId; |
| 48 | /** | 54 | /** |
| @@ -53,6 +59,8 @@ public class ReceivableDO extends BaseDO { | @@ -53,6 +59,8 @@ public class ReceivableDO extends BaseDO { | ||
| 53 | private Integer checkStatus; | 59 | private Integer checkStatus; |
| 54 | /** | 60 | /** |
| 55 | * 工作流编号 | 61 | * 工作流编号 |
| 62 | + * | ||
| 63 | + * TODO @liuhongfeng:这个字段,后续要写下关联的实体哈 | ||
| 56 | */ | 64 | */ |
| 57 | private Long processInstanceId; | 65 | private Long processInstanceId; |
| 58 | /** | 66 | /** |
| @@ -79,6 +87,7 @@ public class ReceivableDO extends BaseDO { | @@ -79,6 +87,7 @@ public class ReceivableDO extends BaseDO { | ||
| 79 | * 显示顺序 | 87 | * 显示顺序 |
| 80 | */ | 88 | */ |
| 81 | private Integer sort; | 89 | private Integer sort; |
| 90 | + // TODO 芋艿:dataScope、dataScopeDeptIds 在想下; | ||
| 82 | /** | 91 | /** |
| 83 | * 数据范围(1:全部数据权限 2:自定数据权限 3:本部门数据权限 4:本部门及以下数据权限) | 92 | * 数据范围(1:全部数据权限 2:自定数据权限 3:本部门数据权限 4:本部门及以下数据权限) |
| 84 | */ | 93 | */ |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/service/receivable/ReceivablePlanServiceImpl.java
| 1 | package cn.iocoder.yudao.module.crm.service.receivable; | 1 | package cn.iocoder.yudao.module.crm.service.receivable; |
| 2 | 2 | ||
| 3 | +import cn.hutool.core.collection.CollUtil; | ||
| 4 | +import cn.hutool.core.collection.ListUtil; | ||
| 3 | import cn.hutool.core.util.ObjectUtil; | 5 | import cn.hutool.core.util.ObjectUtil; |
| 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 6 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 5 | -import org.springframework.stereotype.Service; | ||
| 6 | -import javax.annotation.Resource; | ||
| 7 | -import org.springframework.validation.annotation.Validated; | ||
| 8 | - | ||
| 9 | -import java.util.*; | ||
| 10 | -import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; | ||
| 11 | -import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivablePlanDO; | ||
| 12 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 13 | - | 8 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanCreateReqVO; |
| 9 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanExportReqVO; | ||
| 10 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanPageReqVO; | ||
| 11 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanUpdateReqVO; | ||
| 14 | import cn.iocoder.yudao.module.crm.convert.receivable.ReceivablePlanConvert; | 12 | import cn.iocoder.yudao.module.crm.convert.receivable.ReceivablePlanConvert; |
| 13 | +import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivablePlanDO; | ||
| 15 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivablePlanMapper; | 14 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivablePlanMapper; |
| 15 | +import org.springframework.stereotype.Service; | ||
| 16 | +import org.springframework.validation.annotation.Validated; | ||
| 16 | 17 | ||
| 17 | -import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; | ||
| 18 | -import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.*; | 18 | +import javax.annotation.Resource; |
| 19 | +import java.util.Collection; | ||
| 20 | +import java.util.List; | ||
| 19 | 21 | ||
| 20 | -import cn.hutool.core.collection.CollUtil; | ||
| 21 | -import cn.hutool.core.collection.ListUtil; | 22 | +import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| 23 | +import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.RECEIVABLE_PLAN_NOT_EXISTS; | ||
| 22 | 24 | ||
| 23 | /** | 25 | /** |
| 24 | * 回款计划 Service 实现类 | 26 | * 回款计划 Service 实现类 |
| @@ -36,6 +38,7 @@ public class ReceivablePlanServiceImpl implements ReceivablePlanService { | @@ -36,6 +38,7 @@ public class ReceivablePlanServiceImpl implements ReceivablePlanService { | ||
| 36 | public Long createReceivablePlan(ReceivablePlanCreateReqVO createReqVO) { | 38 | public Long createReceivablePlan(ReceivablePlanCreateReqVO createReqVO) { |
| 37 | // 插入 | 39 | // 插入 |
| 38 | ReceivablePlanDO receivablePlan = ReceivablePlanConvert.INSTANCE.convert(createReqVO); | 40 | ReceivablePlanDO receivablePlan = ReceivablePlanConvert.INSTANCE.convert(createReqVO); |
| 41 | + // TODO @liuhongfeng:空格要注释;if (ObjectUtil.isNull(receivablePlan.getStatus())) { | ||
| 39 | if(ObjectUtil.isNull(receivablePlan.getStatus())){ | 42 | if(ObjectUtil.isNull(receivablePlan.getStatus())){ |
| 40 | receivablePlan.setStatus(CommonStatusEnum.ENABLE.getStatus()); | 43 | receivablePlan.setStatus(CommonStatusEnum.ENABLE.getStatus()); |
| 41 | } | 44 | } |
| @@ -48,6 +51,7 @@ public class ReceivablePlanServiceImpl implements ReceivablePlanService { | @@ -48,6 +51,7 @@ public class ReceivablePlanServiceImpl implements ReceivablePlanService { | ||
| 48 | public void updateReceivablePlan(ReceivablePlanUpdateReqVO updateReqVO) { | 51 | public void updateReceivablePlan(ReceivablePlanUpdateReqVO updateReqVO) { |
| 49 | // 校验存在 | 52 | // 校验存在 |
| 50 | validateReceivablePlanExists(updateReqVO.getId()); | 53 | validateReceivablePlanExists(updateReqVO.getId()); |
| 54 | + | ||
| 51 | // 更新 | 55 | // 更新 |
| 52 | ReceivablePlanDO updateObj = ReceivablePlanConvert.INSTANCE.convert(updateReqVO); | 56 | ReceivablePlanDO updateObj = ReceivablePlanConvert.INSTANCE.convert(updateReqVO); |
| 53 | receivablePlanMapper.updateById(updateObj); | 57 | receivablePlanMapper.updateById(updateObj); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/service/receivable/ReceivableServiceImpl.java
| 1 | package cn.iocoder.yudao.module.crm.service.receivable; | 1 | package cn.iocoder.yudao.module.crm.service.receivable; |
| 2 | 2 | ||
| 3 | -import org.springframework.stereotype.Service; | ||
| 4 | -import javax.annotation.Resource; | ||
| 5 | -import org.springframework.validation.annotation.Validated; | 3 | +import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.hutool.core.collection.ListUtil; | ||
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | -import java.util.*; | ||
| 8 | -import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; | ||
| 9 | -import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivableDO; | ||
| 10 | - | 6 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivableCreateReqVO; |
| 7 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivableExportReqVO; | ||
| 8 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePageReqVO; | ||
| 9 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivableUpdateReqVO; | ||
| 11 | import cn.iocoder.yudao.module.crm.convert.receivable.ReceivableConvert; | 10 | import cn.iocoder.yudao.module.crm.convert.receivable.ReceivableConvert; |
| 11 | +import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivableDO; | ||
| 12 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivableMapper; | 12 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivableMapper; |
| 13 | +import org.springframework.stereotype.Service; | ||
| 14 | +import org.springframework.validation.annotation.Validated; | ||
| 13 | 15 | ||
| 14 | -import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; | ||
| 15 | -import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.*; | 16 | +import javax.annotation.Resource; |
| 17 | +import java.util.Collection; | ||
| 18 | +import java.util.List; | ||
| 16 | 19 | ||
| 17 | -import cn.hutool.core.collection.CollUtil; | ||
| 18 | -import cn.hutool.core.collection.ListUtil; | 20 | +import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| 21 | +import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.RECEIVABLE_NOT_EXISTS; | ||
| 19 | 22 | ||
| 20 | /** | 23 | /** |
| 21 | * 回款管理 Service 实现类 | 24 | * 回款管理 Service 实现类 |
| @@ -31,6 +34,8 @@ public class ReceivableServiceImpl implements ReceivableService { | @@ -31,6 +34,8 @@ public class ReceivableServiceImpl implements ReceivableService { | ||
| 31 | 34 | ||
| 32 | @Override | 35 | @Override |
| 33 | public Long createReceivable(ReceivableCreateReqVO createReqVO) { | 36 | public Long createReceivable(ReceivableCreateReqVO createReqVO) { |
| 37 | + // TODO @liuhongfeng:planId 是否存在,是否合法,需要去校验; | ||
| 38 | + // TODO @liuhongfeng:其它类似 customerId、contractId 也需要去校验; | ||
| 34 | // 插入 | 39 | // 插入 |
| 35 | ReceivableDO receivable = ReceivableConvert.INSTANCE.convert(createReqVO); | 40 | ReceivableDO receivable = ReceivableConvert.INSTANCE.convert(createReqVO); |
| 36 | receivableMapper.insert(receivable); | 41 | receivableMapper.insert(receivable); |
| @@ -42,6 +47,7 @@ public class ReceivableServiceImpl implements ReceivableService { | @@ -42,6 +47,7 @@ public class ReceivableServiceImpl implements ReceivableService { | ||
| 42 | public void updateReceivable(ReceivableUpdateReqVO updateReqVO) { | 47 | public void updateReceivable(ReceivableUpdateReqVO updateReqVO) { |
| 43 | // 校验存在 | 48 | // 校验存在 |
| 44 | validateReceivableExists(updateReqVO.getId()); | 49 | validateReceivableExists(updateReqVO.getId()); |
| 50 | + | ||
| 45 | // 更新 | 51 | // 更新 |
| 46 | ReceivableDO updateObj = ReceivableConvert.INSTANCE.convert(updateReqVO); | 52 | ReceivableDO updateObj = ReceivableConvert.INSTANCE.convert(updateReqVO); |
| 47 | receivableMapper.updateById(updateObj); | 53 | receivableMapper.updateById(updateObj); |
yudao-module-crm/yudao-module-crm-biz/src/test/java/cn/iocoder/yudao/module/crm/service/receivable/ReceivablePlanServiceImplTest.java
| 1 | package cn.iocoder.yudao.module.crm.service.receivable; | 1 | package cn.iocoder.yudao.module.crm.service.receivable; |
| 2 | 2 | ||
| 3 | -import org.junit.jupiter.api.Disabled; | ||
| 4 | -import org.junit.jupiter.api.Test; | ||
| 5 | -import org.springframework.boot.test.mock.mockito.MockBean; | ||
| 6 | - | ||
| 7 | -import javax.annotation.Resource; | ||
| 8 | - | 3 | +import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 9 | import cn.iocoder.yudao.framework.test.core.ut.BaseDbUnitTest; | 4 | import cn.iocoder.yudao.framework.test.core.ut.BaseDbUnitTest; |
| 10 | - | ||
| 11 | -import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; | 5 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanCreateReqVO; |
| 6 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanExportReqVO; | ||
| 7 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanPageReqVO; | ||
| 8 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePlanUpdateReqVO; | ||
| 12 | import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivablePlanDO; | 9 | import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivablePlanDO; |
| 13 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivablePlanMapper; | 10 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivablePlanMapper; |
| 14 | -import cn.iocoder.yudao.framework.common.pojo.PageResult; | 11 | +import org.junit.jupiter.api.Disabled; |
| 12 | +import org.junit.jupiter.api.Test; | ||
| 13 | +import org.springframework.context.annotation.Import; | ||
| 15 | 14 | ||
| 16 | import javax.annotation.Resource; | 15 | import javax.annotation.Resource; |
| 17 | -import org.springframework.context.annotation.Import; | ||
| 18 | -import java.util.*; | ||
| 19 | -import java.time.LocalDateTime; | ||
| 20 | - | ||
| 21 | -import static cn.hutool.core.util.RandomUtil.*; | ||
| 22 | -import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.*; | ||
| 23 | -import static cn.iocoder.yudao.framework.test.core.util.AssertUtils.*; | ||
| 24 | -import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.*; | ||
| 25 | -import static cn.iocoder.yudao.framework.common.util.date.LocalDateTimeUtils.*; | ||
| 26 | -import static cn.iocoder.yudao.framework.common.util.object.ObjectUtils.*; | ||
| 27 | -import static cn.iocoder.yudao.framework.common.util.date.DateUtils.*; | 16 | +import java.util.List; |
| 17 | + | ||
| 18 | +import static cn.iocoder.yudao.framework.common.util.date.LocalDateTimeUtils.buildBetweenTime; | ||
| 19 | +import static cn.iocoder.yudao.framework.common.util.object.ObjectUtils.cloneIgnoreId; | ||
| 20 | +import static cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals; | ||
| 21 | +import static cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertServiceException; | ||
| 22 | +import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomLongId; | ||
| 23 | +import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo; | ||
| 24 | +import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.RECEIVABLE_PLAN_NOT_EXISTS; | ||
| 28 | import static org.junit.jupiter.api.Assertions.*; | 25 | import static org.junit.jupiter.api.Assertions.*; |
| 29 | -import static org.mockito.Mockito.*; | ||
| 30 | 26 | ||
| 27 | +// TODO 芋艿:后续,需要补充测试用例 | ||
| 31 | /** | 28 | /** |
| 32 | * {@link ReceivablePlanServiceImpl} 的单元测试类 | 29 | * {@link ReceivablePlanServiceImpl} 的单元测试类 |
| 33 | * | 30 | * |
yudao-module-crm/yudao-module-crm-biz/src/test/java/cn/iocoder/yudao/module/crm/service/receivable/ReceivableServiceImplTest.java
| 1 | package cn.iocoder.yudao.module.crm.service.receivable; | 1 | package cn.iocoder.yudao.module.crm.service.receivable; |
| 2 | 2 | ||
| 3 | -import org.junit.jupiter.api.Disabled; | ||
| 4 | -import org.junit.jupiter.api.Test; | ||
| 5 | -import org.springframework.boot.test.mock.mockito.MockBean; | ||
| 6 | - | ||
| 7 | -import javax.annotation.Resource; | ||
| 8 | - | 3 | +import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 9 | import cn.iocoder.yudao.framework.test.core.ut.BaseDbUnitTest; | 4 | import cn.iocoder.yudao.framework.test.core.ut.BaseDbUnitTest; |
| 10 | - | ||
| 11 | -import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.*; | 5 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivableCreateReqVO; |
| 6 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivableExportReqVO; | ||
| 7 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivablePageReqVO; | ||
| 8 | +import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.ReceivableUpdateReqVO; | ||
| 12 | import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivableDO; | 9 | import cn.iocoder.yudao.module.crm.dal.dataobject.receivable.ReceivableDO; |
| 13 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivableMapper; | 10 | import cn.iocoder.yudao.module.crm.dal.mysql.receivable.ReceivableMapper; |
| 14 | -import cn.iocoder.yudao.framework.common.pojo.PageResult; | 11 | +import org.junit.jupiter.api.Disabled; |
| 12 | +import org.junit.jupiter.api.Test; | ||
| 13 | +import org.springframework.context.annotation.Import; | ||
| 15 | 14 | ||
| 16 | import javax.annotation.Resource; | 15 | import javax.annotation.Resource; |
| 17 | -import org.springframework.context.annotation.Import; | ||
| 18 | -import java.util.*; | ||
| 19 | -import java.time.LocalDateTime; | 16 | +import java.util.List; |
| 20 | 17 | ||
| 21 | -import static cn.hutool.core.util.RandomUtil.*; | ||
| 22 | -import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.*; | ||
| 23 | -import static cn.iocoder.yudao.framework.test.core.util.AssertUtils.*; | ||
| 24 | -import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.*; | ||
| 25 | -import static cn.iocoder.yudao.framework.common.util.date.LocalDateTimeUtils.*; | ||
| 26 | -import static cn.iocoder.yudao.framework.common.util.object.ObjectUtils.*; | ||
| 27 | -import static cn.iocoder.yudao.framework.common.util.date.DateUtils.*; | 18 | +import static cn.iocoder.yudao.framework.common.util.date.LocalDateTimeUtils.buildBetweenTime; |
| 19 | +import static cn.iocoder.yudao.framework.common.util.object.ObjectUtils.cloneIgnoreId; | ||
| 20 | +import static cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals; | ||
| 21 | +import static cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertServiceException; | ||
| 22 | +import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomLongId; | ||
| 23 | +import static cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo; | ||
| 24 | +import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.RECEIVABLE_NOT_EXISTS; | ||
| 28 | import static org.junit.jupiter.api.Assertions.*; | 25 | import static org.junit.jupiter.api.Assertions.*; |
| 29 | -import static org.mockito.Mockito.*; | ||
| 30 | 26 | ||
| 27 | +// TODO 芋艿:等实现完,在校验下; | ||
| 31 | /** | 28 | /** |
| 32 | * {@link ReceivableServiceImpl} 的单元测试类 | 29 | * {@link ReceivableServiceImpl} 的单元测试类 |
| 33 | * | 30 | * |