Files
platforms/backend/api/internal/models/delivery_account.go

17 lines
848 B
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package models
import "git.apinb.com/bsm-sdk/core/database"
// DeliveryAccount 对应 delivery_account保存配送点登录账户。
type DeliveryAccount struct {
Entity
DeliveryBasicID uint64 `gorm:"column:delivery_basic_id;not null;index" json:"delivery_basic_id"`
Username string `gorm:"column:username;type:varchar(64);not null;uniqueIndex" json:"username"`
DisplayName string `gorm:"column:display_name;type:varchar(64);not null;default:''" json:"display_name"`
PasswordHash string `gorm:"column:password_hash;type:varchar(255);not null" json:"-"`
RoleCode string `gorm:"column:role_code;type:varchar(64);not null" json:"role_code"`
}
func init() { database.AppendMigrate(&DeliveryAccount{}) }
func (table *DeliveryAccount) TableName() string { return "delivery_account" }