You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
922 B
23 lines
922 B
6 months ago
|
package model
|
||
|
|
||
|
import "shop-api/global"
|
||
|
|
||
|
type Address struct {
|
||
|
global.MG_MODEL
|
||
|
UserID string `gorm:"size:255" json:"userId"`
|
||
|
FirstName string `gorm:"size:255" json:"firstName"` // first name
|
||
|
LastName string `gorm:"size:255" json:"lastName"` // last name
|
||
|
Street string `gorm:"size:255" json:"street"` // street
|
||
|
Phone string `gorm:"size:20" json:"phone"` // 手机号
|
||
|
Bldg string `gorm:"size:255" json:"bldg"` // apt,ste,bldg
|
||
|
City string `gorm:"size:255" json:"city"` // city
|
||
|
State string `gorm:"size:255" json:"state"` // state
|
||
|
ZipCode string `gorm:"size:255" json:"zipCode"` // zip code
|
||
|
Default int `gorm:"tinyint(1)" json:"default"` // 是否默认地址 1-是 2-否
|
||
|
Platform string `gorm:"size:50" json:"platform"` // 平台 saller(买家端) / customer(客户端) / influencer(网红端)
|
||
|
}
|
||
|
|
||
|
func (Address) TableName() string {
|
||
|
return "address"
|
||
|
}
|