修改了各个实体类的信息,修改了配置文件

This commit is contained in:
XinYi Song 2021-12-24 08:32:09 +08:00
parent d07c2dc84d
commit c4c2b3cc41
12 changed files with 32 additions and 30 deletions

View File

@ -14,8 +14,8 @@ public class BankCardEntity {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "bank_card_seq_gen")
@SequenceGenerator(name = "bank_card_seq_gen", sequenceName = "bank_card_id_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "bank_card_seq_gen", sequenceName = "bank_card_id_seq",allocationSize = 1)
private Integer id;
/**

View File

@ -14,8 +14,8 @@ public class BusinessEntity {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "business_seq_gen")
@SequenceGenerator(name = "business_seq_gen", sequenceName = "business_id_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "business_seq_gen", sequenceName = "business_id_seq",allocationSize = 1)
private Integer id;
/**

View File

@ -16,8 +16,8 @@ public class FileDocumentEntity implements Serializable {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "file_document_seq_gen")
@SequenceGenerator(name = "file_document_seq_gen", sequenceName = "file_document_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "file_document_seq_gen", sequenceName = "file_document_seq",allocationSize = 1)
private Integer id;
@Column(length = 64, nullable = false, columnDefinition = "varchar(64)")

View File

@ -13,8 +13,8 @@ public class ProductContentPhotoEntity {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "product_content_photo_seq_gen")
@SequenceGenerator(name = "product_content_photo_seq_gen", sequenceName = "product_content_photo_id_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "product_content_photo_seq_gen", sequenceName = "product_content_photo_id_seq",allocationSize = 1)
private Integer id;
/**

View File

@ -13,8 +13,8 @@ public class ProductCoverEntity {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "product_cover_seq_gen")
@SequenceGenerator(name = "product_cover_seq_gen", sequenceName = "product_cover_id_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "product_cover_seq_gen", sequenceName = "product_cover_id_seq",allocationSize = 1)
private Integer id;
/**

View File

@ -14,8 +14,8 @@ public class ProductEntity {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "product_seq_gen")
@SequenceGenerator(name = "product_seq_gen", sequenceName = "product_id_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "product_seq_gen", sequenceName = "product_id_seq",allocationSize = 1)
private Integer id;
/**

View File

@ -15,8 +15,8 @@ public class RelRoleAuthorityEntity implements Serializable {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "rel_role_authority_seq_gen")
@SequenceGenerator(name = "rel_role_authority_seq_gen", sequenceName = "rel_role_authority_id_seq")
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "rel_role_authority_seq_gen", sequenceName = "rel_role_authority_id_seq")
private Integer id;
@Column(nullable = false)

View File

@ -15,8 +15,8 @@ public class RelUserRoleEntity implements Serializable {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "rel_user_role_seq_gen")
@SequenceGenerator(name = "rel_user_role_seq_gen", sequenceName = "rel_user_role_id_seq")
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "rel_user_role_seq_gen", sequenceName = "rel_user_role_id_seq")
private Integer id;
@Column(nullable = false)

View File

@ -15,8 +15,8 @@ public class SysAuthorityEntity implements Serializable {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "sys_authority_seq_gen")
@SequenceGenerator(name = "sys_authority_seq_gen", sequenceName = "sys_authority_id_seq")
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "sys_authority_seq_gen", sequenceName = "sys_authority_id_seq")
private Integer id;
@Column(length = 64, nullable = false, unique = true,columnDefinition = "varchar(64)")

View File

@ -15,8 +15,8 @@ public class SysRoleEntity implements Serializable {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "sys_role_seq_gen")
@SequenceGenerator(name = "sys_role_seq_gen", sequenceName = "sys_role_id_seq")
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "sys_role_seq_gen", sequenceName = "sys_role_id_seq")
private Integer id;
@Column(length = 32, nullable = false, unique = true,columnDefinition = "varchar(32)")

View File

@ -18,8 +18,8 @@ public class SysUserEntity implements Serializable {
* 指定主键建立自增序列主键值取自序列
*/
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "sys_user_seq_gen")
@SequenceGenerator(name = "sys_user_seq_gen", sequenceName = "sys_user_id_seq",allocationSize = 1)
@GeneratedValue(strategy = GenerationType.IDENTITY)
//@SequenceGenerator(name = "sys_user_seq_gen", sequenceName = "sys_user_id_seq",allocationSize = 1)
private Integer id;
/**

View File

@ -1,4 +1,4 @@
server.port = 6809
server.port = 6801
## 数据源配置
spring.datasource.url = jdbc:mysql://rm-bp160630z03x880745o.mysql.rds.aliyuncs.com:3306/leyibo_business?useSSL=false&useUnicode=true&characterEncoding=utf-8&autoReconnect=true&serverTimezone=Asia/Shanghai
@ -27,15 +27,17 @@ spring.datasource.hikari.minimum-idle = 5
spring.datasource.hikari.validation-timeout = 3000
## Spring Data JPA 配置
spring.jpa.database = mysql
spring.jpa.database-platform = org.hibernate.dialect.MySQL5Dialect
spring.jpa.show-sql = true
# 指定 ddl mode (none, validate, create, create-drop, update)
spring.jpa.hibernate.ddl-auto = update
#spring.jpa.database = mysql
#spring.jpa.database-platform = org.hibernate.dialect.MySQL5Dialect
#spring.jpa.show-sql = true
## 指定 ddl mode (none, validate, create, create-drop, update)
#spring.jpa.hibernate.ddl-auto = update
spring.jpa.hibernate.hbm2ddl.auto=update
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
spring.jpa.show-sql= true
spring.jpa.properties.hibernate.enable_lazy_load_no_trans=true
# 命名策略
spring.jpa.hibernate.naming-strategy = org.hibernate.cfg.ImprovedNamingStrategy
#spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.PostgreSQL95Dialect
#spring.jpa.properties.hibernate.dialect = org.hibernate.spatial.dialect.postgis.PostgisDialect
spring.jpa.properties.hibernate.temp.use_jdbc_metadata_defaults = false
spring.jpa.properties.hibernate.jdbc.batch_size=500