Browse Source

用户申请商户入驻商城

Yangzw 7 months ago
parent
commit
27ae151a6d
39 changed files with 785 additions and 253 deletions
  1. 2 2
      feifan-module-distri/feifan-module-distri-biz/src/main/java/cn/newfeifan/mall/module/distri/dal/mysql/ptprofitlog/PtProfitLogMapper.java
  2. 1 0
      feifan-module-mall/feifan-module-sale-api/src/main/java/cn/newfeifan/mall/module/sale/enums/ErrorCodeConstants.java
  3. 22 0
      feifan-module-mall/feifan-module-sale-api/src/main/java/cn/newfeifan/mall/module/sale/enums/MerchantApplyCheckStatusEnum.java
  4. 6 0
      feifan-module-mall/feifan-module-sale-biz/pom.xml
  5. 0 70
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchantapply/MerchantApplyController.java
  6. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantPageReqVO.java
  7. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantRespVO.java
  8. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantSaveReqByMobileVO.java
  9. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantSaveReqVO.java
  10. 93 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/MerchantApplyController.java
  11. 29 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/vo/MerchantApplyPageReqVO.java
  12. 39 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/vo/MerchantApplyRespVO.java
  13. 39 3
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/vo/MerchantApplySaveReqVO.java
  14. 94 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/MerchantApplyLogController.java
  15. 33 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/vo/MerchantApplyLogPageReqVO.java
  16. 37 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/vo/MerchantApplyLogRespVO.java
  17. 28 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/vo/MerchantApplyLogSaveReqVO.java
  18. 1 2
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shop/vo/ShopPageReqVO.java
  19. 1 4
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shop/vo/ShopRespVO.java
  20. 1 2
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shop/vo/ShopSaveReqVO.java
  21. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shopstatus/vo/ShopStatusPageReqVO.java
  22. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shopstatus/vo/ShopStatusRespVO.java
  23. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shopstatus/vo/ShopStatusSaveReqVO.java
  24. 37 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/dataobject/merchantapply/MerchantApplyDO.java
  25. 44 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/dataobject/merchantapplylog/MerchantApplyLogDO.java
  26. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/merchant/MerchantMapper.java
  27. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/merchantapply/MerchantApplyMapper.java
  28. 28 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/merchantapplylog/MerchantApplyLogMapper.java
  29. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/shop/ShopMapper.java
  30. 1 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/shopstatus/ShopStatusMapper.java
  31. 9 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapply/MerchantApplyService.java
  32. 49 1
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapply/MerchantApplyServiceImpl.java
  33. 55 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapplylog/MerchantApplyLogService.java
  34. 72 0
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapplylog/MerchantApplyLogServiceImpl.java
  35. 1 3
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/shop/ShopService.java
  36. 1 6
      feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/shop/ShopServiceImpl.java
  37. 12 0
      feifan-module-mall/feifan-module-sale-biz/src/main/resources/mapper/merchantapplylog/MerchantApplyLogMapper.xml
  38. 0 146
      feifan-module-mall/feifan-module-sale-biz/src/test/java/cn/newfeifan/mall/module/sale/service/shop/ShopServiceImplTest.java
  39. 40 0
      feifan-module-system/feifan-module-system-biz/src/main/java/cn/newfeifan/mall/module/system/controller/app/user/UsersController.java

+ 2 - 2
feifan-module-distri/feifan-module-distri-biz/src/main/java/cn/newfeifan/mall/module/distri/dal/mysql/ptprofitlog/PtProfitLogMapper.java

@@ -50,7 +50,7 @@ public interface PtProfitLogMapper extends BaseMapperX<PtProfitLogDO> {
                     WITHDRAWAL.getType(),
                     WITHDRAWAL_ERROR.getType()
             );
-            queryWrapper.ne(PtProfitLogDO::getAmount,0);
+//            queryWrapper.ne(PtProfitLogDO::getAmount,0);
         } else {
             //冻结
             profitStatus = Arrays.asList(
@@ -61,7 +61,7 @@ public interface PtProfitLogMapper extends BaseMapperX<PtProfitLogDO> {
                     ORDER_REFUND_INTEGRAL_CONSUMER.getType(),
                     ORDER_REFUND_INTEGRAL_ANCESTER.getType(),
                     ORDER_PAY_INTEGRAL_CONSUMER.getType());
-            queryWrapper.ne(PtProfitLogDO::getFreezeAmount,0);
+//            queryWrapper.ne(PtProfitLogDO::getFreezeAmount,0);
         }
 
         if (!reqVO.getIsFreeze() && reqVO.getUserId().equals(PT_ID)) {

+ 1 - 0
feifan-module-mall/feifan-module-sale-api/src/main/java/cn/newfeifan/mall/module/sale/enums/ErrorCodeConstants.java

@@ -16,4 +16,5 @@ public interface ErrorCodeConstants {
     ErrorCode SHOP_NOT_EXISTS = new ErrorCode(1_101_001_001, "店铺不存在");
 
     ErrorCode MERCHANT_APPLY_NOT_EXISTS = new ErrorCode(1_002_029_003, "商户申请不存在");
+    ErrorCode MERCHANT_APPLY_LOG_NOT_EXISTS = new ErrorCode(1_002_029_004, "商户申请记录不存在");
 }

+ 22 - 0
feifan-module-mall/feifan-module-sale-api/src/main/java/cn/newfeifan/mall/module/sale/enums/MerchantApplyCheckStatusEnum.java

@@ -0,0 +1,22 @@
+package cn.newfeifan.mall.module.sale.enums;
+
+import lombok.Getter;
+import lombok.RequiredArgsConstructor;
+
+/**
+ * 商户申请状态枚举类
+ */
+
+@RequiredArgsConstructor
+@Getter
+public enum MerchantApplyCheckStatusEnum {
+
+    WAIT_AUDIT(0, "审核中"),
+    AUDIT_PASS(1, "审核通过"),
+    AUDIT_FAIL(2, "审核不通过"),
+    ;
+
+    private final Integer type;
+
+    private final String name;
+}

+ 6 - 0
feifan-module-mall/feifan-module-sale-biz/pom.xml

@@ -72,6 +72,12 @@
             <version>2.0.0-jdk8-snapshot</version>
             <scope>compile</scope>
         </dependency>
+        <dependency>
+            <groupId>cn.newfeifan.zx</groupId>
+            <artifactId>feifan-module-system-biz</artifactId>
+            <version>2.0.0-jdk8-snapshot</version>
+            <scope>compile</scope>
+        </dependency>
     </dependencies>
 
 </project>

+ 0 - 70
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchantapply/MerchantApplyController.java

@@ -1,70 +0,0 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchantapply;
-
-import cn.newfeifan.mall.framework.security.core.annotations.PreAuthenticated;
-import org.springframework.web.bind.annotation.*;
-import javax.annotation.Resource;
-import org.springframework.validation.annotation.Validated;
-import io.swagger.v3.oas.annotations.tags.Tag;
-import io.swagger.v3.oas.annotations.Parameter;
-import io.swagger.v3.oas.annotations.Operation;
-
-import javax.validation.*;
-import cn.newfeifan.mall.framework.common.pojo.PageResult;
-import cn.newfeifan.mall.framework.common.pojo.CommonResult;
-import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
-import static cn.newfeifan.mall.framework.common.pojo.CommonResult.success;
-
-import cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo.*;
-import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapply.MerchantApplyDO;
-import cn.newfeifan.mall.module.sale.service.merchantapply.MerchantApplyService;
-
-@Tag(name = "管理后台 - 商户申请")
-@RestController
-@RequestMapping("/sale/merchant-apply")
-@Validated
-public class MerchantApplyController {
-
-    @Resource
-    private MerchantApplyService merchantApplyService;
-
-    @PostMapping("/create")
-    @Operation(summary = "创建商户申请")
-    @PreAuthenticated
-    public CommonResult<Long> createMerchantApply(@Valid @RequestBody MerchantApplySaveReqVO createReqVO) {
-        return success(merchantApplyService.createMerchantApply(createReqVO));
-    }
-
-    @PutMapping("/update")
-    @Operation(summary = "更新商户申请")
-    @PreAuthenticated
-    public CommonResult<Boolean> updateMerchantApply(@Valid @RequestBody MerchantApplySaveReqVO updateReqVO) {
-        merchantApplyService.updateMerchantApply(updateReqVO);
-        return success(true);
-    }
-
-    @DeleteMapping("/delete")
-    @Operation(summary = "删除商户申请")
-    @Parameter(name = "id", description = "编号", required = true)
-    @PreAuthenticated
-    public CommonResult<Boolean> deleteMerchantApply(@RequestParam("id") Long id) {
-        merchantApplyService.deleteMerchantApply(id);
-        return success(true);
-    }
-
-    @GetMapping("/get")
-    @Operation(summary = "获得商户申请")
-    @Parameter(name = "id", description = "编号", required = true, example = "1024")
-    @PreAuthenticated
-    public CommonResult<MerchantApplyRespVO> getMerchantApply(@RequestParam("id") Long id) {
-        MerchantApplyDO merchantApply = merchantApplyService.getMerchantApply(id);
-        return success(BeanUtils.toBean(merchantApply, MerchantApplyRespVO.class));
-    }
-
-    @GetMapping("/page")
-    @Operation(summary = "获得商户申请分页")
-    @PreAuthenticated
-    public CommonResult<PageResult<MerchantApplyRespVO>> getMerchantApplyPage(@Valid MerchantApplyPageReqVO pageReqVO) {
-        PageResult<MerchantApplyDO> pageResult = merchantApplyService.getMerchantApplyPage(pageReqVO);
-        return success(BeanUtils.toBean(pageResult, MerchantApplyRespVO.class));
-    }
-}

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchant/vo/MerchantPageReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantPageReqVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchant.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchant.vo;
 
 import cn.newfeifan.mall.framework.common.pojo.PageParam;
 import io.swagger.v3.oas.annotations.media.Schema;

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchant/vo/MerchantRespVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantRespVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchant.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchant.vo;
 
 import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
 import com.alibaba.excel.annotation.ExcelProperty;

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchant/vo/MerchantSaveReqByMobileVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantSaveReqByMobileVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchant.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchant.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.Data;

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchant/vo/MerchantSaveReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchant/vo/MerchantSaveReqVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchant.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchant.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.Data;

+ 93 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/MerchantApplyController.java

@@ -0,0 +1,93 @@
+package cn.newfeifan.mall.module.sale.controller.app.merchantapply;
+
+import cn.newfeifan.mall.framework.security.core.annotations.PreAuthenticated;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplyRespVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplySaveReqVO;
+import org.springframework.web.bind.annotation.*;
+import javax.annotation.Resource;
+import org.springframework.validation.annotation.Validated;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.Operation;
+
+import javax.validation.*;
+import cn.newfeifan.mall.framework.common.pojo.CommonResult;
+import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
+import static cn.newfeifan.mall.framework.common.pojo.CommonResult.success;
+import static cn.newfeifan.mall.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId;
+
+import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapply.MerchantApplyDO;
+import cn.newfeifan.mall.module.sale.service.merchantapply.MerchantApplyService;
+
+import java.util.ArrayList;
+import java.util.List;
+
+@Tag(name = "管理后台 - 商户申请")
+@RestController
+@RequestMapping("/sale/merchant-apply")
+@Validated
+public class MerchantApplyController {
+
+    @Resource
+    private MerchantApplyService merchantApplyService;
+
+    @PostMapping("/create")
+    @Operation(summary = "创建商户申请")
+    @PreAuthenticated
+    public CommonResult<Long> createMerchantApply(@Valid @RequestBody MerchantApplySaveReqVO createReqVO) {
+        return success(merchantApplyService.createMerchantApply(createReqVO));
+    }
+
+    @PutMapping("/update")
+    @Operation(summary = "更新商户申请")
+    @PreAuthenticated
+    public CommonResult<Boolean> updateMerchantApply(@Valid @RequestBody MerchantApplySaveReqVO updateReqVO) {
+        merchantApplyService.updateMerchantApply(updateReqVO);
+        return success(true);
+    }
+
+//    @DeleteMapping("/delete")
+//    @Operation(summary = "删除商户申请")
+//    @Parameter(name = "id", description = "编号", required = true)
+//    @PreAuthenticated
+//    public CommonResult<Boolean> deleteMerchantApply(@RequestParam("id") Long id) {
+//        merchantApplyService.deleteMerchantApply(id);
+//        return success(true);
+//    }
+
+    @GetMapping("/get")
+    @Operation(summary = "获得商户申请")
+    @Parameter(name = "id", description = "编号", required = true, example = "1024")
+    @PreAuthenticated
+    public CommonResult<MerchantApplyRespVO> getMerchantApply() {
+        MerchantApplyDO merchantApply = merchantApplyService.getMerchantApplyBYUserId(getLoginUserId());
+        MerchantApplyRespVO bean = BeanUtils.toBean(merchantApply, MerchantApplyRespVO.class);
+
+        if(merchantApply != null){
+            // Step 1: 去除字符串中的方括号和空格
+            String input = merchantApply.getOtherCertificate().replaceAll("[\\[\\]\\s]", "");
+
+            // Step 2: 按逗号分割字符串
+            String[] parts = input.split(",");
+
+            List<String> fileList = new ArrayList<>();
+
+            // Step 3: 去除每个部分可能的空格并添加到列表中
+            for (String part : parts) {
+                fileList.add(part.trim());
+            }
+
+            bean.setOtherCertificate(fileList);
+        }
+
+        return success(bean);
+    }
+
+//    @GetMapping("/page")
+//    @Operation(summary = "获得商户申请分页")
+//    @PreAuthenticated
+//    public CommonResult<PageResult<MerchantApplyRespVO>> getMerchantApplyPage(@Valid MerchantApplyPageReqVO pageReqVO) {
+//        PageResult<MerchantApplyDO> pageResult = merchantApplyService.getMerchantApplyPage(pageReqVO);
+//        return success(BeanUtils.toBean(pageResult, MerchantApplyRespVO.class));
+//    }
+}

+ 29 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchantapply/vo/MerchantApplyPageReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/vo/MerchantApplyPageReqVO.java

@@ -1,10 +1,11 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo;
 
 import lombok.*;
 import io.swagger.v3.oas.annotations.media.Schema;
 import cn.newfeifan.mall.framework.common.pojo.PageParam;
 import org.springframework.format.annotation.DateTimeFormat;
 import java.time.LocalDateTime;
+import java.util.List;
 
 import static cn.newfeifan.mall.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
 
@@ -89,4 +90,31 @@ public class MerchantApplyPageReqVO extends PageParam {
     @Schema(description = "审核状态:默认0表示未审核,1审核通过,2审核不通过", example = "1")
     private Integer checkStatus;
 
+    @Schema(description = "账户名称", example = "赵六")
+    private String accountName;
+
+    @Schema(description = "账户号码")
+    private String accountNumber;
+
+    @Schema(description = "开户银行", example = "非繁人")
+    private String bankName;
+
+    @Schema(description = "品牌授权书")
+    private String brandLicensing;
+
+    @Schema(description = "其他证书")
+    private List<String> otherCertificate;
+
+    @Schema(description = "法人")
+    private String legalPerson;
+
+    @Schema(description = "法人电话")
+    private String legalPersonNumber;
+
+    @Schema(description = "身份证正面")
+    private String identityCardFront;
+
+    @Schema(description = "身份证反面")
+    private String identityCardReverseSide;
+
 }

+ 39 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchantapply/vo/MerchantApplyRespVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/vo/MerchantApplyRespVO.java

@@ -1,8 +1,10 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.*;
 import java.time.LocalDateTime;
+import java.util.List;
+
 import com.alibaba.excel.annotation.*;
 
 @Schema(description = "管理后台 - 商户申请 Response VO")
@@ -110,4 +112,40 @@ public class MerchantApplyRespVO {
     @ExcelProperty("审核状态:默认0表示未审核,1审核通过,2审核不通过")
     private Integer checkStatus;
 
+    @Schema(description = "账户名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
+    @ExcelProperty("账户名称")
+    private String accountName;
+
+    @Schema(description = "账户号码", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("账户号码")
+    private String accountNumber;
+
+    @Schema(description = "开户银行", requiredMode = Schema.RequiredMode.REQUIRED, example = "非繁人")
+    @ExcelProperty("开户银行")
+    private String bankName;
+
+    @Schema(description = "品牌授权书", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("品牌授权书")
+    private String brandLicensing;
+
+    @Schema(description = "其他证书", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("其他证书")
+    private List<String> otherCertificate;
+
+    @Schema(description = "法人", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("法人")
+    private String legalPerson;
+
+    @Schema(description = "法人电话", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("法人电话")
+    private String legalPersonNumber;
+
+    @Schema(description = "身份证正面", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("身份证正面")
+    private String identityCardFront;
+
+    @Schema(description = "身份证反面", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("身份证反面")
+    private String identityCardReverseSide;
+
 }

+ 39 - 3
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/merchantapply/vo/MerchantApplySaveReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapply/vo/MerchantApplySaveReqVO.java

@@ -1,9 +1,10 @@
-package cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo;
+package cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.*;
 import javax.validation.constraints.*;
 import java.time.LocalDateTime;
+import java.util.List;
 
 @Schema(description = "管理后台 - 商户申请新增/修改 Request VO")
 @Data
@@ -20,7 +21,6 @@ public class MerchantApplySaveReqVO {
     private String name;
 
     @Schema(description = "商户状态,关联商户状态表", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
-    @NotNull(message = "商户状态,关联商户状态表不能为空")
     private Integer status;
 
     @Schema(description = "简介", example = "随便")
@@ -48,6 +48,7 @@ public class MerchantApplySaveReqVO {
     private String customerServiceHotline;
 
     @Schema(description = "邮箱")
+    @Email(message = "邮箱格式不正确")
     private String email;
 
     @Schema(description = "营业执照图片路径")
@@ -66,7 +67,6 @@ public class MerchantApplySaveReqVO {
     private Long areaId;
 
     @Schema(description = "申请用户id", requiredMode = Schema.RequiredMode.REQUIRED, example = "7189")
-    @NotNull(message = "申请用户id不能为空")
     private Long applyMemberUserId;
 
     @Schema(description = "审核系统用户id", example = "29612")
@@ -84,4 +84,40 @@ public class MerchantApplySaveReqVO {
     @Schema(description = "审核状态:默认0表示未审核,1审核通过,2审核不通过", example = "1")
     private Integer checkStatus;
 
+    @Schema(description = "账户名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
+    @NotEmpty(message = "账户名称不能为空")
+    private String accountName;
+
+    @Schema(description = "账户号码", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "账户号码不能为空")
+    @Pattern(regexp = "^\\d+$", message = "字段必须全部为数字")
+    private String accountNumber;
+
+    @Schema(description = "开户银行", requiredMode = Schema.RequiredMode.REQUIRED, example = "非繁人")
+    @NotEmpty(message = "开户银行不能为空")
+    private String bankName;
+
+    @Schema(description = "品牌授权书", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "品牌授权书不能为空")
+    private String brandLicensing;
+
+    @Schema(description = "其他证书", requiredMode = Schema.RequiredMode.REQUIRED)
+    private List<String> otherCertificate;
+
+    @Schema(description = "法人", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "法人不能为空")
+    private String legalPerson;
+
+    @Schema(description = "法人电话", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "法人电话不能为空")
+    private String legalPersonNumber;
+
+    @Schema(description = "身份证正面", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "身份证正面不能为空")
+    private String identityCardFront;
+
+    @Schema(description = "身份证反面", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "身份证反面不能为空")
+    private String identityCardReverseSide;
+
 }

+ 94 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/MerchantApplyLogController.java

@@ -0,0 +1,94 @@
+package cn.newfeifan.mall.module.sale.controller.app.merchantapplylog;
+
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogRespVO;
+import org.springframework.web.bind.annotation.*;
+import javax.annotation.Resource;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.security.access.prepost.PreAuthorize;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.Operation;
+
+import javax.validation.*;
+import javax.servlet.http.*;
+import java.util.*;
+import java.io.IOException;
+
+import cn.newfeifan.mall.framework.common.pojo.PageParam;
+import cn.newfeifan.mall.framework.common.pojo.PageResult;
+import cn.newfeifan.mall.framework.common.pojo.CommonResult;
+import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
+import static cn.newfeifan.mall.framework.common.pojo.CommonResult.success;
+
+import cn.newfeifan.mall.framework.excel.core.util.ExcelUtils;
+
+import cn.newfeifan.mall.framework.operatelog.core.annotations.OperateLog;
+import static cn.newfeifan.mall.framework.operatelog.core.enums.OperateTypeEnum.*;
+
+import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapplylog.MerchantApplyLogDO;
+import cn.newfeifan.mall.module.sale.service.merchantapplylog.MerchantApplyLogService;
+
+@Tag(name = "管理后台 - 商户审核记录")
+@RestController
+@RequestMapping("/sale/merchant-apply-log")
+@Validated
+public class MerchantApplyLogController {
+
+    @Resource
+    private MerchantApplyLogService merchantApplyLogService;
+
+//    @PostMapping("/create")
+//    @Operation(summary = "创建商户审核记录")
+//    @PreAuthorize("@ss.hasPermission('sale:merchant-apply-log:create')")
+//    public CommonResult<Long> createMerchantApplyLog(@Valid @RequestBody MerchantApplyLogSaveReqVO createReqVO) {
+//        return success(merchantApplyLogService.createMerchantApplyLog(createReqVO));
+//    }
+
+//    @PutMapping("/update")
+//    @Operation(summary = "更新商户审核记录")
+//    @PreAuthorize("@ss.hasPermission('sale:merchant-apply-log:update')")
+//    public CommonResult<Boolean> updateMerchantApplyLog(@Valid @RequestBody MerchantApplyLogSaveReqVO updateReqVO) {
+//        merchantApplyLogService.updateMerchantApplyLog(updateReqVO);
+//        return success(true);
+//    }
+
+//    @DeleteMapping("/delete")
+//    @Operation(summary = "删除商户审核记录")
+//    @Parameter(name = "id", description = "编号", required = true)
+//    @PreAuthorize("@ss.hasPermission('sale:merchant-apply-log:delete')")
+//    public CommonResult<Boolean> deleteMerchantApplyLog(@RequestParam("id") Long id) {
+//        merchantApplyLogService.deleteMerchantApplyLog(id);
+//        return success(true);
+//    }
+
+    @GetMapping("/get")
+    @Operation(summary = "获得商户审核记录")
+    @Parameter(name = "id", description = "编号", required = true, example = "1024")
+    @PreAuthorize("@ss.hasPermission('sale:merchant-apply-log:query')")
+    public CommonResult<MerchantApplyLogRespVO> getMerchantApplyLog(@RequestParam("id") Long id) {
+        MerchantApplyLogDO merchantApplyLog = merchantApplyLogService.getMerchantApplyLog(id);
+        return success(BeanUtils.toBean(merchantApplyLog, MerchantApplyLogRespVO.class));
+    }
+
+    @GetMapping("/page")
+    @Operation(summary = "获得商户审核记录分页")
+    public CommonResult<PageResult<MerchantApplyLogRespVO>> getMerchantApplyLogPage(@Valid MerchantApplyLogPageReqVO pageReqVO) {
+        PageResult<MerchantApplyLogDO> pageResult = merchantApplyLogService.getMerchantApplyLogPage(pageReqVO);
+        return success(BeanUtils.toBean(pageResult, MerchantApplyLogRespVO.class));
+    }
+
+    @GetMapping("/export-excel")
+    @Operation(summary = "导出商户审核记录 Excel")
+    @PreAuthorize("@ss.hasPermission('sale:merchant-apply-log:export')")
+    @OperateLog(type = EXPORT)
+    public void exportMerchantApplyLogExcel(@Valid MerchantApplyLogPageReqVO pageReqVO,
+              HttpServletResponse response) throws IOException {
+        pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
+        List<MerchantApplyLogDO> list = merchantApplyLogService.getMerchantApplyLogPage(pageReqVO).getList();
+        // 导出 Excel
+        ExcelUtils.write(response, "商户审核记录.xls", "数据", MerchantApplyLogRespVO.class,
+                        BeanUtils.toBean(list, MerchantApplyLogRespVO.class));
+    }
+
+}

+ 33 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/vo/MerchantApplyLogPageReqVO.java

@@ -0,0 +1,33 @@
+package cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo;
+
+import lombok.*;
+import io.swagger.v3.oas.annotations.media.Schema;
+import cn.newfeifan.mall.framework.common.pojo.PageParam;
+import org.springframework.format.annotation.DateTimeFormat;
+import java.time.LocalDateTime;
+
+import static cn.newfeifan.mall.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
+
+@Schema(description = "管理后台 - 商户审核记录分页 Request VO")
+@Data
+@EqualsAndHashCode(callSuper = true)
+@ToString(callSuper = true)
+public class MerchantApplyLogPageReqVO extends PageParam {
+
+    @Schema(description = "申请状态  0:申请中 1:通过 2:未通过", example = "2")
+    private Integer status;
+
+    @Schema(description = "商户申请id", example = "16850")
+    private Long merchantApplyId;
+
+    @Schema(description = "审核系统用户id", example = "16237")
+    private Long checkSystemUserId;
+
+    @Schema(description = "审核意见")
+    private String checkComment;
+
+    @Schema(description = "创建时间")
+    @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
+    private LocalDateTime[] createTime;
+
+}

+ 37 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/vo/MerchantApplyLogRespVO.java

@@ -0,0 +1,37 @@
+package cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.*;
+import java.time.LocalDateTime;
+import com.alibaba.excel.annotation.*;
+
+@Schema(description = "管理后台 - 商户审核记录 Response VO")
+@Data
+@ExcelIgnoreUnannotated
+public class MerchantApplyLogRespVO {
+
+    @Schema(description = "审核记录id", requiredMode = Schema.RequiredMode.REQUIRED, example = "9887")
+    @ExcelProperty("审核记录id")
+    private Long id;
+
+    @Schema(description = "申请状态  0:申请中 1:通过 2:未通过", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
+    @ExcelProperty("申请状态  0:申请中 1:通过 2:未通过")
+    private Integer status;
+
+    @Schema(description = "商户申请id", requiredMode = Schema.RequiredMode.REQUIRED, example = "16850")
+    @ExcelProperty("商户申请id")
+    private Long merchantApplyId;
+
+    @Schema(description = "审核系统用户id", example = "16237")
+    @ExcelProperty("审核系统用户id")
+    private Long checkSystemUserId;
+
+    @Schema(description = "审核意见")
+    @ExcelProperty("审核意见")
+    private String checkComment;
+
+    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
+    @ExcelProperty("创建时间")
+    private LocalDateTime createTime;
+
+}

+ 28 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/merchantapplylog/vo/MerchantApplyLogSaveReqVO.java

@@ -0,0 +1,28 @@
+package cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.*;
+import javax.validation.constraints.*;
+
+@Schema(description = "管理后台 - 商户审核记录新增/修改 Request VO")
+@Data
+public class MerchantApplyLogSaveReqVO {
+
+    @Schema(description = "审核记录id", requiredMode = Schema.RequiredMode.REQUIRED, example = "9887")
+    private Long id;
+
+    @Schema(description = "申请状态  0:申请中 1:通过 2:未通过", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
+    @NotNull(message = "申请状态  0:申请中 1:通过 2:未通过不能为空")
+    private Integer status;
+
+    @Schema(description = "商户申请id", requiredMode = Schema.RequiredMode.REQUIRED, example = "16850")
+    @NotNull(message = "商户申请id不能为空")
+    private Long merchantApplyId;
+
+    @Schema(description = "审核系统用户id", example = "16237")
+    private Long checkSystemUserId;
+
+    @Schema(description = "审核意见")
+    private String checkComment;
+
+}

+ 1 - 2
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/shop/vo/ShopPageReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shop/vo/ShopPageReqVO.java

@@ -1,7 +1,6 @@
-package cn.newfeifan.mall.module.sale.controller.admin.shop.vo;
+package cn.newfeifan.mall.module.sale.controller.app.shop.vo;
 
 import lombok.*;
-import java.util.*;
 import io.swagger.v3.oas.annotations.media.Schema;
 import cn.newfeifan.mall.framework.common.pojo.PageParam;
 import org.springframework.format.annotation.DateTimeFormat;

+ 1 - 4
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/shop/vo/ShopRespVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shop/vo/ShopRespVO.java

@@ -1,10 +1,7 @@
-package cn.newfeifan.mall.module.sale.controller.admin.shop.vo;
+package cn.newfeifan.mall.module.sale.controller.app.shop.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.*;
-import java.util.*;
-import java.util.*;
-import org.springframework.format.annotation.DateTimeFormat;
 import java.time.LocalDateTime;
 import com.alibaba.excel.annotation.*;
 

+ 1 - 2
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/shop/vo/ShopSaveReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shop/vo/ShopSaveReqVO.java

@@ -1,8 +1,7 @@
-package cn.newfeifan.mall.module.sale.controller.admin.shop.vo;
+package cn.newfeifan.mall.module.sale.controller.app.shop.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.*;
-import java.util.*;
 import javax.validation.constraints.*;
 
 @Schema(description = "管理后台 - 店铺新增/修改 Request VO")

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/shopstatus/vo/ShopStatusPageReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shopstatus/vo/ShopStatusPageReqVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.shopstatus.vo;
+package cn.newfeifan.mall.module.sale.controller.app.shopstatus.vo;
 
 import cn.newfeifan.mall.framework.common.pojo.PageParam;
 import io.swagger.v3.oas.annotations.media.Schema;

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/shopstatus/vo/ShopStatusRespVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shopstatus/vo/ShopStatusRespVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.shopstatus.vo;
+package cn.newfeifan.mall.module.sale.controller.app.shopstatus.vo;
 
 import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
 import com.alibaba.excel.annotation.ExcelProperty;

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/admin/shopstatus/vo/ShopStatusSaveReqVO.java → feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/controller/app/shopstatus/vo/ShopStatusSaveReqVO.java

@@ -1,4 +1,4 @@
-package cn.newfeifan.mall.module.sale.controller.admin.shopstatus.vo;
+package cn.newfeifan.mall.module.sale.controller.app.shopstatus.vo;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.Data;

+ 37 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/dataobject/merchantapply/MerchantApplyDO.java

@@ -117,5 +117,42 @@ public class MerchantApplyDO extends BaseDO {
      * 审核状态:默认0表示未审核,1审核通过,2审核不通过
      */
     private Integer checkStatus;
+    /**
+     * 账户名称
+     */
+    private String accountName;
+    /**
+     * 账户号码
+     */
+    private String accountNumber;
+    /**
+     * 开户银行
+     */
+    private String bankName;
+    /**
+     * 品牌授权书
+     */
+    private String brandLicensing;
+    /**
+     * 其他证书
+     */
+    private String otherCertificate;
+
+    /**
+     * 法人
+     */
+    private String legalPerson;
+    /**
+     * 法人电话
+     */
+    private String legalPersonNumber;
+    /**
+     * 身份证正面
+     */
+    private String identityCardFront;
+    /**
+     * 身份证反面
+     */
+    private String identityCardReverseSide;
 
 }

+ 44 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/dataobject/merchantapplylog/MerchantApplyLogDO.java

@@ -0,0 +1,44 @@
+package cn.newfeifan.mall.module.sale.dal.dataobject.merchantapplylog;
+
+import lombok.*;
+import com.baomidou.mybatisplus.annotation.*;
+import cn.newfeifan.mall.framework.mybatis.core.dataobject.BaseDO;
+
+/**
+ * 商户审核记录 DO
+ *
+ * @author 非繁人
+ */
+@TableName("sale_merchant_apply_log")
+@KeySequence("sale_merchant_apply_log_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
+@Data
+@EqualsAndHashCode(callSuper = true)
+@ToString(callSuper = true)
+@Builder
+@NoArgsConstructor
+@AllArgsConstructor
+public class MerchantApplyLogDO extends BaseDO {
+
+    /**
+     * 审核记录id
+     */
+    @TableId
+    private Long id;
+    /**
+     * 申请状态  0:申请中 1:通过 2:未通过
+     */
+    private Integer status;
+    /**
+     * 商户申请id
+     */
+    private Long merchantApplyId;
+    /**
+     * 审核系统用户id
+     */
+    private Long checkSystemUserId;
+    /**
+     * 审核意见
+     */
+    private String checkComment;
+
+}

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/merchant/MerchantMapper.java

@@ -3,7 +3,7 @@ package cn.newfeifan.mall.module.sale.dal.mysql.merchant;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
 import cn.newfeifan.mall.framework.mybatis.core.mapper.BaseMapperX;
 import cn.newfeifan.mall.framework.mybatis.core.query.LambdaQueryWrapperX;
-import cn.newfeifan.mall.module.sale.controller.admin.merchant.vo.MerchantPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchant.vo.MerchantPageReqVO;
 import cn.newfeifan.mall.module.sale.dal.dataobject.merchant.MerchantDO;
 import org.apache.ibatis.annotations.Mapper;
 

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/merchantapply/MerchantApplyMapper.java

@@ -4,9 +4,9 @@ package cn.newfeifan.mall.module.sale.dal.mysql.merchantapply;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
 import cn.newfeifan.mall.framework.mybatis.core.query.LambdaQueryWrapperX;
 import cn.newfeifan.mall.framework.mybatis.core.mapper.BaseMapperX;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplyPageReqVO;
 import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapply.MerchantApplyDO;
 import org.apache.ibatis.annotations.Mapper;
-import cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo.*;
 
 /**
  * 商户申请 Mapper

+ 28 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/merchantapplylog/MerchantApplyLogMapper.java

@@ -0,0 +1,28 @@
+package cn.newfeifan.mall.module.sale.dal.mysql.merchantapplylog;
+
+import cn.newfeifan.mall.framework.common.pojo.PageResult;
+import cn.newfeifan.mall.framework.mybatis.core.query.LambdaQueryWrapperX;
+import cn.newfeifan.mall.framework.mybatis.core.mapper.BaseMapperX;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogPageReqVO;
+import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapplylog.MerchantApplyLogDO;
+import org.apache.ibatis.annotations.Mapper;
+
+/**
+ * 商户审核记录 Mapper
+ *
+ * @author 非繁人
+ */
+@Mapper
+public interface MerchantApplyLogMapper extends BaseMapperX<MerchantApplyLogDO> {
+
+    default PageResult<MerchantApplyLogDO> selectPage(MerchantApplyLogPageReqVO reqVO) {
+        return selectPage(reqVO, new LambdaQueryWrapperX<MerchantApplyLogDO>()
+                .eqIfPresent(MerchantApplyLogDO::getStatus, reqVO.getStatus())
+                .eqIfPresent(MerchantApplyLogDO::getMerchantApplyId, reqVO.getMerchantApplyId())
+                .eqIfPresent(MerchantApplyLogDO::getCheckSystemUserId, reqVO.getCheckSystemUserId())
+                .eqIfPresent(MerchantApplyLogDO::getCheckComment, reqVO.getCheckComment())
+                .betweenIfPresent(MerchantApplyLogDO::getCreateTime, reqVO.getCreateTime())
+                .orderByDesc(MerchantApplyLogDO::getId));
+    }
+
+}

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/shop/ShopMapper.java

@@ -7,7 +7,7 @@ import cn.newfeifan.mall.framework.mybatis.core.query.LambdaQueryWrapperX;
 import cn.newfeifan.mall.framework.mybatis.core.mapper.BaseMapperX;
 import cn.newfeifan.mall.module.sale.dal.dataobject.shop.ShopDO;
 import org.apache.ibatis.annotations.Mapper;
-import cn.newfeifan.mall.module.sale.controller.admin.shop.vo.*;
+import cn.newfeifan.mall.module.sale.controller.app.shop.vo.*;
 
 /**
  * 店铺 Mapper

+ 1 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/dal/mysql/shopstatus/ShopStatusMapper.java

@@ -3,7 +3,7 @@ package cn.newfeifan.mall.module.sale.dal.mysql.shopstatus;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
 import cn.newfeifan.mall.framework.mybatis.core.mapper.BaseMapperX;
 import cn.newfeifan.mall.framework.mybatis.core.query.LambdaQueryWrapperX;
-import cn.newfeifan.mall.module.sale.controller.admin.shopstatus.vo.ShopStatusPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.shopstatus.vo.ShopStatusPageReqVO;
 import cn.newfeifan.mall.module.sale.dal.dataobject.shopstatus.ShopStatusDO;
 import org.apache.ibatis.annotations.Mapper;
 

+ 9 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapply/MerchantApplyService.java

@@ -1,7 +1,9 @@
 package cn.newfeifan.mall.module.sale.service.merchantapply;
 
 import javax.validation.*;
-import cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo.*;
+
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplyPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplySaveReqVO;
 import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapply.MerchantApplyDO;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
 
@@ -50,4 +52,10 @@ public interface MerchantApplyService {
      */
     PageResult<MerchantApplyDO> getMerchantApplyPage(MerchantApplyPageReqVO pageReqVO);
 
+    /**
+     * 获得商户申请
+     * @param loginUserId 用户id
+     * @return 商户申请
+     */
+    MerchantApplyDO getMerchantApplyBYUserId(Long loginUserId);
 }

+ 49 - 1
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapply/MerchantApplyServiceImpl.java

@@ -1,17 +1,24 @@
 package cn.newfeifan.mall.module.sale.service.merchantapply;
 
+import cn.newfeifan.mall.framework.common.exception.ErrorCode;
+import cn.newfeifan.mall.module.member.enums.DictTypeConstants;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplyPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapply.vo.MerchantApplySaveReqVO;
+import cn.newfeifan.mall.module.sale.enums.MerchantApplyCheckStatusEnum;
+import cn.newfeifan.mall.module.system.service.user.AdminUserService;
 import org.springframework.stereotype.Service;
 import javax.annotation.Resource;
 import org.springframework.validation.annotation.Validated;
 
-import cn.newfeifan.mall.module.sale.controller.admin.merchantapply.vo.*;
 import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapply.MerchantApplyDO;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
 import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
 
 import cn.newfeifan.mall.module.sale.dal.mysql.merchantapply.MerchantApplyMapper;
 
+
 import static cn.newfeifan.mall.framework.common.exception.util.ServiceExceptionUtil.exception;
+import static cn.newfeifan.mall.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId;
 import static cn.newfeifan.mall.module.sale.enums.ErrorCodeConstants.*;
 
 /**
@@ -26,10 +33,27 @@ public class MerchantApplyServiceImpl implements MerchantApplyService {
     @Resource
     private MerchantApplyMapper merchantApplyMapper;
 
+    @Resource
+    private AdminUserService usersService;
+
     @Override
     public Long createMerchantApply(MerchantApplySaveReqVO createReqVO) {
+
+        // 校验存在
+        if(usersService.getUserByMobile(createReqVO.getContactNumber()) != null){
+            ErrorCode ERROR = new ErrorCode(1_002_029_003, "联络人账户已存在");
+            throw exception(ERROR);
+        }
+
         // 插入
         MerchantApplyDO merchantApply = BeanUtils.toBean(createReqVO, MerchantApplyDO.class);
+        merchantApply.setApplyMemberUserId(getLoginUserId());
+
+        // 默认log
+        if(createReqVO.getLogoUrl() == null || createReqVO.getLogoUrl().isEmpty()){
+            createReqVO.setLogoUrl(DictTypeConstants.DEFAULT_AVATAR);
+        }
+
         merchantApplyMapper.insert(merchantApply);
         // 返回
         return merchantApply.getId();
@@ -37,10 +61,29 @@ public class MerchantApplyServiceImpl implements MerchantApplyService {
 
     @Override
     public void updateMerchantApply(MerchantApplySaveReqVO updateReqVO) {
+
+        MerchantApplyDO merchantApplyDO = merchantApplyMapper.selectById(updateReqVO.getId());
+
+        // 联系人手机号校验
+        if(!merchantApplyDO.getContactNumber().equals(updateReqVO.getContactNumber()) && usersService.getUserByMobile(updateReqVO.getContactNumber()) != null){
+            ErrorCode ERROR = new ErrorCode(1_002_029_003, "联络人账户已存在");
+            throw exception(ERROR);
+        }
+
+        updateReqVO.setApplyMemberUserId(getLoginUserId());
         // 校验存在
         validateMerchantApplyExists(updateReqVO.getId());
         // 更新
         MerchantApplyDO updateObj = BeanUtils.toBean(updateReqVO, MerchantApplyDO.class);
+
+        // 默认log
+        if(updateObj.getLogoUrl() == null || updateObj.getLogoUrl().isEmpty()){
+            updateObj.setLogoUrl(DictTypeConstants.DEFAULT_AVATAR);
+        }
+
+        // 所有变动都需要重新审核
+        updateObj.setCheckStatus(MerchantApplyCheckStatusEnum.WAIT_AUDIT.getType());
+
         merchantApplyMapper.updateById(updateObj);
     }
 
@@ -68,4 +111,9 @@ public class MerchantApplyServiceImpl implements MerchantApplyService {
         return merchantApplyMapper.selectPage(pageReqVO);
     }
 
+    @Override
+    public MerchantApplyDO getMerchantApplyBYUserId(Long loginUserId) {
+        return merchantApplyMapper.selectOne(MerchantApplyDO::getApplyMemberUserId, loginUserId);
+    }
+
 }

+ 55 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapplylog/MerchantApplyLogService.java

@@ -0,0 +1,55 @@
+package cn.newfeifan.mall.module.sale.service.merchantapplylog;
+
+import javax.validation.*;
+
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogSaveReqVO;
+import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapplylog.MerchantApplyLogDO;
+import cn.newfeifan.mall.framework.common.pojo.PageResult;
+
+/**
+ * 商户审核记录 Service 接口
+ *
+ * @author 非繁人
+ */
+public interface MerchantApplyLogService {
+
+    /**
+     * 创建商户审核记录
+     *
+     * @param createReqVO 创建信息
+     * @return 编号
+     */
+    Long createMerchantApplyLog(@Valid MerchantApplyLogSaveReqVO createReqVO);
+
+    /**
+     * 更新商户审核记录
+     *
+     * @param updateReqVO 更新信息
+     */
+    void updateMerchantApplyLog(@Valid MerchantApplyLogSaveReqVO updateReqVO);
+
+    /**
+     * 删除商户审核记录
+     *
+     * @param id 编号
+     */
+    void deleteMerchantApplyLog(Long id);
+
+    /**
+     * 获得商户审核记录
+     *
+     * @param id 编号
+     * @return 商户审核记录
+     */
+    MerchantApplyLogDO getMerchantApplyLog(Long id);
+
+    /**
+     * 获得商户审核记录分页
+     *
+     * @param pageReqVO 分页查询
+     * @return 商户审核记录分页
+     */
+    PageResult<MerchantApplyLogDO> getMerchantApplyLogPage(MerchantApplyLogPageReqVO pageReqVO);
+
+}

+ 72 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/merchantapplylog/MerchantApplyLogServiceImpl.java

@@ -0,0 +1,72 @@
+package cn.newfeifan.mall.module.sale.service.merchantapplylog;
+
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogPageReqVO;
+import cn.newfeifan.mall.module.sale.controller.app.merchantapplylog.vo.MerchantApplyLogSaveReqVO;
+import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import org.springframework.validation.annotation.Validated;
+
+import cn.newfeifan.mall.module.sale.dal.dataobject.merchantapplylog.MerchantApplyLogDO;
+import cn.newfeifan.mall.framework.common.pojo.PageResult;
+import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
+
+import cn.newfeifan.mall.module.sale.dal.mysql.merchantapplylog.MerchantApplyLogMapper;
+
+import static cn.newfeifan.mall.framework.common.exception.util.ServiceExceptionUtil.exception;
+import static cn.newfeifan.mall.module.sale.enums.ErrorCodeConstants.MERCHANT_APPLY_LOG_NOT_EXISTS;
+
+/**
+ * 商户审核记录 Service 实现类
+ *
+ * @author 非繁人
+ */
+@Service
+@Validated
+public class MerchantApplyLogServiceImpl implements MerchantApplyLogService {
+
+    @Resource
+    private MerchantApplyLogMapper merchantApplyLogMapper;
+
+    @Override
+    public Long createMerchantApplyLog(MerchantApplyLogSaveReqVO createReqVO) {
+        // 插入
+        MerchantApplyLogDO merchantApplyLog = BeanUtils.toBean(createReqVO, MerchantApplyLogDO.class);
+        merchantApplyLogMapper.insert(merchantApplyLog);
+        // 返回
+        return merchantApplyLog.getId();
+    }
+
+    @Override
+    public void updateMerchantApplyLog(MerchantApplyLogSaveReqVO updateReqVO) {
+        // 校验存在
+        validateMerchantApplyLogExists(updateReqVO.getId());
+        // 更新
+        MerchantApplyLogDO updateObj = BeanUtils.toBean(updateReqVO, MerchantApplyLogDO.class);
+        merchantApplyLogMapper.updateById(updateObj);
+    }
+
+    @Override
+    public void deleteMerchantApplyLog(Long id) {
+        // 校验存在
+        validateMerchantApplyLogExists(id);
+        // 删除
+        merchantApplyLogMapper.deleteById(id);
+    }
+
+    private void validateMerchantApplyLogExists(Long id) {
+        if (merchantApplyLogMapper.selectById(id) == null) {
+            throw exception(MERCHANT_APPLY_LOG_NOT_EXISTS);
+        }
+    }
+
+    @Override
+    public MerchantApplyLogDO getMerchantApplyLog(Long id) {
+        return merchantApplyLogMapper.selectById(id);
+    }
+
+    @Override
+    public PageResult<MerchantApplyLogDO> getMerchantApplyLogPage(MerchantApplyLogPageReqVO pageReqVO) {
+        return merchantApplyLogMapper.selectPage(pageReqVO);
+    }
+
+}

+ 1 - 3
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/shop/ShopService.java

@@ -1,11 +1,9 @@
 package cn.newfeifan.mall.module.sale.service.shop;
 
-import java.util.*;
 import javax.validation.*;
-import cn.newfeifan.mall.module.sale.controller.admin.shop.vo.*;
+import cn.newfeifan.mall.module.sale.controller.app.shop.vo.*;
 import cn.newfeifan.mall.module.sale.dal.dataobject.shop.ShopDO;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
-import cn.newfeifan.mall.framework.common.pojo.PageParam;
 
 /**
  * 店铺 Service 接口

+ 1 - 6
feifan-module-mall/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/module/sale/service/shop/ShopServiceImpl.java

@@ -4,19 +4,14 @@ import cn.newfeifan.mall.module.sale.enums.ErrorCodeConstants;
 import org.springframework.stereotype.Service;
 import javax.annotation.Resource;
 import org.springframework.validation.annotation.Validated;
-import org.springframework.transaction.annotation.Transactional;
-
-import java.util.*;
-import cn.newfeifan.mall.module.sale.controller.admin.shop.vo.*;
+import cn.newfeifan.mall.module.sale.controller.app.shop.vo.*;
 import cn.newfeifan.mall.module.sale.dal.dataobject.shop.ShopDO;
 import cn.newfeifan.mall.framework.common.pojo.PageResult;
-import cn.newfeifan.mall.framework.common.pojo.PageParam;
 import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
 
 import cn.newfeifan.mall.module.sale.dal.mysql.shop.ShopMapper;
 
 import static cn.newfeifan.mall.framework.common.exception.util.ServiceExceptionUtil.exception;
-import static cn.newfeifan.mall.module.sale.enums.ErrorCodeConstants.*;
 
 /**
  * 店铺 Service 实现类

+ 12 - 0
feifan-module-mall/feifan-module-sale-biz/src/main/resources/mapper/merchantapplylog/MerchantApplyLogMapper.xml

@@ -0,0 +1,12 @@
+<?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.newfeifan.mall.module.sale.dal.mysql.merchantapplylog.MerchantApplyLogMapper">
+
+    <!--
+        一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
+        无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
+        代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
+        文档可见:https://www.zhongxing.cn/MyBatis/x-plugins/
+     -->
+
+</mapper>

+ 0 - 146
feifan-module-mall/feifan-module-sale-biz/src/test/java/cn/newfeifan/mall/module/sale/service/shop/ShopServiceImplTest.java

@@ -1,146 +0,0 @@
-package cn.newfeifan.mall.module.sale.service.shop;
-
-import org.junit.jupiter.api.Disabled;
-import org.junit.jupiter.api.Test;
-import org.springframework.boot.test.mock.mockito.MockBean;
-
-import javax.annotation.Resource;
-
-import cn.newfeifan.mall.framework.test.core.ut.BaseDbUnitTest;
-
-import cn.newfeifan.mall.module.sale.controller.admin.shop.vo.*;
-import cn.newfeifan.mall.module.sale.dal.dataobject.shop.ShopDO;
-import cn.newfeifan.mall.module.sale.dal.mysql.shop.ShopMapper;
-import cn.newfeifan.mall.framework.common.pojo.PageResult;
-
-import javax.annotation.Resource;
-import org.springframework.context.annotation.Import;
-import java.util.*;
-import java.time.LocalDateTime;
-
-import static cn.hutool.core.util.RandomUtil.*;
-import static cn.newfeifan.mall.module.sale.enums.ErrorCodeConstants.*;
-import static cn.newfeifan.mall.framework.test.core.util.AssertUtils.*;
-import static cn.newfeifan.mall.framework.test.core.util.RandomUtils.*;
-import static cn.newfeifan.mall.framework.common.util.date.LocalDateTimeUtils.*;
-import static cn.newfeifan.mall.framework.common.util.object.ObjectUtils.*;
-import static cn.newfeifan.mall.framework.common.util.date.DateUtils.*;
-import static org.junit.jupiter.api.Assertions.*;
-import static org.mockito.Mockito.*;
-
-/**
- * {@link ShopServiceImpl} 的单元测试类
- *
- * @author 非繁人
- */
-@Import(ShopServiceImpl.class)
-public class ShopServiceImplTest extends BaseDbUnitTest {
-
-    @Resource
-    private ShopServiceImpl shopService;
-
-    @Resource
-    private ShopMapper shopMapper;
-
-    @Test
-    public void testCreateShop_success() {
-        // 准备参数
-        ShopSaveReqVO createReqVO = randomPojo(ShopSaveReqVO.class).setId(null);
-
-        // 调用
-        Long shopId = shopService.createShop(createReqVO);
-        // 断言
-        assertNotNull(shopId);
-        // 校验记录的属性是否正确
-        ShopDO shop = shopMapper.selectById(shopId);
-        assertPojoEquals(createReqVO, shop, "id");
-    }
-
-    @Test
-    public void testUpdateShop_success() {
-        // mock 数据
-        ShopDO dbShop = randomPojo(ShopDO.class);
-        shopMapper.insert(dbShop);// @Sql: 先插入出一条存在的数据
-        // 准备参数
-        ShopSaveReqVO updateReqVO = randomPojo(ShopSaveReqVO.class, o -> {
-            o.setId(dbShop.getId()); // 设置更新的 ID
-        });
-
-        // 调用
-        shopService.updateShop(updateReqVO);
-        // 校验是否更新正确
-        ShopDO shop = shopMapper.selectById(updateReqVO.getId()); // 获取最新的
-        assertPojoEquals(updateReqVO, shop);
-    }
-
-    @Test
-    public void testUpdateShop_notExists() {
-        // 准备参数
-        ShopSaveReqVO updateReqVO = randomPojo(ShopSaveReqVO.class);
-
-        // 调用, 并断言异常
-        assertServiceException(() -> shopService.updateShop(updateReqVO), SHOP_NOT_EXISTS);
-    }
-
-    @Test
-    public void testDeleteShop_success() {
-        // mock 数据
-        ShopDO dbShop = randomPojo(ShopDO.class);
-        shopMapper.insert(dbShop);// @Sql: 先插入出一条存在的数据
-        // 准备参数
-        Long id = dbShop.getId();
-
-        // 调用
-        shopService.deleteShop(id);
-       // 校验数据不存在了
-       assertNull(shopMapper.selectById(id));
-    }
-
-    @Test
-    public void testDeleteShop_notExists() {
-        // 准备参数
-        Long id = randomLongId();
-
-        // 调用, 并断言异常
-        assertServiceException(() -> shopService.deleteShop(id), SHOP_NOT_EXISTS);
-    }
-
-    @Test
-    @Disabled  // TODO 请修改 null 为需要的值,然后删除 @Disabled 注解
-    public void testGetShopPage() {
-       // mock 数据
-       ShopDO dbShop = randomPojo(ShopDO.class, o -> { // 等会查询到
-           o.setName(null);
-           o.setStatus(null);
-           o.setMerchantId(null);
-           o.setCreateTime(null);
-           o.setLogoUrl(null);
-       });
-       shopMapper.insert(dbShop);
-       // 测试 name 不匹配
-       shopMapper.insert(cloneIgnoreId(dbShop, o -> o.setName(null)));
-       // 测试 status 不匹配
-       shopMapper.insert(cloneIgnoreId(dbShop, o -> o.setStatus(null)));
-       // 测试 merchantId 不匹配
-       shopMapper.insert(cloneIgnoreId(dbShop, o -> o.setMerchantId(null)));
-       // 测试 createTime 不匹配
-       shopMapper.insert(cloneIgnoreId(dbShop, o -> o.setCreateTime(null)));
-       // 测试 logoUrl 不匹配
-       shopMapper.insert(cloneIgnoreId(dbShop, o -> o.setLogoUrl(null)));
-       // 准备参数
-       ShopPageReqVO reqVO = new ShopPageReqVO();
-       reqVO.setName(null);
-       reqVO.setStatus(null);
-       reqVO.setMerchantId(null);
-       reqVO.setCreateTime(buildBetweenTime(2023, 2, 1, 2023, 2, 28));
-       reqVO.setLogoUrl(null);
-
-       // 调用
-       PageResult<ShopDO> pageResult = shopService.getShopPage(reqVO);
-       // 断言
-       assertEquals(1, pageResult.getTotal());
-       assertEquals(1, pageResult.getList().size());
-       assertPojoEquals(dbShop, pageResult.getList().get(0));
-    }
-
-}

+ 40 - 0
feifan-module-system/feifan-module-system-biz/src/main/java/cn/newfeifan/mall/module/system/controller/app/user/UsersController.java

@@ -0,0 +1,40 @@
+package cn.newfeifan.mall.module.system.controller.app.user;
+
+import cn.newfeifan.mall.module.system.controller.admin.user.vo.user.UserRespVO;
+import cn.newfeifan.mall.module.system.dal.dataobject.user.AdminUserDO;
+import cn.newfeifan.mall.module.system.service.user.AdminUserService;
+import org.springframework.web.bind.annotation.*;
+import javax.annotation.Resource;
+import org.springframework.validation.annotation.Validated;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.Operation;
+
+import cn.newfeifan.mall.framework.common.pojo.CommonResult;
+import cn.newfeifan.mall.framework.common.util.object.BeanUtils;
+import static cn.newfeifan.mall.framework.common.pojo.CommonResult.success;
+
+@Tag(name = "管理后台 - 用户信息")
+@RestController
+@RequestMapping("/system/users")
+@Validated
+public class UsersController {
+
+    @Resource
+    private AdminUserService usersService;
+
+    @GetMapping("/get")
+    @Operation(summary = "获得用户信息")
+    @Parameter(name = "id", description = "编号", required = true, example = "1024")
+    public CommonResult<UserRespVO> getUsers(@RequestParam("id") Long id) {
+        AdminUserDO users = usersService.getUser(id);
+        return success(BeanUtils.toBean(users, UserRespVO.class));
+    }
+
+    @GetMapping("/getUserMobile")
+    @Operation(summary = "查询系统用户号码是否存在")
+    @Parameter(name = "mobile", description = "手机号码", required = true, example = "1024")
+    public CommonResult<Boolean> getUserMobile(@RequestParam("mobile") String mobile) {
+        return success(usersService.getUserByMobile(mobile) == null);
+    }
+}