Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
yangxiujun
/
paidan_demo
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 259d35fe
authored
Jul 08, 2023
by
丁伟峰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
重新生成entity的完整定义,以便启用数据表的默认值
1 parent
6e0348eb
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
44 additions
and
52 deletions
project-order/src/main/java/com/dituhui/pea/order/entity/OrgTeamEntity.java
project-order/src/main/java/com/dituhui/pea/order/entity/OrgTeamEntity.java
View file @
259d35f
...
...
@@ -5,88 +5,80 @@ import lombok.experimental.Accessors;
import
javax.persistence.*
;
import
java.time.LocalDateTime
;
import
java.util.Date
;
@Entity
@Table
(
name
=
"org_team"
)
@Data
@Accessors
(
chain
=
true
)
@Table
(
name
=
"org_team"
)
public
class
OrgTeamEntity
{
/**
* id
*/
@Id
@GeneratedValue
(
strategy
=
GenerationType
.
IDENTITY
)
private
Integer
id
;
/**
* 工作队id
*/
@Column
(
name
=
"team_id"
,
nullable
=
false
,
unique
=
true
)
private
String
teamId
;
/**
* 工作队名称
*/
@Column
(
name
=
"team_name"
,
nullable
=
false
)
private
String
teamName
;
/**
* 类别:1 映射工作队 2自定义工作队
*/
private
Integer
teamType
;
@Column
(
name
=
"team_type"
,
columnDefinition
=
"int default 1"
)
private
Integer
teamType
=
1
;
/**
* 归属大区
*/
@Column
(
name
=
"cluster_id"
,
nullable
=
false
)
private
String
clusterId
;
/**
* 归属分部
*/
@Column
(
name
=
"branch_id"
,
nullable
=
false
)
private
String
branchId
;
/**
* 归属小组
*/
@Column
(
name
=
"group_id"
,
nullable
=
false
)
private
String
groupId
;
/**
* 取件配件仓
*/
@Column
(
name
=
"warehouse_id"
,
nullable
=
false
)
private
String
warehouseId
;
/**
* 工作日,1表示星期一,2表示星期二
*/
private
String
workdays
;
@Column
(
name
=
"workdays"
,
nullable
=
false
,
columnDefinition
=
"varchar(30) default '1,2,3,4,5,6,7'"
)
private
String
workdays
=
"1,2,3,4,5,6,7"
;
/**
* 备注
*/
@Column
(
nullable
=
false
)
private
String
memo
;
/**
* 创建时间
*/
@Column
(
name
=
"create_time"
,
nullable
=
false
,
updatable
=
false
,
columnDefinition
=
"timestamp default current_timestamp"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@Column
(
name
=
"update_time"
,
nullable
=
false
,
columnDefinition
=
"timestamp default current_timestamp on update current_timestamp"
)
private
LocalDateTime
updateTime
;
private
String
workOn
;
private
String
workOff
;
private
Integer
workDuration
;
private
String
transportMode
;
private
String
strategySchedule
;
private
String
strategyAppointment
;
private
Integer
intervalSchedule
;
private
Integer
intervalScheduleNext
;
private
String
cuteOff
;
private
Integer
status
;
@Column
(
name
=
"work_on"
,
nullable
=
false
,
columnDefinition
=
"varchar(5) default '08:00'"
)
private
String
workOn
=
"08:00"
;
@Column
(
name
=
"work_off"
,
nullable
=
false
,
columnDefinition
=
"varchar(5) default '18:00'"
)
private
String
workOff
=
"18:00"
;
@Column
(
name
=
"work_duration"
,
nullable
=
false
,
columnDefinition
=
"int default 600"
)
private
Integer
workDuration
=
600
;
@Column
(
name
=
"transport_mode"
,
columnDefinition
=
"varchar(10) default '电动车'"
)
private
String
transportMode
=
"电动车"
;
@Column
(
name
=
"strategy_schedule"
,
columnDefinition
=
"varchar(10) default '营销优先'"
)
private
String
strategySchedule
=
"营销优先"
;
@Column
(
name
=
"strategy_appointment"
,
columnDefinition
=
"varchar(10) default '指派给信息员'"
)
private
String
strategyAppointment
=
"指派给信息员"
;
@Column
(
name
=
"interval_schedule"
,
nullable
=
false
,
columnDefinition
=
"int default 100"
)
private
Integer
intervalSchedule
=
100
;
@Column
(
name
=
"interval_schedule_next"
,
nullable
=
false
,
columnDefinition
=
"int default 200"
)
private
Integer
intervalScheduleNext
=
200
;
@Column
(
name
=
"cute_off"
,
nullable
=
false
,
columnDefinition
=
"varchar(5) default '18:00'"
)
private
String
cuteOff
=
"18:00"
;
public
OrgTeamEntity
()
{
@Column
(
nullable
=
false
,
columnDefinition
=
"int default 1"
)
private
Integer
status
=
1
;
}
// 其他字段和关联关系的定义
// ...
}
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