From 7e2fe90b96bfb1fd69a49e8af1e2ebf396727f67 Mon Sep 17 00:00:00 2001 From: wxy Date: Wed, 27 Mar 2024 21:30:58 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/muyu/product/domain/Ladder.java | 26 ++++ .../com/muyu/product/domain/Preference.java | 33 +++++ .../muyu/product/domain/util/Constants.java | 133 ++++++++++++++++++ 3 files changed, 192 insertions(+) create mode 100644 muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Ladder.java create mode 100644 muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Preference.java create mode 100644 muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/util/Constants.java diff --git a/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Ladder.java b/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Ladder.java new file mode 100644 index 0000000..7a595ba --- /dev/null +++ b/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Ladder.java @@ -0,0 +1,26 @@ +package com.muyu.product.domain; + +import com.muyu.common.core.web.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @ClassName ladder + * @Description 描述 + * @Author 龙 + * @Date 2024/3/24 10:10 + */ +@Data +@ApiModel(value = "Ladder", description = "阶梯信息") +public class Ladder extends BaseEntity { + + @ApiModelProperty(value = "阶梯ID") + private Integer id; + + @ApiModelProperty(value = "阶梯数量") + private Integer ladderNum; + + @ApiModelProperty(value = "阶梯折扣") + private Double ladderDiscount; +} diff --git a/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Preference.java b/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Preference.java new file mode 100644 index 0000000..e5b4b1e --- /dev/null +++ b/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/Preference.java @@ -0,0 +1,33 @@ +package com.muyu.product.domain; + + +import com.fasterxml.jackson.annotation.JsonFormat; +import com.muyu.common.core.web.domain.BaseEntity; +import lombok.Data; + +import java.util.Date; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; + +/** + * @author A3385 + + */ +@Data +@ApiModel(value = "Preference", description = "特惠信息") +public class Preference extends BaseEntity { + + @ApiModelProperty(value = "特惠ID") + private Integer id; + + @ApiModelProperty(value = "特惠开始时间") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") + private Date preferenceStartTime; + + @ApiModelProperty(value = "特惠结束时间") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") + private Date preferenceEndTime; + + @ApiModelProperty(value = "促销价格") + private Double preferencePrice; +} diff --git a/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/util/Constants.java b/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/util/Constants.java new file mode 100644 index 0000000..8297ccc --- /dev/null +++ b/muyu-modules/muyu-product/muyu-product-commo/src/main/java/com/muyu/product/domain/util/Constants.java @@ -0,0 +1,133 @@ +package com.muyu.product.domain.util; + +/** + * @Author: wangxinyuan + * @Date: 2024/3/27 21:20 + */ +public class Constants { + /** + * UTF-8 字符集 + */ + public static final String UTF8 = "UTF-8"; + + /** + * GBK 字符集 + */ + public static final String GBK = "GBK"; + + /** + * www主域 + */ + public static final String WWW = "www."; + + /** + * RMI 远程方法调用 + */ + public static final String LOOKUP_RMI = "rmi:"; + + /** + * LDAP 远程方法调用 + */ + public static final String LOOKUP_LDAP = "ldap:"; + + /** + * LDAPS 远程方法调用 + */ + public static final String LOOKUP_LDAPS = "ldaps:"; + + /** + * http请求 + */ + public static final String HTTP = "http://"; + + /** + * https请求 + */ + public static final String HTTPS = "https://"; + + /** + * 成功标记 + */ + public static final Integer SUCCESS = 200; + + /** + * 失败标记 + */ + public static final Integer FAIL = 500; + + /** + * 登录成功状态 + */ + public static final String LOGIN_SUCCESS_STATUS = "0"; + + /** + * 登录失败状态 + */ + public static final String LOGIN_FAIL_STATUS = "1"; + + /** + * 登录成功 + */ + public static final String LOGIN_SUCCESS = "Success"; + + /** + * 注销 + */ + public static final String LOGOUT = "Logout"; + + /** + * 注册 + */ + public static final String REGISTER = "Register"; + + /** + * 登录失败 + */ + public static final String LOGIN_FAIL = "Error"; + + /** + * 当前记录起始索引 + */ + public static final String PAGE_NUM = "pageNum"; + + /** + * 每页显示记录数 + */ + public static final String PAGE_SIZE = "pageSize"; + + /** + * 排序列 + */ + public static final String ORDER_BY_COLUMN = "orderByColumn"; + + /** + * 排序的方向 "desc" 或者 "asc". + */ + public static final String IS_ASC = "isAsc"; + + /** + * 验证码有效期(分钟) + */ + public static final long CAPTCHA_EXPIRATION = 2; + + /** + * 资源映射路径 前缀 + */ + public static final String RESOURCE_PREFIX = "/profile"; + + /** + * 自动识别json对象白名单配置(仅允许解析的包名,范围越小越安全) + */ + public static final String[] JSON_WHITELIST_STR = { "org.springframework", "com.bwie" }; + + /** + * 定时任务白名单配置(仅允许访问的包名,如其他需要可以自行添加) + */ + public static final String[] JOB_WHITELIST_STR = { "com.bwie.job.task" }; + + /** + * 定时任务违规的字符 + */ + public static final String[] JOB_ERROR_STR = { "java.net.URL", "javax.naming.InitialContext", "org.yaml.snakeyaml", + "org.springframework", "org.apache", "com.bwie.common.core.utils.file" }; +}