Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
OSmall
/
linjiashop
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 9f6c6e9e
authored
Dec 23, 2020
by
tyfanchz
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
调整数据表字段长度
1 parent
1f82e775
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
11 deletions
doc/database.sql
shop-core/src/main/java/com/glsx/shop/bean/entity/cms/Banner.java
shop-core/src/main/java/com/glsx/shop/bean/entity/shop/Goods.java
doc/database.sql
View file @
9f6c6e9
...
@@ -53,7 +53,7 @@ CREATE TABLE `t_cms_banner` (
...
@@ -53,7 +53,7 @@ CREATE TABLE `t_cms_banner` (
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间/注册时间'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间/注册时间'
,
`modify_by`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'最后更新人'
,
`modify_by`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'最后更新人'
,
`modify_time`
datetime
DEFAULT
NULL
COMMENT
'最后更新时间'
,
`modify_time`
datetime
DEFAULT
NULL
COMMENT
'最后更新时间'
,
`id_file`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'banner图id'
,
`id_file`
varchar
(
128
)
DEFAULT
NULL
COMMENT
'banner图id'
,
`page`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'界面'
,
`page`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'界面'
,
`param`
varchar
(
128
)
DEFAULT
NULL
COMMENT
'参数'
,
`param`
varchar
(
128
)
DEFAULT
NULL
COMMENT
'参数'
,
`title`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'标题'
,
`title`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'标题'
,
...
@@ -414,7 +414,7 @@ CREATE TABLE `t_shop_goods` (
...
@@ -414,7 +414,7 @@ CREATE TABLE `t_shop_goods` (
`modify_time`
datetime
DEFAULT
NULL
COMMENT
'最后更新时间'
,
`modify_time`
datetime
DEFAULT
NULL
COMMENT
'最后更新时间'
,
`descript`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'产品简介'
,
`descript`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'产品简介'
,
`detail`
text
COMMENT
'产品详情'
,
`detail`
text
COMMENT
'产品详情'
,
`gallery`
varchar
(
512
)
DEFAULT
NULL
COMMENT
'大图相册列表,以逗号分隔'
,
`gallery`
text
DEFAULT
NULL
COMMENT
'大图相册列表,以逗号分隔'
,
`id_category`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'类别id'
,
`id_category`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'类别id'
,
`is_delete`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'是否删除'
,
`is_delete`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'是否删除'
,
`is_hot`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'是否人气商品'
,
`is_hot`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'是否人气商品'
,
...
@@ -422,7 +422,7 @@ CREATE TABLE `t_shop_goods` (
...
@@ -422,7 +422,7 @@ CREATE TABLE `t_shop_goods` (
`is_on_sale`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'是否上架'
,
`is_on_sale`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'是否上架'
,
`like_num`
int
(
11
)
DEFAULT
NULL
COMMENT
'收藏数'
,
`like_num`
int
(
11
)
DEFAULT
NULL
COMMENT
'收藏数'
,
`name`
varchar
(
32
)
DEFAULT
NULL
COMMENT
'名称'
,
`name`
varchar
(
32
)
DEFAULT
NULL
COMMENT
'名称'
,
`pic`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'小图'
,
`pic`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'小图'
,
`price`
varchar
(
16
)
DEFAULT
NULL
COMMENT
'价格'
,
`price`
varchar
(
16
)
DEFAULT
NULL
COMMENT
'价格'
,
`stock`
int
(
11
)
DEFAULT
NULL
COMMENT
'库存数量'
,
`stock`
int
(
11
)
DEFAULT
NULL
COMMENT
'库存数量'
,
PRIMARY
KEY
(
`id`
)
PRIMARY
KEY
(
`id`
)
...
...
shop-core/src/main/java/com/glsx/shop/bean/entity/cms/Banner.java
View file @
9f6c6e9
package
com
.
glsx
.
shop
.
bean
.
entity
.
cms
;
package
com
.
glsx
.
shop
.
bean
.
entity
.
cms
;
import
com.glsx.shop.bean.entity.BaseEntity
;
import
lombok.Data
;
import
org.hibernate.annotations.Table
;
import
org.springframework.data.jpa.domain.support.AuditingEntityListener
;
import
javax.persistence.Column
;
import
javax.persistence.Column
;
import
javax.persistence.Entity
;
import
javax.persistence.Entity
;
import
javax.persistence.EntityListeners
;
import
javax.persistence.EntityListeners
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotBlank
;
import
com.glsx.shop.bean.entity.BaseEntity
;
import
lombok.Data
;
import
org.hibernate.annotations.Table
;
import
org.springframework.data.jpa.domain.support.AuditingEntityListener
;
@Entity
(
name
=
"t_cms_banner"
)
@Entity
(
name
=
"t_cms_banner"
)
@Table
(
appliesTo
=
"t_cms_banner"
,
comment
=
"文章"
)
@Table
(
appliesTo
=
"t_cms_banner"
,
comment
=
"文章"
)
...
@@ -23,7 +22,7 @@ public class Banner extends BaseEntity {
...
@@ -23,7 +22,7 @@ public class Banner extends BaseEntity {
@Column
(
columnDefinition
=
"VARCHAR(32) COMMENT '类型'"
)
@Column
(
columnDefinition
=
"VARCHAR(32) COMMENT '类型'"
)
@NotBlank
(
message
=
"类型不能为空"
)
@NotBlank
(
message
=
"类型不能为空"
)
private
String
type
;
private
String
type
;
@Column
(
columnDefinition
=
"VARCHAR(
64
) COMMENT 'banner图id'"
)
@Column
(
columnDefinition
=
"VARCHAR(
128
) COMMENT 'banner图id'"
)
private
String
idFile
;
private
String
idFile
;
@Column
(
columnDefinition
=
"VARCHAR(64) COMMENT '界面'"
)
@Column
(
columnDefinition
=
"VARCHAR(64) COMMENT '界面'"
)
private
String
page
;
private
String
page
;
...
...
shop-core/src/main/java/com/glsx/shop/bean/entity/shop/Goods.java
View file @
9f6c6e9
...
@@ -27,9 +27,9 @@ public class Goods extends BaseEntity {
...
@@ -27,9 +27,9 @@ public class Goods extends BaseEntity {
@NotBlank
(
message
=
"商品名称不能为空"
)
@NotBlank
(
message
=
"商品名称不能为空"
)
@Column
(
columnDefinition
=
"VARCHAR(32) COMMENT '名称'"
)
@Column
(
columnDefinition
=
"VARCHAR(32) COMMENT '名称'"
)
private
String
name
;
private
String
name
;
@Column
(
columnDefinition
=
"VARCHAR(
64
) COMMENT '小图'"
)
@Column
(
columnDefinition
=
"VARCHAR(
128
) COMMENT '小图'"
)
private
String
pic
;
private
String
pic
;
@Column
(
columnDefinition
=
"
VARCHAR(512)
COMMENT '大图相册列表,以逗号分隔'"
)
@Column
(
columnDefinition
=
"
TEXT
COMMENT '大图相册列表,以逗号分隔'"
)
private
String
gallery
;
private
String
gallery
;
@Column
(
name
=
"id_category"
,
columnDefinition
=
"BIGINT COMMENT '类别id'"
)
@Column
(
name
=
"id_category"
,
columnDefinition
=
"BIGINT COMMENT '类别id'"
)
private
Long
idCategory
;
private
Long
idCategory
;
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment