Documentation ¶
Overview ¶
消息服务
订单服务
商品服务
店铺服务
商户服务
Index ¶
- func APIInterface(config *Config, strAction string, params map[string]interface{}) (interface{}, error)
- type APIClient
- type APIError
- type ApiBody
- type Category
- func (category *Category) CreateCategory(shopId_ int64, name_ string, description_ string) (interface{}, error)
- func (category *Category) GetCategory(categoryId_ int64) (interface{}, error)
- func (category *Category) GetShopCategories(shopId_ int64) (interface{}, error)
- func (category *Category) RemoveCategory(categoryId_ int64) (interface{}, error)
- func (category *Category) SetCategoryPositions(shopId_ int64, categoryIds_ interface{}) (interface{}, error)
- func (category *Category) UpdateCategory(categoryId_ int64, name_ string, description_ string) (interface{}, error)
- type Config
- type ElemeSdkLogger
- type File
- type Item
- func (item *Item) BatchClearStock(specIds_ interface{}) (interface{}, error)
- func (item *Item) BatchCreateItems(categoryId_ int64, items_ interface{}) (interface{}, error)
- func (item *Item) BatchFillStock(specIds_ interface{}) (interface{}, error)
- func (item *Item) BatchGetItems(itemIds_ interface{}) (interface{}, error)
- func (item *Item) BatchOffShelf(specIds_ interface{}) (interface{}, error)
- func (item *Item) BatchOnShelf(specIds_ interface{}) (interface{}, error)
- func (item *Item) BatchRemoveItems(itemIds_ interface{}) (interface{}, error)
- func (item *Item) BatchUpdateSpecStocks(specStocks_ interface{}) (interface{}, error)
- func (item *Item) ClearAndTimingMaxStock(clearStocks_ interface{}) (interface{}, error)
- func (item *Item) CreateItem(categoryId_ int64, properties_ interface{}) (interface{}, error)
- func (item *Item) GetItem(itemId_ int64) (interface{}, error)
- func (item *Item) GetItemsByCategoryId(categoryId_ int64) (interface{}, error)
- func (item *Item) RemoveItem(itemId_ int64) (interface{}, error)
- func (item *Item) SetItemPositions(categoryId_ int64, itemIds_ interface{}) (interface{}, error)
- func (item *Item) UpdateItem(itemId_ int64, categoryId_ int64, properties_ interface{}) (interface{}, error)
- type Message
- type OAuthClient
- func (oauth *OAuthClient) GenerateAuthUrl(state string, scope string, redirectUri string) string
- func (oauth *OAuthClient) GetClientToken() Token
- func (oauth *OAuthClient) GetTokenByAuthCode(code string, redirectURL string) Token
- func (oauth *OAuthClient) GetTokenByRefreshToken(refreshToken string, scope string) Token
- func (oauth *OAuthClient) SetConfig(conf Config)
- type Order
- func (order *Order) AgreeRefund(orderId_ string) (interface{}, error)
- func (order *Order) BatchGetDeliveryStates(orderIds_ interface{}) (interface{}, error)
- func (order *Order) CancelOrder(orderId_ string, type_ interface{}, remark_ string) (interface{}, error)
- func (order *Order) ConfirmOrder(orderId_ string) (interface{}, error)
- func (order *Order) DeliveryBySelf(orderId_ string) (interface{}, error)
- func (order *Order) DisagreeRefund(orderId_ string, reason_ string) (interface{}, error)
- func (order *Order) GetDeliveryStateRecord(orderId_ string) (interface{}, error)
- func (order *Order) GetOrder(orderId_ string) (interface{}, error)
- func (order *Order) MgetOrders(orderIds_ interface{}) (interface{}, error)
- func (order *Order) NoMoreDelivery(orderId_ string) (interface{}, error)
- func (order *Order) ReceivedOrder(orderId_ string) (interface{}, error)
- type Product
- type Shop
- func (shop *Shop) GetShop(shopId_ int64) (interface{}, error)
- func (shop *Shop) MgetShopStatus(shopIds_ interface{}) (interface{}, error)
- func (shop *Shop) SetDeliveryTime(shopId_ int64, deliveryBasicMins_ int, deliveryAdjustMins_ int) (interface{}, error)
- func (shop *Shop) UpdateShop(shopId_ int64, properties_ interface{}) (interface{}, error)
- type SimpleLogger
- type Token
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIClient ¶
type APIError ¶
type ApiBody ¶
type Category ¶
type Category struct {
// contains filtered or unexported fields
}
func (*Category) CreateCategory ¶
func (category *Category) CreateCategory(shopId_ int64, name_ string, description_ string) (interface{}, error)
添加商品分类 shopId 店铺Id name 商品分类名称,长度需在50字以内 description 商品分类描述,长度需在50字以内
func (*Category) GetCategory ¶
查询商品分类详情 categoryId 商品分类Id
func (*Category) GetShopCategories ¶
查询店铺商品分类 shopId 店铺Id
func (*Category) RemoveCategory ¶
删除商品分类 categoryId 商品分类Id
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
type File ¶
type File struct {
// contains filtered or unexported fields
}
func (*File) GetUploadedUrl ¶
获取上传文件的访问URL,返回文件的Url地址 hash 图片hash值
func (*File) UploadImage ¶
上传图片,返回图片的hash值 image 文件内容base64编码值
type Item ¶
type Item struct {
// contains filtered or unexported fields
}
func (*Item) BatchClearStock ¶
批量沽清库存 specIds 商品及商品规格的列表
func (*Item) BatchCreateItems ¶
批量添加商品 categoryId 商品分类Id items 商品属性的列表
func (*Item) BatchFillStock ¶
批量置满库存 specIds 商品及商品规格的列表
func (*Item) BatchGetItems ¶
批量查询商品详情 itemIds 商品Id的列表
func (*Item) BatchOffShelf ¶
批量下架商品 specIds 商品及商品规格的列表
func (*Item) BatchOnShelf ¶
批量上架商品 specIds 商品及商品规格的列表
func (*Item) BatchRemoveItems ¶
批量删除商品 itemIds 商品Id的列表
func (*Item) BatchUpdateSpecStocks ¶
批量更新商品库存 specStocks 商品以及规格库存列表
func (*Item) ClearAndTimingMaxStock ¶ added in v1.2.0
批量沽清库存并在次日2:00开始置满 clearStocks 店铺Id及商品Id的列表
func (*Item) CreateItem ¶
添加商品 categoryId 商品分类Id properties 商品属性
func (*Item) GetItem ¶
查询商品详情 itemId 商品Id
func (*Item) GetItemsByCategoryId ¶
获取一个分类下的所有商品 categoryId 商品分类Id
func (*Item) RemoveItem ¶
删除商品 itemId 商品Id
func (*Item) SetItemPositions ¶
设置商品排序 categoryId 商品分类Id itemIds 商品Id列表
type Message ¶
type Message struct {
// contains filtered or unexported fields
}
func (*Message) GetNonReachedMessages ¶
获取未到达的推送消息 appId 应用ID
type OAuthClient ¶
type OAuthClient struct {
// contains filtered or unexported fields
}
func NewAuthClient ¶
func NewAuthClient(conf Config) OAuthClient
func (*OAuthClient) GenerateAuthUrl ¶
func (oauth *OAuthClient) GenerateAuthUrl(state string, scope string, redirectUri string) string
获取授权 URL
func (*OAuthClient) GetClientToken ¶
func (oauth *OAuthClient) GetClientToken() Token
获取 token 客户端模式
func (*OAuthClient) GetTokenByAuthCode ¶
func (oauth *OAuthClient) GetTokenByAuthCode(code string, redirectURL string) Token
通过 auth code 获取 token
func (*OAuthClient) GetTokenByRefreshToken ¶
func (oauth *OAuthClient) GetTokenByRefreshToken(refreshToken string, scope string) Token
通过刷新 token 获取 token
type Order ¶
type Order struct {
// contains filtered or unexported fields
}
func (*Order) AgreeRefund ¶
同意退单/取消单 orderId 订单Id
func (*Order) BatchGetDeliveryStates ¶
批量获取订单最新配送记录 orderIds 订单Id列表
func (*Order) CancelOrder ¶
func (order *Order) CancelOrder(orderId_ string, type_ interface{}, remark_ string) (interface{}, error)
取消订单 orderId 订单Id type 取消原因 remark 备注说明
func (*Order) ConfirmOrder ¶
确认订单 orderId 订单Id
func (*Order) DeliveryBySelf ¶
配送异常或者物流拒单后选择自行配送 orderId 订单Id
func (*Order) DisagreeRefund ¶
不同意退单/取消单 orderId 订单Id reason 商家不同意退单原因
func (*Order) GetDeliveryStateRecord ¶
获取订单配送记录 orderId 订单Id
func (*Order) GetOrder ¶
获取订单 orderId 订单Id
func (*Order) MgetOrders ¶
批量获取订单 orderIds 订单Id的列表
func (*Order) NoMoreDelivery ¶
配送异常或者物流拒单后选择不再配送 orderId 订单Id
type Product ¶
type Shop ¶
type Shop struct {
// contains filtered or unexported fields
}
func (*Shop) GetShop ¶
查询店铺信息 shopId 店铺Id
func (*Shop) MgetShopStatus ¶
批量获取店铺简要 shopIds 店铺Id的列表
type SimpleLogger ¶
type SimpleLogger struct { }
func (*SimpleLogger) Error ¶
func (logger *SimpleLogger) Error(message string)
func (*SimpleLogger) Info ¶
func (logger *SimpleLogger) Info(message string)