作者 钟来

生成所有业务接口

  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<project xmlns="http://maven.apache.org/POM/4.0.0"
  3 + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4 + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  5 + <modelVersion>4.0.0</modelVersion>
  6 + <parent>
  7 + <groupId>com.zhonglai.luhui</groupId>
  8 + <artifactId>lh-common</artifactId>
  9 + <version>1.0.0</version>
  10 + </parent>
  11 +
  12 + <artifactId>lh-common-util</artifactId>
  13 +
  14 + <properties>
  15 + <maven.compiler.source>8</maven.compiler.source>
  16 + <maven.compiler.target>8</maven.compiler.target>
  17 + <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  18 + </properties>
  19 +
  20 + <dependencies>
  21 + <!-- JSON工具类 -->
  22 + <dependency>
  23 + <groupId>com.fasterxml.jackson.core</groupId>
  24 + <artifactId>jackson-databind</artifactId>
  25 + </dependency>
  26 + <!-- excel工具 -->
  27 + <dependency>
  28 + <groupId>org.apache.poi</groupId>
  29 + <artifactId>poi-ooxml</artifactId>
  30 + </dependency>
  31 + </dependencies>
  32 +</project>
1 -package com.ruoyi.common.annotation; 1 +package com.zhonglai.luhui.common.util.annotation;
2 2
3 import java.lang.annotation.ElementType; 3 import java.lang.annotation.ElementType;
4 import java.lang.annotation.Retention; 4 import java.lang.annotation.Retention;
@@ -7,7 +7,7 @@ import java.lang.annotation.Target; @@ -7,7 +7,7 @@ import java.lang.annotation.Target;
7 import java.math.BigDecimal; 7 import java.math.BigDecimal;
8 import org.apache.poi.ss.usermodel.HorizontalAlignment; 8 import org.apache.poi.ss.usermodel.HorizontalAlignment;
9 import org.apache.poi.ss.usermodel.IndexedColors; 9 import org.apache.poi.ss.usermodel.IndexedColors;
10 -import com.ruoyi.common.utils.poi.ExcelHandlerAdapter; 10 +import com.zhonglai.luhui.common.util.poi.ExcelHandlerAdapter;
11 11
12 /** 12 /**
13 * 自定义导出Excel数据注解 13 * 自定义导出Excel数据注解
1 -package com.ruoyi.common.annotation; 1 +package com.zhonglai.luhui.common.util.annotation;
2 2
3 import java.lang.annotation.ElementType; 3 import java.lang.annotation.ElementType;
4 import java.lang.annotation.Retention; 4 import java.lang.annotation.Retention;
1 -package com.ruoyi.common.core.domain; 1 +package com.zhonglai.luhui.common.util.domain;
2 2
3 import java.io.Serializable; 3 import java.io.Serializable;
4 import java.util.Date; 4 import java.util.Date;
@@ -38,6 +38,46 @@ public class BaseEntity implements Serializable @@ -38,6 +38,46 @@ public class BaseEntity implements Serializable
38 /** 备注 */ 38 /** 备注 */
39 private String remark; 39 private String remark;
40 40
  41 + private Map<String,Object[]> timeMap; //时间条件(如:{"create_time":[开始时间,结束时间]})
  42 +
  43 + private String[] keyValue; //模糊匹配的关键字(如:["value","name,no"])
  44 +
  45 + private Map<String, QueryType> queryParams; //字段对应的比较符号(如:{"id":"EQ"})
  46 +
  47 + private String orderBy; //排序(如:"id desc,name asc")
  48 +
  49 + public Map<String, Object[]> getTimeMap() {
  50 + return timeMap;
  51 + }
  52 +
  53 + public void setTimeMap(Map<String, Object[]> timeMap) {
  54 + this.timeMap = timeMap;
  55 + }
  56 +
  57 + public String[] getKeyValue() {
  58 + return keyValue;
  59 + }
  60 +
  61 + public void setKeyValue(String[] keyValue) {
  62 + this.keyValue = keyValue;
  63 + }
  64 +
  65 + public Map<String, QueryType> getQueryParams() {
  66 + return queryParams;
  67 + }
  68 +
  69 + public void setQueryParams(Map<String, QueryType> queryParams) {
  70 + this.queryParams = queryParams;
  71 + }
  72 +
  73 + public String getOrderBy() {
  74 + return orderBy;
  75 + }
  76 +
  77 + public void setOrderBy(String orderBy) {
  78 + this.orderBy = orderBy;
  79 + }
  80 +
41 /** 请求参数 */ 81 /** 请求参数 */
42 @JsonInclude(JsonInclude.Include.NON_EMPTY) 82 @JsonInclude(JsonInclude.Include.NON_EMPTY)
43 private Map<String, Object> params; 83 private Map<String, Object> params;
  1 +package com.zhonglai.luhui.common.util.domain;
  2 +
  3 +public enum QueryType {
  4 + /**
  5 + * 等于
  6 + */
  7 + EQ,
  8 + /**
  9 + * 不等于
  10 + */
  11 + NE,
  12 + /**
  13 + * 大于
  14 + */
  15 + GT,
  16 + /**
  17 + * 大于等于
  18 + */
  19 + GTE,
  20 + /**
  21 + * 小于
  22 + */
  23 + LT,
  24 + /**
  25 + * 小于等于
  26 + */
  27 + LTE,
  28 + /**
  29 + * 模糊匹配
  30 + */
  31 + LIKE
  32 +
  33 +}
1 -package com.ruoyi.common.utils.poi; 1 +package com.zhonglai.luhui.common.util.poi;
2 2
3 import org.apache.poi.ss.usermodel.Cell; 3 import org.apache.poi.ss.usermodel.Cell;
4 import org.apache.poi.ss.usermodel.Workbook; 4 import org.apache.poi.ss.usermodel.Workbook;