更细用户表去重索引
This commit is contained in:
parent
6b0ca5c019
commit
2aea6debbb
@ -3,10 +3,10 @@ package model
|
|||||||
// User 用户模型
|
// User 用户模型
|
||||||
type User struct {
|
type User struct {
|
||||||
Model
|
Model
|
||||||
MgmtAccId int64 `gorm:"column:mgmt_acc_id;not null;uniqueIndex:mgmt_acc_mgmt_artist_uid;comment:账号id"`
|
MgmtAccId int64 `gorm:"column:mgmt_acc_id;not null;uniqueIndex:mgmt_acc_mgmt_artist_tel_uid_tel_num;comment:账号id"`
|
||||||
MgmtArtistId int64 `gorm:"column:mgmt_artist_id;not null;comment:艺术家id"`
|
MgmtArtistId int64 `gorm:"column:mgmt_artist_id;not null;comment:艺术家id"`
|
||||||
MgmtArtistUid string `gorm:"column:mgmt_artist_uid;type:varchar(256);uniqueIndex:mgmt_acc_mgmt_artist_uid;comment:艺术家uid"`
|
MgmtArtistUid string `gorm:"column:mgmt_artist_uid;type:varchar(256);uniqueIndex:mgmt_acc_mgmt_artist_uid_tel_num;comment:艺术家uid"`
|
||||||
TelNum string `gorm:"column:tel_num;type:varchar(20);not null;电话号码"`
|
TelNum string `gorm:"column:tel_num;type:varchar(20);uniqueIndex:mgmt_acc_mgmt_artist_uid_tel_num;not null;电话号码"`
|
||||||
InviteCode string `gorm:"column:invited_code;type:varchar(16);default:'';comment:个人邀请码"`
|
InviteCode string `gorm:"column:invited_code;type:varchar(16);default:'';comment:个人邀请码"`
|
||||||
InvitedBy *Invite `gorm:"foreignKey:InvitedId"` //邀请者的相关信息
|
InvitedBy *Invite `gorm:"foreignKey:InvitedId"` //邀请者的相关信息
|
||||||
Account string `gorm:"column:account;varchar(191);comment:账号"`
|
Account string `gorm:"column:account;varchar(191);comment:账号"`
|
||||||
|
@ -2,12 +2,18 @@
|
|||||||
mode = dev #正式prod #测试dev
|
mode = dev #正式prod #测试dev
|
||||||
|
|
||||||
[mysql]
|
[mysql]
|
||||||
|
# Db = mysql
|
||||||
|
# DbHost = 127.0.0.1
|
||||||
|
# DbPort = 3306
|
||||||
|
# DbUser = root
|
||||||
|
# DbPassWord = 123456
|
||||||
|
# DbName = artistmgmttest
|
||||||
Db = mysql
|
Db = mysql
|
||||||
DbHost = 127.0.0.1
|
DbHost = 127.0.0.1
|
||||||
DbPort = 3306
|
DbPort = 13307
|
||||||
DbUser = root
|
DbUser = root
|
||||||
DbPassWord = 123456
|
DbPassWord = 123456
|
||||||
DbName = artistmgmttest
|
DbName = artistmgmtprod
|
||||||
|
|
||||||
[redis]
|
[redis]
|
||||||
RedisDB = 2
|
RedisDB = 2
|
||||||
|
Loading…
Reference in New Issue
Block a user