release- 新增表tb_bank,tb_user_bank,tb_withdraw

release-2024-08-08
pikaqiudeshujia 7 months ago
parent 185723b345
commit 0ca8b1bab8

@ -0,0 +1,16 @@
package com.luoo.user.dao;
import com.luoo.user.pojo.TbBank;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
/**
* @Author: yawei.huang
* @Package: com.luoo.user.dao
* @Project: luoo_parent
* @Date: 2024/5/11 10:59
* @Filename: TbBankDao
* @Describe:
*/
public interface TbBankDao extends JpaRepository<TbBank, String>, JpaSpecificationExecutor<TbBank> {
}

@ -0,0 +1,16 @@
package com.luoo.user.dao;
import com.luoo.user.pojo.TbUserBank;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
/**
* @Author: yawei.huang
* @Package: com.luoo.user.dao
* @Project: luoo_parent
* @Date: 2024/5/11 10:59
* @Filename: TbUserBankDao
* @Describe:
*/
public interface TbUserBankDao extends JpaRepository<TbUserBank, String>, JpaSpecificationExecutor<TbUserBank> {
}

@ -0,0 +1,16 @@
package com.luoo.user.dao;
import com.luoo.user.pojo.TbWithdraw;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
/**
* @Author: yawei.huang
* @Package: com.luoo.user.dao
* @Project: luoo_parent
* @Date: 2024/5/11 11:00
* @Filename: TbWithdrawDao
* @Describe:
*/
public interface TbWithdrawDao extends JpaRepository<TbWithdraw, String>, JpaSpecificationExecutor<TbWithdraw> {
}

@ -0,0 +1,29 @@
package com.luoo.user.pojo;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;
@Builder
@AllArgsConstructor
@NoArgsConstructor
@Getter
@Setter
@ToString
@Entity
@Table(name = "tb_bank")
public class TbBank implements Serializable {
@Id
private String id;
@ApiModelProperty(value = "银行名称")
private String name;
@ApiModelProperty(value = "银行logo")
private String logo;
}

@ -0,0 +1,64 @@
package com.luoo.user.pojo;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.format.annotation.DateTimeFormat;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;
import java.time.Instant;
@Builder
@AllArgsConstructor
@NoArgsConstructor
@Getter
@Setter
@ToString
@Entity
@Table(name = "tb_user_bank")
public class TbUserBank implements Serializable {
@Id
private String id;
@ApiModelProperty(value = "银行卡号")
private String bankCard;
@ApiModelProperty(value = "银行id")
private String bankId;
@ApiModelProperty(value = "银行名称")
private String bankName;
@ApiModelProperty(value = "手机号")
private String phone;
@ApiModelProperty(value = "用户id")
private String userId;
@ApiModelProperty(value = "状态 1-绑定 2-解绑")
private Integer state;
@ApiModelProperty(value = "创建时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@CreatedDate
private Instant createTime;
@ApiModelProperty(value = "修改时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@LastModifiedDate
private Instant updateTime;
@ApiModelProperty(value = "创建人")
private String createUser;
@ApiModelProperty(value = "修改人")
private String updateUser;
}

@ -0,0 +1,52 @@
package com.luoo.user.pojo;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.format.annotation.DateTimeFormat;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.Instant;
@Builder
@AllArgsConstructor
@NoArgsConstructor
@Getter
@Setter
@ToString
@Entity
@Table(name = "tb_withdraw")
public class TbWithdraw implements Serializable {
@Id
private String id;
@ApiModelProperty(value = "提现状态 1-已发起 2-已完成 3-提现失败")
private Integer state;
@ApiModelProperty(value = "提现金额")
private BigDecimal amount;
@ApiModelProperty(value = "用户id")
private String userId;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@CreatedDate
private Instant createTime;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@LastModifiedDate
private Instant updateTime;
private String createUser;
private String updateUser;
}

@ -1,7 +1,11 @@
package com.luoo.user.pojo;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.format.annotation.DateTimeFormat;
import javax.persistence.Entity;
import javax.persistence.Id;
@ -42,9 +46,15 @@ public class UserProcess implements Serializable {
@ApiModelProperty("拒绝理由")
private String content;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty("创建时间")
@CreatedDate
private Date createTime;
@ApiModelProperty("修改时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@LastModifiedDate
private Date modifyTime;
}

@ -0,0 +1,40 @@
create table tb_bank
(
id varchar(20) not null comment 'id'
primary key,
name varchar(255) null comment '银行名称',
logo varchar(255) null comment '银行logo'
)
comment '常见银行及其logo显示';
create table tb_user_bank
(
id varchar(20) not null comment 'id'
primary key,
bank_card varchar(50) null comment '银行卡号',
bank_id varchar(20) null comment '银行表id',
bank_name varchar(255) null comment '银行名称',
phone varchar(50) null comment '手机号',
user_id varchar(20) not null comment '用户id',
state int null comment '状态 1-绑定 2-解绑',
create_time datetime null comment '创建时间',
update_time datetime null comment '修改时间',
create_user varchar(20) null comment '创建人',
update_user varchar(20) null comment '修改人'
)
comment '用户绑定银行卡';
create table tb_withdraw
(
id varchar(20) not null
primary key,
state int null comment '提现状态 1-已发起 2-已完成 3-提现失败',
amount decimal(10, 2) null comment '提现金额',
user_id varchar(20) null comment '用户id',
create_time datetime null comment '创建时间',
update_time datetime null comment '修改时间',
create_user varchar(20) null comment '创建人',
update_user varchar(20) null comment '修改人'
)
comment '提现记录表';
Loading…
Cancel
Save