service位置调整
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
package com.czg.account.dto;
|
||||
|
||||
import jakarta.validation.constraints.Min;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
|
||||
public record PageDTO(
|
||||
// 页码
|
||||
@NotNull
|
||||
@Min(1)
|
||||
Integer page,
|
||||
// 数量
|
||||
@NotNull
|
||||
@Min(1)
|
||||
Integer size
|
||||
) {
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.czg.account.dto;
|
||||
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
|
||||
public record SysLoginDTO(
|
||||
@NotEmpty(message = "用户名不为空")
|
||||
String username, // 用户名
|
||||
@NotEmpty(message = "密码不为空")
|
||||
String password, // 密码
|
||||
@NotEmpty(message = "验证码不为空")
|
||||
String code, // 验证码
|
||||
@NotEmpty(message = "uid不为空")
|
||||
String uuid, // 验证码uid
|
||||
@NotNull
|
||||
Integer loginType // 登录类型 0:商户登录 1:员工登录
|
||||
) {
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.czg.account.dto.merchant;
|
||||
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
@Data
|
||||
public class ShopMerchantEditDTO {
|
||||
@NotEmpty(message = "支付系统商户id不为空")
|
||||
private String storeId;
|
||||
@NotEmpty(message = "商户应用id不为空")
|
||||
private String appId;
|
||||
@NotEmpty(message = "商户秘钥不为空")
|
||||
private String appSecret;
|
||||
// 支付密码
|
||||
@NotEmpty(message = "支付密码不为空")
|
||||
private String payPassword;
|
||||
// 微信appid
|
||||
@NotEmpty(message = "微信appid")
|
||||
private String wechatSmallAppid;
|
||||
// 支付宝appid
|
||||
@NotEmpty(message = "支付宝appid")
|
||||
private String alipaySmallAppid;
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.czg.account.dto.register;
|
||||
|
||||
import jakarta.validation.constraints.Max;
|
||||
import jakarta.validation.constraints.Min;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
|
||||
public record MerchantRegisterDTO(
|
||||
@NotNull(message = "激活时长不能为空")
|
||||
@Min(1)
|
||||
Integer periodMonth,
|
||||
@NotNull(message = "数量不为空")
|
||||
@Min(1)
|
||||
@Max(10)
|
||||
Integer num
|
||||
) {
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.czg.account.dto.role;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public record RoleAddDTO(
|
||||
/* 角色名称 */
|
||||
@NotBlank
|
||||
String name,
|
||||
// 角色级别
|
||||
Integer level,
|
||||
// 菜单id
|
||||
@NotEmpty(message = "菜单id不能为空")
|
||||
List<Long> menuIdList,
|
||||
// 描述
|
||||
String description
|
||||
) {
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package com.czg.account.dto.role;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
@Data
|
||||
public class RoleEditDTO {
|
||||
// 角色id
|
||||
@NotNull
|
||||
private Long id;
|
||||
// 角色名称
|
||||
@NotBlank
|
||||
private String name;
|
||||
// 角色等级
|
||||
private Integer level;
|
||||
// 菜单id
|
||||
@NotNull
|
||||
private List<Long> menuIdList;
|
||||
// 描述
|
||||
private String description;
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
package com.czg.account.dto.role;
|
||||
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
|
||||
|
||||
public record RoleRemoveDTO(/* 角色id */@NotNull Long id) {
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
package com.czg.account.dto.shopinfo;
|
||||
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
@Data
|
||||
public class ShopInfoAddDTO {
|
||||
@NotEmpty(message = "店铺名称不为空")
|
||||
private String shopName;
|
||||
@NotEmpty(message = "店铺类型不为空")
|
||||
private String shopType;
|
||||
private String chainName;
|
||||
@NotEmpty(message = "店铺logo不为空")
|
||||
private String logo;
|
||||
@NotEmpty(message = "门头照不为空")
|
||||
private String frontImg;
|
||||
@NotEmpty(message = "试用/正式不为空")
|
||||
private String profiles;
|
||||
@NotEmpty(message = "激活码不为空")
|
||||
private String activateCode;
|
||||
@NotEmpty(message = "登录账号不为空")
|
||||
private String accountName;
|
||||
@NotEmpty(message = "登录密码不为空")
|
||||
private String accountPwd;
|
||||
@NotEmpty(message = "经度不为空")
|
||||
private String lat;
|
||||
@NotEmpty(message = "纬度不为空")
|
||||
private String lng;
|
||||
@NotNull(message = "状态不为空")
|
||||
private String detail;
|
||||
@NotNull(message = "角色id不为空")
|
||||
private Long roleId;
|
||||
private String address;
|
||||
private String phone;
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.czg.account.dto.shopinfo;
|
||||
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
@Data
|
||||
public class ShopInfoEditDTO {
|
||||
@NotNull(message = "id不为空")
|
||||
private Integer id;
|
||||
private String shopName;
|
||||
private String shopType;
|
||||
private String chainName;
|
||||
private String logo;
|
||||
private String frontImg;
|
||||
private String profiles;
|
||||
private String activateCode;
|
||||
private String accountName;
|
||||
private String accountPwd;
|
||||
private String lat;
|
||||
private String lng;
|
||||
private String detail;
|
||||
private Long roleId;
|
||||
private String address;
|
||||
private String phone;
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.czg.account.dto.shopuser;
|
||||
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
|
||||
public record ShopUserAddDTO(@NotEmpty(message = "店铺名称不为空") String shopName,
|
||||
@NotEmpty(message = "logo不为空") String logo,
|
||||
@NotEmpty String profiles,
|
||||
@NotNull(message = "店铺类型不为空") Integer shopType,
|
||||
@NotEmpty(message = "经营模式不为空") String registerType,
|
||||
@NotEmpty(message = "账号不为空") String loginName,
|
||||
@NotEmpty(message = "密码不为空") String loginPwd,
|
||||
@NotEmpty(message = "经度不为空") String lat,
|
||||
@NotEmpty(message = "维度不为空") String lng,
|
||||
@NotEmpty(message = "详细地址不为空") String address,
|
||||
@NotNull(message = "店铺状态不为空") Integer status,
|
||||
String detail,
|
||||
String phone,
|
||||
String activateCode,
|
||||
String coverImg,
|
||||
String chainName) {
|
||||
}
|
||||
@@ -0,0 +1,70 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 激活码 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-11
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_merchant_register")
|
||||
public class MerchantRegister implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 激活码
|
||||
*/
|
||||
private String registerCode;
|
||||
|
||||
/**
|
||||
* 店铺id
|
||||
*/
|
||||
private String shopId;
|
||||
|
||||
/**
|
||||
* 激活码金额
|
||||
*/
|
||||
private BigDecimal amount;
|
||||
|
||||
/**
|
||||
* 激活时长(月)
|
||||
*/
|
||||
private Integer periodMonth;
|
||||
|
||||
/**
|
||||
* 状态0未使用1已使用
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,272 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 店铺信息 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_shop_info")
|
||||
public class ShopInfo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 使用系统用户 sys_user id
|
||||
*/
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 主店id
|
||||
*/
|
||||
private Integer mainId;
|
||||
|
||||
/**
|
||||
* 店铺口号
|
||||
*/
|
||||
private String subTitle;
|
||||
|
||||
/**
|
||||
* 店铺名称
|
||||
*/
|
||||
private String shopName;
|
||||
|
||||
/**
|
||||
* 连锁店扩展店名
|
||||
*/
|
||||
private String chainName;
|
||||
|
||||
/**
|
||||
* 背景图
|
||||
*/
|
||||
private String backImg;
|
||||
|
||||
/**
|
||||
* 门头照
|
||||
*/
|
||||
private String frontImg;
|
||||
|
||||
/**
|
||||
* 联系人姓名
|
||||
*/
|
||||
private String contactName;
|
||||
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
private String phone;
|
||||
|
||||
/**
|
||||
* 店铺logo
|
||||
*/
|
||||
private String logo;
|
||||
|
||||
/**
|
||||
* 封面图
|
||||
*/
|
||||
private String coverImg;
|
||||
|
||||
/**
|
||||
* 店铺简介
|
||||
*/
|
||||
private String detail;
|
||||
|
||||
private String registerType;
|
||||
|
||||
/**
|
||||
* 店铺类型 单店--only 连锁店--chain--加盟店join (对应原来 type)
|
||||
*/
|
||||
private String shopType;
|
||||
|
||||
/**
|
||||
* 管理 0否 1是, 1 为直接管理 可切换店铺 0 不可以切换
|
||||
*/
|
||||
private Integer tubeType;
|
||||
|
||||
/**
|
||||
* 营业时间(周开始)
|
||||
*/
|
||||
private String businessStartDay;
|
||||
|
||||
/**
|
||||
* 营业时间(周结束)
|
||||
*/
|
||||
private String businessEndDay;
|
||||
|
||||
/**
|
||||
* 营业时间
|
||||
*/
|
||||
private String businessTime;
|
||||
|
||||
/**
|
||||
* trial试用版,release正式
|
||||
*/
|
||||
private String profiles;
|
||||
|
||||
/**
|
||||
* 0停业 1,正常营业 2,网上售卖
|
||||
*/
|
||||
private Integer onSale;
|
||||
|
||||
/**
|
||||
* -1 平台禁用 0-过期,1正式营业,
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 到期时间
|
||||
*/
|
||||
private LocalDateTime expireTime;
|
||||
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
/**
|
||||
* 商家二维码
|
||||
*/
|
||||
private String shopQrcode;
|
||||
|
||||
/**
|
||||
* 商家标签
|
||||
*/
|
||||
private String tag;
|
||||
|
||||
/**
|
||||
* 经纬度
|
||||
*/
|
||||
private String lat;
|
||||
|
||||
/**
|
||||
* 经纬度
|
||||
*/
|
||||
private String lng;
|
||||
|
||||
/**
|
||||
* 省
|
||||
*/
|
||||
private String provinces;
|
||||
|
||||
/**
|
||||
* 市
|
||||
*/
|
||||
private String cities;
|
||||
|
||||
/**
|
||||
* 区/县
|
||||
*/
|
||||
private String districts;
|
||||
|
||||
/**
|
||||
* 详细地址
|
||||
*/
|
||||
private String address;
|
||||
|
||||
/**
|
||||
* 是否允许会员自定义金额 1 允许 0 不允许
|
||||
*/
|
||||
private Integer isCustomAmount;
|
||||
|
||||
/**
|
||||
* 是否开启退款密码 1 启用 0 禁用
|
||||
*/
|
||||
private Integer isReturnPwd;
|
||||
|
||||
/**
|
||||
* 是否开启会员充值密码 1 启用 0 禁用
|
||||
*/
|
||||
private Integer isMemberInPwd;
|
||||
|
||||
/**
|
||||
* 是否开启会员退款密码 1 启用 0 禁用
|
||||
*/
|
||||
private Integer isMemberReturnPwd;
|
||||
|
||||
/**
|
||||
* 是否免除桌位费 0否1是
|
||||
*/
|
||||
private Integer isTableFee;
|
||||
|
||||
/**
|
||||
* 桌位费
|
||||
*/
|
||||
private BigDecimal tableFee;
|
||||
|
||||
/**
|
||||
* 是否启用会员价 0否1是
|
||||
*/
|
||||
private Integer isMemberPrice;
|
||||
|
||||
/**
|
||||
* 积分群体 all-所有 vip-仅针对会员
|
||||
*/
|
||||
private String consumeColony;
|
||||
|
||||
/**
|
||||
* 就餐模式 堂食 dine-in 外带 take-out
|
||||
*/
|
||||
private String eatModel;
|
||||
|
||||
/**
|
||||
* 小程序码(零点八零首页)
|
||||
*/
|
||||
private String smallQrcode;
|
||||
|
||||
/**
|
||||
* 店铺收款码
|
||||
*/
|
||||
private String paymentQrcode;
|
||||
|
||||
/**
|
||||
* 台桌预订短信
|
||||
*/
|
||||
private String bookingSms;
|
||||
|
||||
/**
|
||||
* 操作密码
|
||||
*/
|
||||
private String operationPwd;
|
||||
|
||||
/**
|
||||
* 开票系统账号
|
||||
*/
|
||||
private String bindAccount;
|
||||
|
||||
/**
|
||||
* 项目分类
|
||||
*/
|
||||
private String article;
|
||||
|
||||
/**
|
||||
* 数电发票类型
|
||||
*/
|
||||
private String sdType;
|
||||
|
||||
/**
|
||||
* 税率
|
||||
*/
|
||||
private String taxAmount;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 第三方商户进件 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-11
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_shop_merchant")
|
||||
public class ShopMerchant implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 店铺id
|
||||
*/
|
||||
@Id
|
||||
private Long shopId;
|
||||
|
||||
/**
|
||||
* 支付系统商户id
|
||||
*/
|
||||
private String storeId;
|
||||
|
||||
/**
|
||||
* 商户应用id
|
||||
*/
|
||||
private String appId;
|
||||
|
||||
/**
|
||||
* 商户token
|
||||
*/
|
||||
private String appSecret;
|
||||
|
||||
/**
|
||||
* 微信小程序appid
|
||||
*/
|
||||
private String wechatSmallAppid;
|
||||
|
||||
/**
|
||||
* 支付宝小程序appid
|
||||
*/
|
||||
private String alipaySmallAppid;
|
||||
|
||||
/**
|
||||
* 支付密码
|
||||
*/
|
||||
private String payPassword;
|
||||
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 店铺员工 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_shop_staff")
|
||||
public class ShopStaff implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 使用系统用户 sys_user id
|
||||
*/
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 员工编号
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 员工名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 最大优惠金额
|
||||
*/
|
||||
private BigDecimal maxDiscountAmount;
|
||||
|
||||
/**
|
||||
* 优惠类型 1 折扣 0 金额
|
||||
*/
|
||||
private String discountType;
|
||||
|
||||
/**
|
||||
* 1启用0不启用
|
||||
*/
|
||||
private Boolean status;
|
||||
|
||||
/**
|
||||
* shopId
|
||||
*/
|
||||
private String shopId;
|
||||
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
/**
|
||||
* master商户账号staff员工
|
||||
*/
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* 是否允许管理端登录 0:不允许;1:允许
|
||||
*/
|
||||
private Integer isManage;
|
||||
|
||||
/**
|
||||
* 是否允许pc端登录 0:不允许;1:允许
|
||||
*/
|
||||
private Integer isPc;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,110 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 商户储值会员 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-08
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_shop_user")
|
||||
public class ShopUser implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* (随机)
|
||||
*/
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 店铺Id
|
||||
*/
|
||||
private Long shopId;
|
||||
|
||||
/**
|
||||
* 用户Id
|
||||
*/
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 账户积分
|
||||
*/
|
||||
private Integer accountPoints;
|
||||
|
||||
/**
|
||||
* 钱包余额
|
||||
*/
|
||||
private BigDecimal amount;
|
||||
|
||||
/**
|
||||
* 消费累计
|
||||
*/
|
||||
private BigDecimal consumeAmount;
|
||||
|
||||
/**
|
||||
* 消费次数累计
|
||||
*/
|
||||
private Integer consumeCount;
|
||||
|
||||
/**
|
||||
* 0-不可使用 1可使用
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 是否会员,
|
||||
*/
|
||||
private Integer isVip;
|
||||
|
||||
/**
|
||||
* 会员编号
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 会员码
|
||||
*/
|
||||
private String dynamicCode;
|
||||
|
||||
/**
|
||||
* 最近一次积分变动时间
|
||||
*/
|
||||
private LocalDateTime lastPointsChangeTime;
|
||||
|
||||
/**
|
||||
* 最近一次浮动积分
|
||||
*/
|
||||
private Integer lastFloatPoints;
|
||||
|
||||
/**
|
||||
* 成为会员的时间
|
||||
*/
|
||||
private LocalDateTime joinTime;
|
||||
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,135 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 系统菜单 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("sys_menu")
|
||||
public class SysMenu implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Long menuId;
|
||||
|
||||
/**
|
||||
* 上级菜单ID
|
||||
*/
|
||||
private Long pid;
|
||||
|
||||
/**
|
||||
* 子菜单数目
|
||||
*/
|
||||
private Integer subCount;
|
||||
|
||||
/**
|
||||
* 菜单类型 0 菜单 1按钮 3接口
|
||||
*/
|
||||
private Integer type;
|
||||
|
||||
/**
|
||||
* 菜单标题
|
||||
*/
|
||||
private String title;
|
||||
|
||||
/**
|
||||
* 组件名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 组件
|
||||
*/
|
||||
private String component;
|
||||
|
||||
/**
|
||||
* 排序
|
||||
*/
|
||||
private Integer menuSort;
|
||||
|
||||
/**
|
||||
* 图标
|
||||
*/
|
||||
private String icon;
|
||||
|
||||
/**
|
||||
* 链接地址
|
||||
*/
|
||||
private String path;
|
||||
|
||||
/**
|
||||
* 是否外链
|
||||
*/
|
||||
private Boolean iFrame;
|
||||
|
||||
/**
|
||||
* 缓存
|
||||
*/
|
||||
private Boolean cache;
|
||||
|
||||
/**
|
||||
* 隐藏
|
||||
*/
|
||||
private Boolean hidden;
|
||||
|
||||
/**
|
||||
* 权限
|
||||
*/
|
||||
private String permission;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
private String createBy;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
private String updateBy;
|
||||
|
||||
/**
|
||||
* 创建日期
|
||||
*/
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
/**
|
||||
* 是否选中父级菜单
|
||||
*/
|
||||
private String activeMenu;
|
||||
|
||||
/**
|
||||
* 商户使用 0:否;1:是;
|
||||
*/
|
||||
private Long isShop;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,80 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 角色表 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-08
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("sys_role")
|
||||
public class SysRole implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 角色级别
|
||||
*/
|
||||
private Integer level;
|
||||
|
||||
/**
|
||||
* 商户id
|
||||
*/
|
||||
private Long shopId;
|
||||
|
||||
/**
|
||||
* 描述
|
||||
*/
|
||||
private String description;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
private Long createUserId;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
private Long updateUserId;
|
||||
|
||||
/**
|
||||
* 创建日期
|
||||
*/
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 角色菜单关联 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("sys_roles_menus")
|
||||
public class SysRolesMenus implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 菜单ID
|
||||
*/
|
||||
@Id
|
||||
private Long menuId;
|
||||
|
||||
/**
|
||||
* 角色ID
|
||||
*/
|
||||
@Id
|
||||
private Long roleId;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,110 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Column;
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.KeyType;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 系统用户 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-08
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("sys_user")
|
||||
public class SysUser implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
@Id(keyType = KeyType.Auto)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 账号
|
||||
*/
|
||||
private String account;
|
||||
|
||||
/**
|
||||
* 昵称
|
||||
*/
|
||||
private String nickName;
|
||||
|
||||
/**
|
||||
* 性别
|
||||
*/
|
||||
private String gender;
|
||||
|
||||
/**
|
||||
* 手机号码
|
||||
*/
|
||||
private String phone;
|
||||
|
||||
/**
|
||||
* 邮箱
|
||||
*/
|
||||
private String email;
|
||||
|
||||
/**
|
||||
* 头像
|
||||
*/
|
||||
private String avatar;
|
||||
|
||||
/**
|
||||
* 密码
|
||||
*/
|
||||
private String password;
|
||||
|
||||
/**
|
||||
* 是否为admin账号
|
||||
*/
|
||||
private Boolean isAdmin;
|
||||
|
||||
/**
|
||||
* 状态:1启用、0禁用
|
||||
*/
|
||||
private Integer stauts;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
private Long createUserId;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
private Long updateUserId;
|
||||
|
||||
/**
|
||||
* 修改密码的时间
|
||||
*/
|
||||
private LocalDateTime pwdResetTime;
|
||||
|
||||
/**
|
||||
* 创建日期
|
||||
*/
|
||||
@Column(onInsertValue = "now()")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.czg.account.entity;
|
||||
|
||||
import com.mybatisflex.annotation.Id;
|
||||
import com.mybatisflex.annotation.Table;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 用户角色关联 实体类。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("sys_users_roles")
|
||||
public class SysUsersRoles implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
@Id
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 角色ID
|
||||
*/
|
||||
@Id
|
||||
private Long roleId;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
|
||||
import com.czg.account.dto.SysLoginDTO;
|
||||
import com.czg.account.vo.LoginVO;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
public interface AuthorizationService {
|
||||
Object getCaptcha();
|
||||
|
||||
LoginVO login(SysLoginDTO loginDTO);
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.dto.PageDTO;
|
||||
import com.czg.account.dto.register.MerchantRegisterDTO;
|
||||
import com.czg.account.entity.MerchantRegister;
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 激活码 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-11
|
||||
*/
|
||||
public interface MerchantRegisterService extends IService<MerchantRegister> {
|
||||
|
||||
Page<MerchantRegister> get(PageDTO pageDTO, Integer state, String startTime, String endTime);
|
||||
|
||||
Boolean add(MerchantRegisterDTO merchantRegisterDTO);
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
public interface PermissionService {
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.dto.PageDTO;
|
||||
import com.czg.account.dto.shopinfo.ShopInfoAddDTO;
|
||||
import com.czg.account.dto.shopinfo.ShopInfoEditDTO;
|
||||
import com.czg.account.entity.ShopInfo;
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
public interface ShopInfoService extends IService<ShopInfo> {
|
||||
Page<ShopInfo> get(PageDTO pageDTO, String shopName, Integer status);
|
||||
|
||||
Boolean add(ShopInfoAddDTO shopInfoAddDTO);
|
||||
|
||||
Boolean edit(ShopInfoEditDTO shopInfoEditDTO);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.dto.merchant.ShopMerchantEditDTO;
|
||||
import com.czg.account.entity.ShopMerchant;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 第三方商户进件 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-11
|
||||
*/
|
||||
public interface ShopMerchantService extends IService<ShopMerchant> {
|
||||
|
||||
ShopMerchant detail();
|
||||
|
||||
Boolean edit(ShopMerchantEditDTO shopMerchantEditDTO);
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.entity.ShopStaff;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 店铺员工 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
public interface ShopStaffService extends IService<ShopStaff> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.entity.ShopUser;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 商户储值会员 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-08
|
||||
*/
|
||||
public interface ShopUserService extends IService<ShopUser> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.entity.SysMenu;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 系统菜单 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
public interface SysMenuService extends IService<SysMenu> {
|
||||
|
||||
Object getMenu();
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.dto.PageDTO;
|
||||
import com.czg.account.dto.role.RoleAddDTO;
|
||||
import com.czg.account.dto.role.RoleEditDTO;
|
||||
import com.czg.account.entity.SysRole;
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 角色表 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-08
|
||||
*/
|
||||
public interface SysRoleService extends IService<SysRole> {
|
||||
|
||||
List<SysRole> getByUserId(Long id);
|
||||
|
||||
Page<SysRole> getList(PageDTO pageDTO, String key, String startTime, String endTime);
|
||||
|
||||
Boolean add(RoleAddDTO roleAddDTO);
|
||||
|
||||
Boolean edit(RoleEditDTO roleEditDTO);
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.entity.SysRolesMenus;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 角色菜单关联 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
public interface SysRolesMenusService extends IService<SysRolesMenus> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.entity.SysUser;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 系统用户 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-08
|
||||
*/
|
||||
public interface SysUserService extends IService<SysUser> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.entity.SysUsersRoles;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
/**
|
||||
* 用户角色关联 服务层。
|
||||
*
|
||||
* @author Administrator
|
||||
* @since 2025-02-10
|
||||
*/
|
||||
public interface SysUsersRolesService extends IService<SysUsersRoles> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.czg.account.vo;
|
||||
|
||||
|
||||
import com.czg.account.entity.ShopInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public record LoginVO(
|
||||
// token信息
|
||||
Object tokenInfo,
|
||||
// 接口权限集合
|
||||
List<String> promissionList,
|
||||
// 登录类型
|
||||
Integer loginType,
|
||||
// 店铺信息
|
||||
ShopInfo shopInfo
|
||||
) {
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.czg.account.vo;
|
||||
|
||||
import com.czg.account.entity.SysMenu;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* @author Administrator
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
public class MenuVO extends SysMenu {
|
||||
private List<MenuVO> children;
|
||||
private List<String> permissions;
|
||||
}
|
||||
Reference in New Issue
Block a user