Преглед изворни кода

资质分类字典管理
资质字典管理

jinhu пре 9 месеци
родитељ
комит
068a2efc91

+ 2 - 2
src/main/java/com/kcim/DemoApplication.java → src/main/java/com/kcim/MedicalApplication.java

@@ -4,10 +4,10 @@ import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
 
 @SpringBootApplication
-public class DemoApplication {
+public class MedicalApplication {
 
     public static void main(String[] args) {
-        SpringApplication.run(DemoApplication.class, args);
+        SpringApplication.run(MedicalApplication.class, args);
         System.out.println("============================启动成功==========================================");
 
     }

+ 82 - 24
src/main/java/com/kcim/constants/NumberConstant.java

@@ -3,99 +3,157 @@ package com.kcim.constants;
 /**
  * 数字设置
  */
-public final class NumberConstant {
-    public NumberConstant() {
-    }
+public  interface NumberConstant {
 
     /**
      * 零
      */
-    public static final Long ZERO_L = 0L;
-    public static final Integer ZERO = 0;
-    public static final String ZERO_S = "0";
+     Integer ZERO = 0;
+
+    /**
+     * 零
+     */
+    Long ZERO_L = 0L;
+
+    /**
+     * 零
+     */
+    String ZERO_S = "0";
+
+    /**
+     * 一
+     */
+     Integer ONE = 1;
+
+
     /**
      * 一
      */
-    public static final Integer ONE = 1;
+    String ONES = "01";
+
+    /**
+     * 一
+     */
+    String ONE_S = "1";
+    /**
+     * LONG 一
+     */
+    Long ONE_L = 1L;
 
     /**
      * 二
      */
-    public static final Integer TWO = 2;
+     Integer TWO = 2;
+    /**
+     * 二
+     */
+    String TWO_S = "2";
+    /**
+     * LONG 二
+     */
+    Long TWO_L = 2L;
 
     /**
      * 三
      */
-    public static final Integer THREE = 3;
+     Integer THREE = 3;
+    /**
+     * 三
+     */
+    String THREE_S = "3";
+
+    /**
+     * LONG 三
+     */
+    Long THREE_L = 3L;
 
     /**
      * 四
      */
-    public static final Integer FOUR = 4;
+     Integer FOUR = 4;
+    /**
+     * 四
+     */
+    String FOUR_S = "4";
 
     /**
      * 五
      */
-    public static final Integer FIVE = 5;
+     Integer FIVE = 5;
 
     /**
      * 六
      */
-    public static final Integer SIX = 6;
+     Integer SIX = 6;
 
     /**
      * 七
      */
-    public static final Integer SEVEN = 7;
+     Integer SEVEN = 7;
 
     /**
      * 八
      */
-    public static final Integer EIGHT = 8;
+     Integer EIGHT = 8;
 
     /**
      * 九
      */
-    public static final Integer NINE = 9;
+     Integer NINE = 9;
 
     /**
      * 10
      */
-    public static final Integer TEN = 10;
-
+     Integer TEN = 10;
+    /**
+     * 17
+     */
+     Integer SEVENTEEN=17;
+    /**
+     * 18
+     */
+     Integer EIGHTEEN=18;
     /**
      * 二十四
      */
-    public static final Integer TWENTY_FOUR = 24;
+     Integer TWENTY_FOUR = 24;
 
     /**
      * 三十
      */
-    public static final Integer THIRTY = 30;
+     Integer THIRTY = 30;
 
     /**
      * 五十八
      */
-    public static final Integer FIFTY_EIGHT = 58;
+     Integer FIFTY_EIGHT = 58;
 
     /**
      * 五十九
      */
-    public static final Integer FIFTY_NINE = 59;
+     Integer FIFTY_NINE = 59;
 
     /**
      * 一百
      */
-    public static final Integer ONE_HUNDRED = 100;
+     Integer ONE_HUNDRED = 100;
     /**
      * 一千
      */
-    public static final Integer ONE_THOUSAND = 1000;
+     Integer ONE_THOUSAND = 1000;
 
     /**
      * 负一
      */
-    public static final Integer NEGATIVE = -1;
+     Integer NEGATIVE = -1;
 
+    /**
+     * 十二
+     */
+    Integer  TWELVE = 12;
 
+    /**
+     * 十二
+     */
+    String  TWELVES = "12";
 }

+ 10 - 17
src/main/java/com/kcim/controller/DemoController.java

@@ -6,16 +6,13 @@ import com.kcim.util.Result;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import lombok.AllArgsConstructor;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestParam;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 /**
  * @program: center-parent
  * @description:
- * @author: Wang.YS
- * @create: 2023-11-30 20:13
+ * @author: jinhu
+ * @create: 2024-11-30 20:13
  **/
 
 @RestController
@@ -25,36 +22,32 @@ import org.springframework.web.bind.annotation.RestController;
 public class DemoController {
 
     DemoService demoService;
-    @ApiOperation("测试-新增")
+
     public Result testAdd(@RequestBody Test request){
-        demoService.testAdd(request);
+        demoService.add(request);
         return Result.ok();
     }
     @ApiOperation("测试-编辑")
     public Result testEdit(@RequestBody Test request){
-        demoService.testEdit(request);
+        demoService.edit(request);
         return Result.ok();
     }
 
     @ApiOperation("测试-删除")
     public Result testDelete(@RequestParam Integer id){
-        demoService.testDelete(id);
+        demoService.delete(id);
         return Result.ok();
     }
 
     @ApiOperation("测试-查询")
     public Result testQuery(@RequestParam(required = false,value = "name") String name){
-        return Result.ok(demoService.testQuery(name));
+        return Result.ok(demoService.get());
     }
     @ApiOperation("测试-分页查询")
     public Result testPage(@RequestParam(required = false,value = "current",defaultValue = "1")Integer current,
                            @RequestParam(required = false,value = "pageSize",defaultValue = "10")Integer pageSize,
                            @RequestParam(required = false,value = "name") String name){
 
-        return Result.ok(demoService.testPage(current,pageSize,name));
+        return Result.ok(demoService.getPage(current,pageSize));
     }
-
-
-
-
-}
+}

+ 94 - 0
src/main/java/com/kcim/dao/model/DoctorAttachment.java

@@ -0,0 +1,94 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * 
+ * 
+ * @author Wang.YS
+
+ * @date 2024-11-18 22:20:15
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("med_doctor_attachment")
+public class DoctorAttachment implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 主键
+	 */
+	@TableId
+	private Integer id;
+	/**
+	 * 
+	 */
+	private Long userId;
+	/**
+	 * 附件名称
+	 */
+	private String fileName;
+	/**
+	 * 附件链接
+	 */
+	private String url;
+	/**
+	 * 附件说明
+	 */
+	private String description;
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+	/**
+	 * 创建人
+	 */
+	@JsonIgnore
+	private String createUser;
+	/**
+	 * 创建时间
+	 */
+	@JsonIgnore
+	private Date createTime;
+	/**
+	 * 更新人
+	 */
+	@JsonIgnore
+	private String updateUser;
+	/**
+	 * 更新时间
+	 */
+	@JsonIgnore
+	private Date updateTime;
+	/**
+	 * 删除人
+	 */
+	@JsonIgnore
+	private String deleteUser;
+	/**
+	 * 删除时间
+	 */
+	@JsonIgnore
+	private Date deleteTime;
+	/**
+	 * 删除标志  0正常 1作废
+	 */
+	@JsonIgnore
+	@TableLogic(value = "0",delval = "1")
+	private Integer delFlag;
+
+}

+ 95 - 0
src/main/java/com/kcim/dao/model/HisItemDic.java

@@ -0,0 +1,95 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * HIS医嘱项目字典表
+ * 
+ * @author Wang.YS
+
+ * @date 2024-11-16 20:43:53
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("interface_his_item_dic")
+public class HisItemDic implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 
+	 */
+	@TableId
+	private Integer id;
+
+	/**
+	 * HIS医嘱类型
+	 */
+	private String hisItemType;
+	/**
+	 * HIS医嘱字典id
+	 */
+	private String hisItemId;
+	/**
+	 * HIS医嘱项目名称
+	 */
+	private String hisItemName;
+	/**
+	 * 备注
+	 */
+	private String memo;
+	/**
+	 * 创建人
+	 */
+	@JsonIgnore
+	private String createUser;
+	/**
+	 * 创建时间
+	 */
+	@JsonIgnore
+	private Date createTime;
+	/**
+	 * 更新人
+	 */
+	@JsonIgnore
+	private String updateUser;
+	/**
+	 * 更新时间
+	 */
+	@JsonIgnore
+	private Date updateTime;
+	/**
+	 * 删除人
+	 */
+	@JsonIgnore
+	private String deleteUser;
+	/**
+	 * 删除时间
+	 */
+	@JsonIgnore
+	private Date deleteTime;
+	/**
+	 * 删除标志  0正常 1作废
+	 */
+	@JsonIgnore
+	@TableLogic(value = "0",delval = "1")
+	private Integer delFlag;
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+
+}

+ 122 - 0
src/main/java/com/kcim/dao/model/QualificationApply.java

@@ -0,0 +1,122 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * 
+ * 
+ * @author Wang.YS
+
+ * @date 2024-11-18 22:20:15
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("med_qualification_apply")
+public class QualificationApply implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 主键
+	 */
+	@TableId
+	private Integer id;
+	/**
+	 * 资质编码
+	 */
+	private String qualificationCode;
+	/**
+	 * 用户id
+	 */
+	private Long userId;
+	/**
+	 * 授权期限 1长期授权 2临时授权 3单次授权
+	 */
+	private Integer qualificationPeriod;
+	/**
+	 * 申请授权时间
+	 */
+	private Date applyDate;
+	/**
+	 * 申请备注
+	 */
+	private String applyMemo;
+	/**
+	 * 授权开始时间
+	 */
+	private Date beginDate;
+	/**
+	 * 授权结束时间
+	 */
+	private Date endDate;
+	/**
+	 * 科主任审批意见
+	 */
+	private String deptOpinion;
+	/**
+	 * 医务部审批意见
+	 */
+	private String managerOpinion;
+	/**
+	 * 院领导审批意见
+	 */
+	private String masterOpinion;
+	/**
+	 * 申请状态 1草稿 2待科主任审核 3待医务部审核 4待院长审核 5审核通过 6驳回
+	 */
+	private Integer applyStatus;
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+	/**
+	 * 创建人
+	 */
+	@JsonIgnore
+	private String createUser;
+	/**
+	 * 创建时间
+	 */
+	@JsonIgnore
+	private Date createTime;
+	/**
+	 * 更新人
+	 */
+	@JsonIgnore
+	private String updateUser;
+	/**
+	 * 更新时间
+	 */
+	@JsonIgnore
+	private Date updateTime;
+	/**
+	 * 删除人
+	 */
+	@JsonIgnore
+	private String deleteUser;
+	/**
+	 * 删除时间
+	 */
+	@JsonIgnore
+	private Date deleteTime;
+	/**
+	 * 删除标志  0正常 1作废
+	 */
+	@JsonIgnore
+	@TableLogic(value = "0",delval = "1")
+	private Integer delFlag;
+
+}

+ 114 - 0
src/main/java/com/kcim/dao/model/QualificationApplyAdjust.java

@@ -0,0 +1,114 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * 
+ * 
+ * @author Wang.YS
+
+ * @date 2024-11-18 22:20:14
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("med_qualification_apply_adjust")
+public class QualificationApplyAdjust implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 主键
+	 */
+	@TableId
+	private Integer id;
+	/**
+	 * 资质申请id
+	 */
+	private Integer qualificationApplyId;
+	/**
+	 * 调整人id
+	 */
+	private Long userId;
+	/**
+	 * 调整前授权期限 1长期授权 2临时授权 3单次授权
+	 */
+	private Integer qualificationPeriodBefore;
+	/**
+	 * 调整后授权期限 1长期授权 2临时授权 3单次授权
+	 */
+	private Integer qualificationPeriodAfter;
+	/**
+	 * 调整前开始时间
+	 */
+	private Date beginDateBefore;
+	/**
+	 * 调整后开始时间
+	 */
+	private Date beginDateAfter;
+	/**
+	 * 调整前截止时间
+	 */
+	private Date endDateBefore;
+	/**
+	 * 调整后截止时间
+	 */
+	private Date endDateAfter;
+	/**
+	 * 调整原因
+	 */
+	private String memo;
+	/**
+	 * 创建人
+	 */
+	@JsonIgnore
+	private String createUser;
+	/**
+	 * 创建时间
+	 */
+	@JsonIgnore
+	private Date createTime;
+	/**
+	 * 更新人
+	 */
+	@JsonIgnore
+	private String updateUser;
+	/**
+	 * 更新时间
+	 */
+	@JsonIgnore
+	private Date updateTime;
+	/**
+	 * 删除人
+	 */
+	@JsonIgnore
+	private String deleteUser;
+	/**
+	 * 删除时间
+	 */
+	@JsonIgnore
+	private Date deleteTime;
+	/**
+	 * 删除标志  0正常 1作废
+	 */
+	@JsonIgnore
+	@TableLogic(value = "0",delval = "1")
+	private Integer delFlag;
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+
+}

+ 90 - 0
src/main/java/com/kcim/dao/model/QualificationApplyAttachment.java

@@ -0,0 +1,90 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * 
+ * 
+ * @author Wang.YS
+
+ * @date 2024-11-18 22:20:14
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("med_qualification_apply_attachment")
+public class QualificationApplyAttachment implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 主键
+	 */
+	@TableId
+	private Integer id;
+	/**
+	 * 资质申请id
+	 */
+	private Integer qualificationApplyId;
+	/**
+	 * 附件名称
+	 */
+	private String fileName;
+	/**
+	 * 附件链接
+	 */
+	private String url;
+	/**
+	 * 创建人
+	 */
+	@JsonIgnore
+	private String createUser;
+	/**
+	 * 创建时间
+	 */
+	@JsonIgnore
+	private Date createTime;
+	/**
+	 * 更新人
+	 */
+	@JsonIgnore
+	private String updateUser;
+	/**
+	 * 更新时间
+	 */
+	@JsonIgnore
+	private Date updateTime;
+	/**
+	 * 删除人
+	 */
+	@JsonIgnore
+	private String deleteUser;
+	/**
+	 * 删除时间
+	 */
+	@JsonIgnore
+	private Date deleteTime;
+	/**
+	 * 删除标志  0正常 1作废
+	 */
+	@JsonIgnore
+	@TableLogic(value = "0",delval = "1")
+	private Integer delFlag;
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+
+}

+ 96 - 0
src/main/java/com/kcim/dao/model/QualificationHisItem.java

@@ -0,0 +1,96 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * @author jinhu
+ * @date  2024-11-16 20:43:53
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("med_qualification_his_item")
+public class QualificationHisItem implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 主键
+	 */
+	@TableId
+	private Integer id;
+	/**
+	 * 资质id
+	 */
+	private Integer qualificationId;
+	/**
+	 * HIS医嘱项目id
+	 */
+	private Integer hisItemDicId;
+	/**
+	 * HIS医嘱类型
+	 */
+	private String hisItemType;
+	/**
+	 * HIS医嘱项目名称
+	 */
+	private String hisItemName;
+	/**
+	 * 备注
+	 */
+	private String memo;
+
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+	/**
+	 * 创建人
+	 */
+	@JsonIgnore
+	private String createUser;
+	/**
+	 * 创建时间
+	 */
+	@JsonIgnore
+	private Date createTime;
+	/**
+	 * 更新人
+	 */
+	@JsonIgnore
+	private String updateUser;
+	/**
+	 * 更新时间
+	 */
+	@JsonIgnore
+	private Date updateTime;
+	/**
+	 * 删除人
+	 */
+	@JsonIgnore
+	private String deleteUser;
+	/**
+	 * 删除时间
+	 */
+	@JsonIgnore
+	private Date deleteTime;
+	/**
+	 * 删除标志  0正常 1作废
+	 */
+	@JsonIgnore
+	@TableLogic(value = "0",delval = "1")
+	private Integer delFlag;
+
+}

+ 84 - 0
src/main/java/com/kcim/dao/model/UserInfo.java

@@ -0,0 +1,84 @@
+package com.kcim.dao.model;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.experimental.Accessors;
+
+/**
+ * VIEW
+ * 
+ * @author Wang.YS
+
+ * @date 2024-11-18 22:20:15
+ */
+@Data
+@Accessors(chain = true)
+@AllArgsConstructor
+@NoArgsConstructor
+@TableName("med_user_info")
+public class UserInfo implements Serializable {
+	private static final long serialVersionUID = 1L;
+
+	/**
+	 * 主键id
+	 */
+	@TableId
+	private Long id;
+	/**
+	 * 用户名
+	 */
+	private String name;
+	/**
+	 * 账号,医院中可能是工号
+	 */
+	private String account;
+	/**
+	 * 
+	 */
+	private String gender;
+	/**
+	 * 
+	 */
+	private String deptName;
+	/**
+	 * 
+	 */
+	private String title;
+	/**
+	 * 
+	 */
+	private String jobTitle;
+	/**
+	 * 资格证号
+	 */
+	private String qualificationCertificateNo;
+	/**
+	 * 执业证号
+	 */
+	private String practiceCertificateNo;
+	/**
+	 * 
+	 */
+	private String doctorLevel;
+	/**
+	 * 
+	 */
+	private String practiceCate;
+	/**
+	 * 
+	 */
+	private String major;
+	/**
+	 * 医院id
+	 */
+	@JsonIgnore
+	private Long hospId;
+
+}

+ 12 - 0
src/main/java/com/kcim/dao/repository/QualificationTypeRepository.java

@@ -0,0 +1,12 @@
+package com.kcim.dao.repository;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.kcim.dao.mapper.QualificationTypeMapper;
+import com.kcim.dao.model.QualificationType;
+import org.springframework.stereotype.Repository;
+
+@Repository
+public class QualificationTypeRepository extends ServiceImpl<QualificationTypeMapper, QualificationType> {
+
+}
+

+ 11 - 11
src/main/java/com/kcim/dao/repository/TestRepository.java

@@ -19,22 +19,22 @@ import java.util.List;
  **/
 @Repository
 public class TestRepository extends ServiceImpl<TestMapper, Test> {
-    public List<Test> getList(String name) {
-        LambdaQueryWrapper<Test> queryWrapper = new LambdaQueryWrapper<>();
-
-        if(StringUtils.isEmpty(name)){
-            queryWrapper.like(Test::getName,name);
-        }
-       return this.list(queryWrapper);
+    public List<Test> getList() {
+//        LambdaQueryWrapper<Test> queryWrapper = new LambdaQueryWrapper<>();
+//
+//        if(StringUtils.isEmpty(name)){
+//            queryWrapper.like(Test::getName,name);
+//        }
+       return this.list();
     }
 
-    public Page<Test> getPage(Integer current, Integer pageSize, String name) {
+    public Page<Test> getPage(Integer current, Integer pageSize) {
         Page<Test> page = new Page<>(current,pageSize);
         LambdaQueryWrapper<Test> queryWrapper = new LambdaQueryWrapper<>();
 
-        if(StringUtils.isEmpty(name)){
-            queryWrapper.like(Test::getName,name);
-        }
+//        if(StringUtils.isEmpty(name)){
+//            queryWrapper.like(Test::getName,name);
+//        }
       return  this.page(page,queryWrapper);
 
     }

+ 10 - 8
src/main/java/com/kcim/service/DemoService.java

@@ -1,21 +1,23 @@
 package com.kcim.service;
 
+import com.baomidou.mybatisplus.extension.service.IService;
 import com.kcim.dao.model.Test;
 
 /**
  * @program: center-parent
  * @description:
- * @author: Wang.YS
+ * @author: jinhu
  * @create: 2023-11-30 20:15
  **/
-public interface DemoService {
-    void testAdd(Test request);
+public interface DemoService extends IService<Test> {
 
-    void testEdit(Test request);
+    Object get();
 
-    void testDelete(Integer request);
+    void add(Test request);
 
-    Object testQuery(String name);
+    void edit(Test request);
 
-    Object testPage(Integer current, Integer pageSize, String name);
-}
+    void delete(Integer request);
+
+    Object getPage(Integer current, Integer pageSize);
+}

+ 15 - 18
src/main/java/com/kcim/service/impl/DemoServiceImpl.java

@@ -3,7 +3,11 @@ package com.kcim.service.impl;
 import com.baomidou.mybatisplus.annotation.TableLogic;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.kcim.constants.NumberConstant;
+import com.kcim.dao.mapper.QualificationMapper;
+import com.kcim.dao.mapper.TestMapper;
+import com.kcim.dao.model.Qualification;
 import com.kcim.dao.model.Test;
 import com.kcim.dao.repository.TestRepository;
 import com.kcim.service.DemoService;
@@ -29,15 +33,20 @@ import java.util.Objects;
 @Service("DemoService")
 @Slf4j
 @AllArgsConstructor
-public class DemoServiceImpl implements DemoService {
+public class DemoServiceImpl extends ServiceImpl<TestMapper, Test> implements DemoService {
     TestRepository repository;
 
+    @Override
+    public Object get() {
+        return null;
+    }
+
     /**
      * 测试-新增
      * @param request 入参
      */
     @Override
-    public void testAdd(Test request) {
+    public void add(Test request) {
         request.setCreateUser(String.valueOf(UserContext.getCurrentUser().getId()));
         request.setCreateTime(new Date());
         repository.save(request);
@@ -48,7 +57,7 @@ public class DemoServiceImpl implements DemoService {
      * @param request 入参
      */
     @Override
-    public void testEdit(Test request) {
+    public void edit(Test request) {
         Integer id = request.getId();
         Test byId = repository.getById(id);
         if(Objects.nonNull(byId)){
@@ -64,7 +73,7 @@ public class DemoServiceImpl implements DemoService {
      * @param id 主键
      */
     @Override
-    public void testDelete(Integer id) {
+    public void delete(Integer id) {
         Test byId = repository.getById(id);
         if(Objects.nonNull(byId)){
             byId.setUpdateTime(new Date());
@@ -77,30 +86,18 @@ public class DemoServiceImpl implements DemoService {
 
     }
 
-    /**
-     * 测试-查询
-     * @param name 名称过滤
-     * @return 符合条件的数据
-     */
-    @Override
-    public Object testQuery(String name) {
-       return repository.getList(name);
-    }
-
     /**
      * 测试分页查询
      * @param current 当前页
      * @param pageSize 页容量
-     * @param name 过滤名称
      * @return 分页列表
      */
     @Override
-    public Object testPage(Integer current, Integer pageSize, String name) {
-        Page<Test> page = repository.getPage(current, pageSize, name);
+    public Object getPage(Integer current, Integer pageSize) {
+        Page<Test> page = repository.getPage(current, pageSize);
         if(CollectionUtils.isEmpty(page.getRecords())){
            return new PageUtils(new ArrayList<>(), NumberConstant.ZERO,pageSize,current);
         }
         return new PageUtils(page.getRecords(), Math.toIntExact(page.getTotal()),pageSize,current);
-
     }
 }

+ 2 - 122
src/main/resources/application.yml

@@ -1,123 +1,3 @@
-server:
-  #端口号
-  port: 8701
-  servlet:
-    #网关配置的路由 按项目自行调整
-    context-path: /medical
 spring:
-  datasource:
-    type: com.zaxxer.hikari.HikariDataSource
-    driver-class-name: com.mysql.cj.jdbc.Driver
-    url: jdbc:mysql://120.27.235.181:3306/demo?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai
-    username: root
-    password: xywl2021!
-    hikari:
-      maximum-pool-size: 15
-      minimum-idle: 5
-      idle-timeout: 300000
-      connection-timeout: 300000
-      max-lifetime: 180000
-      auto-commit: true
-      connection-test-query: SELECT 1
-  application:
-    name: kcim-medical
-  cloud:
-    nacos: #注册nacos
-      discovery:
-        service: ${spring.application.name}
-        server-addr: 120.27.235.181:8848
-#        namespace: 38b4fbe9-4a20-48c3-a8bf-ebf069fb26e8
-#        group: KCIM
-        namespace: 060cc0fe-193f-4a94-bbca-6d48a4f95ac2
-        group: dev
-    sentinel:
-      enabled: true
-      transport:
-        port: 8719
-        dashboard: 120.27.235.181:8080
-  jackson:
-    date-format: yyyy-MM-dd hh:mm:ss
-    time-zone: GMT+8
-  #    default-property-inclusion: non_null
-  #redis
-  redis:
-    port: 6379
-    host: 120.27.235.181
-    password: xywl2021!
-    jedis:
-      pool:
-        max-active: 30
-        max-idle: 10
-        max-wait: -1
-        min-idle: 0
-    database: 1
-mybatis-plus:
-  mapper-locations: classpath*:/mapper/*.xml
-  type-aliases-package: com.kcim.model
-  configuration:
-    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
-  global-config:
-    db-config:
-      id-type: auto
-      logic-not-delete-value: 0
-      logic-delete-value: UNIX_TIMESTAMP(NOW()) * 1000
-    banner: false
-    enable-sql-runner: true
-
-#日志
-# log config
-logging:
-
-  #  config: classpath:log4j2.xml
-  level:
-    io.swagger.models.parameters.AbstractSerializableParameter: error
-    org.springframework.web: error
-    org.hibernate.SQL: debug
-    org.hibernate.engine.QueryParameters: debug
-    org.hibernate.engine.query.HQLQueryPlan: debug
-    org.hibernate.type.descriptor.sql.BasicBinder: trace
-####本地文件相关配置
-#file:
-#  filelocal: file:/image/
-#  #linux
-#  #  serverPath: /image
-#  #windows
-#  serverPath: /file
-#  #local
-#  #  serverUrl: http://112.124.59.133:8082//
-#  #linux
-#  serverUrl: http://47.96.149.190:8082/
-sa-token:
-  jwt-secret-key: kcim-oauth
-  #  kcim-oauth
-  ## 前后端分离不设置会有奇怪的问题
-  ## 默认采用的获取token 是从请求头默认名称为Sa-token的地方获取,如果没有会从Cookie中获取,会造成奇怪的问题!!
-  token-name: token
-  is-read-cookie: false
-  is-read-body: false
-  ##token 有效期 默认30天,到期强制登录
-  timeout: 2592000
-  ## 30分钟无操作就失效 不适用
-  activity-timeout: 1800
-  # 配置 Sa-Token 单独使用的 Redis 连接
-  alone-redis:
-    # Redis数据库索引(默认为0) 先固定2,后续有钱开另外的单独的db
-    database: 1
-    # Redis服务器地址
-    host: 120.27.235.181
-    # Redis服务器连接端口
-    port: 6379
-    # Redis服务器连接密码(默认为空)
-    password: xywl2021!
-    # 连接超时时间
-    timeout: 10s
-  #    host: 118.31.245.65
-  #    password: xywl2021#
-
-  is-log: false
-minio:
-  url: http://47.97.198.219:9000
-  port: 9000
-  access-key: UOxpxcO0loqZqKzH
-  secret-key: KfHhDLRWL0PtaWW0JTXqz6Gn685P2EWY
-  bucket-name: kcim-medical
+  profiles:
+    active: dev