This commit is contained in:
richboo111
2022-11-18 16:53:49 +08:00
parent 11b63862d1
commit a038f850c9
2 changed files with 25 additions and 14 deletions

View File

@@ -1511,14 +1511,16 @@ func (c *StoreController) GetDDScope() {
// @Title 创建抖店电子围栏
// @Description 创建抖店电子围栏
// @Param token header string true "认证token"
// @Param storeID formData int true "门店ID"
// @Param vendorOrgCode formData string false "厂商内组织代码"
// @Param payload formData string true "json数据[]string对象"
// @Success 200 {object} controllers.CallResult
// @Failure 200 {object} controllers.CallResult
// @router /CreateDDStoreFence [post]
func (c *StoreController) CreateDDStoreFence() {
c.callCreateDDStoreFence(func(params *tStoreCreateDDStoreFenceParams) (interface{}, string, error) {
err := cms.AssistCreateFence(params.VendorOrgCode, int64(params.StoreID))
return nil, "", err
c.callCreateDDStoreFence(func(params *tStoreCreateDDStoreFenceParams) (retVal interface{}, errCode string, err error) {
payload := make(map[string][]int64)
if err = utils.UnmarshalUseNumber([]byte(params.Payload), &payload); err == nil {
retVal, err = cms.AssistCreateFence(payload)
}
return retVal, "", err
})
}