- 添加用户最后登录信息

This commit is contained in:
gazebo
2019-09-24 18:09:32 +08:00
parent 412b11396a
commit bf86235ce2
4 changed files with 35 additions and 7 deletions

View File

@@ -1,6 +1,10 @@
package model
import "git.rosy.net.cn/baseapi/utils"
import (
"time"
"git.rosy.net.cn/baseapi/utils"
)
const (
UserStatusNormal = 1
@@ -40,6 +44,10 @@ type User struct {
IDCardNo string `orm:"size(18);column(id_card_no)" json:"idCardNo" compact:"idCardNo"` // 身份证号
Remark string `orm:"size(255)" json:"remark"`
LastLoginAt *time.Time `orm:"null" json:"lastLoginAt"`
LastLoginIP string `orm:"size(64);column(last_login_ip)" json:"lastLoginIP"`
LastLoginType string `orm:"size(16)" json:"lastLoginType"`
}
func (*User) TableUnique() [][]string {