sys_user.go 594 B

1234567891011121314151617
  1. package model
  2. import (
  3. "github.com/jinzhu/gorm"
  4. uuid "github.com/satori/go.uuid"
  5. )
  6. type SysUser struct {
  7. gorm.Model
  8. UUID uuid.UUID `json:"uuid"`
  9. Username string `json:"userName"`
  10. Password string `json:"-"`
  11. NickName string `json:"nickName" gorm:"default:'QMPlusUser'"`
  12. HeaderImg string `json:"headerImg" gorm:"default:'http://www.henrongyi.top/avatar/lufu.jpg'"`
  13. Authority SysAuthority `json:"authority" gorm:"ForeignKey:AuthorityId;AssociationForeignKey:AuthorityId"`
  14. AuthorityId string `json:"authorityId" gorm:"default:888"`
  15. }