Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SearchItself ¶
func SearchItself()
Types ¶
type Order ¶
type Order struct { OrderNo string `json:"OrderNo" bson:"OrderNo"` Seller string `json:"seller" bson:"seller,omitempty"` Buyer string `json:"buyer" bson:"buyer"` Payment int32 `json:"payment" bson:"payment" ` PaymentType int `json:"payment_type" bson:"payment_type,omitempty" ` ShippingTo Address `json:"shipping_to" bson:"shipping_to,omitempty"` Item []Product `json:"item" bson:"item,omitempty"` CreateTime time.Time `json:"create_time" bson:"create_time"` IsClose bool `json:"is_close"` EndTime time.Time `json:"end_time"` SendTime time.Time `json:"send_time"` sync.RWMutex `bson:"-"` }
OrderNo 订单号 Seller 卖家 Buyer 卖家 Payment 价格 PaymentType 支付方式 ShippingTo 邮寄地址 IsClose 订单是否已关闭 CreateAt 订单创建时间
type Product ¶
type Product struct { ProductId uint16 `json:"product_id" bson:"_id"` //商品id Name string `json:"name" bson:"name,omitempty"` //商品名 ImageUri string `json:"image_uri" bson:"image_uri,omitempty"` //商品图片url Description string `json:"description" bson:"description,omitempty"` //商品介绍 Information Type `json:"info" bson:"info,omitempty"` //品牌 Price int `json:"price" bson:"price,omitempty"` //价格 Off int `json:"off" bson:"off,omitempty"` //折扣 Owner string `json:"owner" bson:"owner,omitempty"` //拥有者 CreateAt time.Time `json:"create_at" bson:"create_at,omitempty"` //创建时间 Shelves bool `json:"shelves" bson:"shelves,omitempty"` //是否上架 IsDelete bool `json:"is_delete" bson:"is_delete,omitempty"` //是否已删除 sync.RWMutex `json:"_" bson:"_"` }
type Shop ¶
type Shop struct { Name string `json:"name" bson:"name"` Owner string `json:"owner" bson:"owner,omitempty"` Description string `json:"description" bson:"description,omitempty"` IsClose bool `json:"is_close" bson:"is_close,omitempty"` CreateAt time.Time `json:"create_at" bson:"create_at,omitempty"` CloseAt time.Time `json:"close_at" bson:"close_at,omitempty"` sync.RWMutex `bson:"-"` IsDelete bool `json:"is_delete" bson:"is_delete,omitempty"` }
type UserInformation ¶
type UserInformation struct { Id uint16 `json:"id,omitempty" bson:"id,omitempty"` Username string `json:"username" validate:"min=1,max=32" bson:"username,omitempty"` Password string `json:"password,omitempty" validate:"min=1,max=32" bson:"password,omitempty"` Email string `json:"email,omitempty" bson:"email,omitempty"` Role int `json:"role,omitempty" bson:"role,omitempty"` Gander int `json:"gander,omitempty" bson:"gander,omitempty"` Addresses []Address `json:"addresses,omitempty" bson:"addresses,omitempty"` sync.RWMutex `bson:"-"` }
func (*UserInformation) GetUser ¶
func (u *UserInformation) GetUser() (*UserInformation, error)
获取用户信息
func (*UserInformation) Set ¶
func (u *UserInformation) Set(filed string, value interface{}) error
修改用户信息
Click to show internal directories.
Click to hide internal directories.