Documentation ¶
Index ¶
- type BusinessAdmin
- type CertificatePhoto
- type Goods
- func (g *Goods) AddGoods() error
- func (g *Goods) DeleteGoodsByIds(ids []int64) error
- func (g *Goods) QueryGoodsByAdminID(pageSize int, page int) (goods []Goods)
- func (g *Goods) QueryGoodsByGoodsTypeID() (goods []Goods)
- func (g *Goods) QueryGoodsByID() error
- func (g *Goods) QueryGoodsCountByAdminID() (count int)
- func (g *Goods) QueryGoodsExistNameByAdminId() error
- func (g *Goods) UpdateGoodsByID(args map[string]interface{}) error
- type GoodsType
- func (g *GoodsType) AddGoodsType() error
- func (g *GoodsType) DeleteGoodsTypeByIds(ids []int64) error
- func (g *GoodsType) QueryGoodsTypeByAdminID(pageSize int, page int) (goodsTypes []GoodsType)
- func (g *GoodsType) QueryGoodsTypeByID() error
- func (g *GoodsType) QueryGoodsTypeCountByAdminID() (count int)
- func (g *GoodsType) QueryGoodsTypeExistNameByAdminID() error
- func (g *GoodsType) QueryGoodsTypeIDAndNameByAdminID() (res []entity.GoodsTypeResponse)
- func (g *GoodsType) UpdateGoodsTypeByID(args map[string]interface{}) error
- type InStorePhoto
- type IndustryQualification
- type Store
- type StoreOpeningPersonalInfo
- type StoreQualificationInfo
- type SubjectQualification
- type Table
- func (t *Table) AddTable() error
- func (t *Table) DeleteTable(ids []int64) error
- func (t *Table) QueryTableByID() error
- func (t *Table) QueryTableByTableTypeID() (tables []Table)
- func (t *Table) QueryTableCountByAdminID() (count int)
- func (t *Table) QueryTableExistName() error
- func (t *Table) QueryTablesByAdminID(pageSize int, page int) (Tables []Table)
- func (t *Table) UpdateTable(args map[string]interface{}) error
- type TableType
- func (t *TableType) AddTableType() error
- func (t *TableType) DeleteTableTypeByIDs(ids []int64) error
- func (t *TableType) QueryTableTypeByID() error
- func (t *TableType) QueryTableTypeCountByAdminID() (count int)
- func (t *TableType) QueryTableTypeExistName() error
- func (t *TableType) QueryTableTypeIDAndNameByAdminID() (res []entity.TableTypeResponse)
- func (t *TableType) QueryTableTypesByAdminID(pageSize int, page int) (TableTypes []TableType)
- func (t *TableType) UpdateTableType(args map[string]interface{}) error
- type WeChat
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BusinessAdmin ¶
type BusinessAdmin struct { model.Model Tel string `gorm:"not null;unique;" json:"tel"` // 手机号 Password string `json:"-"` // 密码 IP string `json:"ip"` // 登录IP Token string `json:"token"` // 授权令牌 Avatar string `json:"avatar"` // 头像 UUID uuid.UUID `json:"uuid"` // uuid Wechat WeChat `json:"wechat"` // 微信信息 WechatID int64 `json:"-"` // 微信信息ID }
BusinessAdmin model 商家管理员
func (*BusinessAdmin) QueryUserByID ¶
func (a *BusinessAdmin) QueryUserByID() error
查询商家 by ID
param id return BusinessAdmin,error
func (*BusinessAdmin) QueryUserByTel ¶
func (a *BusinessAdmin) QueryUserByTel() error
查询商家 by tel
param tel return BusinessAdmin,error
func (*BusinessAdmin) QueryUserByToken ¶
func (a *BusinessAdmin) QueryUserByToken() error
查询商家 by token
param token return BusinessAdmin,error
func (*BusinessAdmin) RegisterBusinessAdmin ¶
func (a *BusinessAdmin) RegisterBusinessAdmin() error
注册商家
func (*BusinessAdmin) UpdateBusinessAdmin ¶
func (a *BusinessAdmin) UpdateBusinessAdmin(args map[string]interface{}) error
更新商家 by id
param tel param password param ip param token param manager param avatar param uuid param stores return BusinessAdmin,error
type CertificatePhoto ¶
type CertificatePhoto struct { ID int64 Url string `json:"Url"` // 图片保存地址 StoreOpeningPersonalInfoID int64 `gorm:"INDEX" json:"store_opening_personal_info_id"` // 开店个人信息ID }
CertificatePhoto model 身份证照
type Goods ¶
type Goods struct { model.Model GoodsName string `json:"goods_name"` // 商品名称 GoodsPhoto string `json:"goods_photo"` // 商品图片 GoodsDescription string `json:"goods_description"` // 商品描述 GoodsListing bool `json:"goods_listing"` // 是否上架 GoodsPrice float64 `json:"goods_price"` // 商品价格 GoodsUnit string `json:"goods_unit"` // 商品单位 份、杯 GoodsSort int64 `json:"goods_sort"` // 商品排序 GoodsTypeID int64 `json:"goods_type_id"` // 商品种类ID GoodsTypeName string `json:"goods_type_name"` // 商品种类名称 AdminID int64 `gorm:"INDEX" json:"admin_id"` // 商家管理员ID }
Goods model 商品
func (*Goods) QueryGoodsByAdminID ¶
批量查询商品
func (*Goods) QueryGoodsByGoodsTypeID ¶
查询商品by goods_type_id
func (*Goods) QueryGoodsCountByAdminID ¶
商品总记录数
func (*Goods) UpdateGoodsByID ¶
修改商品by id
type GoodsType ¶
type GoodsType struct { model.Model Name string `json:"name"` // 种类名称 TypeSort int64 `json:"type_sort"` // 种类排序 DisplayOrNot bool `json:"display_or_not"` // 是否显示 AdminID int64 `gorm:"INDEX" json:"admin_id"` // 商家管理员ID }
GoodsType model 商品种类
func (*GoodsType) QueryGoodsTypeByAdminID ¶
批量查询商品种类
func (*GoodsType) QueryGoodsTypeCountByAdminID ¶
商品种类总记录数
func (*GoodsType) QueryGoodsTypeExistNameByAdminID ¶
检查商家是否已创建相同的商品种类名称
func (*GoodsType) QueryGoodsTypeIDAndNameByAdminID ¶
func (g *GoodsType) QueryGoodsTypeIDAndNameByAdminID() (res []entity.GoodsTypeResponse)
查询商品种类ID和名称
func (*GoodsType) UpdateGoodsTypeByID ¶
修改商品种类
type InStorePhoto ¶
type InStorePhoto struct { ID int64 Url string `json:"Url"` // 图片保存地址 StoreID int64 `gorm:"INDEX" json:"store_id"` // 门店ID }
店内照
type IndustryQualification ¶
type IndustryQualification struct { ID int64 CertificateType string `json:"certificate_type"` // 证书类型 CertificatePhoto string `json:"certificate_photo"` // 证书照片 }
IndustryQualification model 行业资质
type Store ¶
type Store struct { model.Model StoreName string `gorm:"not null" json:"store_name"` // 门店名称 StoreAddress string `gorm:"not null" json:"store_address"` // 门店详细地址 StoreLogo string `json:"store_logo"` // 门店logo StoreContactName string `json:"store_contact_name"` // 门店联系人姓名 StoreContactTel string `json:"store_contact_tel"` // 门店联系人电话 StoreStartBankingHours string `gorm:"not null" json:"store_start_banking_hours"` // 门店开始营业时间 StoreEndBankingHours string `gorm:"not null" json:"store_end_banking_hours"` // 门店结束营业时间 StoreFacePhoto string `json:"store_face_photo"` // 门脸照 InStorePhotos []InStorePhoto `gorm:"foreignkey:StoreID;association_foreignkey:ID" json:"in_store_photos"` // 店内照 AdminID int64 `gorm:"INDEX" json:"admin_id"` // 商家管理员ID }
Store model 门店信息
type StoreOpeningPersonalInfo ¶
type StoreOpeningPersonalInfo struct { ID int64 CertificateType string `json:"certificate_type"` // 证书类型 CertificatePhotos []CertificatePhoto `gorm:"foreignkey:StoreOpeningPersonalInfoID;association_foreignkey:ID"` // 身份证照 }
StoreOpeningPersonalInfo model 开店个人信息
type StoreQualificationInfo ¶
type StoreQualificationInfo struct { model.Model StoreCertificationStatus int64 `json:"store_certification_status"` // 店铺认证状态 0:已认证 | 1:未认证 StoreOperationIndustry string `json:"shop_operation_industry"` // 店铺经营行业 SubjectQualification SubjectQualification `json:"subject_qualification"` // 主体资质 SubjectQualificationID int64 `json:"-"` // 主体资质ID IndustryQualification IndustryQualification `json:"industry_qualification"` // 行业资质 IndustryQualificationID int64 `json:"-"` // 行业资质ID AdminID int64 `gorm:"INDEX" json:"admin_id"` // 商家管理员ID }
StoreQualificationInfo model 资质信息
func (*StoreQualificationInfo) AddStoreCertification ¶
func (s *StoreQualificationInfo) AddStoreCertification() error
提交认证
func (*StoreQualificationInfo) UpdateStoreCertification ¶
func (s *StoreQualificationInfo) UpdateStoreCertification(args map[string]interface{}) error
修改认证信息
type SubjectQualification ¶
type SubjectQualification struct { ID int64 CertificateType string `json:"certificate_type"` // 证书类型 CertificatePhoto string `json:"certificate_photo"` // 证书照片 }
SubjectQualification model 主体资质
type Table ¶
type Table struct { model.Model Name string `json:"name"` // 餐桌名称 Sort int64 `json:"sort"` // 餐桌排序 QRCode string `json:"QR_code"` // 餐桌二维码 Opening bool `json:"opening"` // 是否开台 DisplayOrNot bool `json:"display_or_not"` // 是否显示 TableTypeID int64 `json:"table_type_id"` // 餐桌种类ID TableTypeName string `json:"table_type_name"` // 餐桌种类名称 AdminID int64 `gorm:"INDEX" json:"admin_id"` // 商家管理员ID }
Table model 餐桌
func (*Table) QueryTableByTableTypeID ¶
查询餐桌 By TableTypeID
func (*Table) QueryTableCountByAdminID ¶
餐桌总记录数
func (*Table) QueryTablesByAdminID ¶
批量查询餐桌
type TableType ¶
type TableType struct { model.Model Name string `json:"name"` // 种类名称 SeatingMin int64 `json:"seating_min"` // 最少可坐人数 SeatingMax int64 `json:"seating_max"` // 最多可坐人数 DisplayOrNot bool `json:"display_or_not"` // 是否显示 AdminID int64 `gorm:"INDEX" json:"admin_id"` // 商家管理员ID }
TableType model 餐桌种类
func (*TableType) QueryTableTypeCountByAdminID ¶
餐桌种类总记录数
func (*TableType) QueryTableTypeExistName ¶
检查商家是否已创建相同的餐桌种类名称
func (*TableType) QueryTableTypeIDAndNameByAdminID ¶
func (t *TableType) QueryTableTypeIDAndNameByAdminID() (res []entity.TableTypeResponse)
查询餐桌种类ID和名称
func (*TableType) QueryTableTypesByAdminID ¶
批量查询餐桌种类
func (*TableType) UpdateTableType ¶
修改餐桌种类
Click to show internal directories.
Click to hide internal directories.