京东商城建商品开测

This commit is contained in:
苏尹岚
2020-05-13 09:43:27 +08:00
parent 7b05c7b87a
commit 5f901f8531
11 changed files with 243 additions and 34 deletions

View File

@@ -1,9 +1,12 @@
package jdshop
import (
"git.rosy.net.cn/baseapi/platformapi/jdshopapi"
"git.rosy.net.cn/jx-callback/business/jxutils/jxcontext"
"git.rosy.net.cn/jx-callback/business/jxutils/tasksch"
"git.rosy.net.cn/jx-callback/business/model"
"git.rosy.net.cn/jx-callback/business/model/dao"
"git.rosy.net.cn/jx-callback/globals/api"
)
func (p *PurchaseHandler) ReadStore(ctx *jxcontext.Context, vendorOrgCode, vendorStoreID string) (storeDetail *dao.StoreDetail, err error) {
@@ -15,6 +18,22 @@ func (p *PurchaseHandler) UpdateStore(db *dao.DaoDB, storeID int, userName strin
return err
}
func (p *PurchaseHandler) CreateStore2(db *dao.DaoDB, storeID int, userName string) (err error) {
store, err := dao.GetStoreDetail(db, storeID, model.VendorIDJDShop)
if err != nil {
return err
}
createEntityStoreParam := &jdshopapi.CreateEntityStoreParam{
Name: store.Name,
}
err = api.JdShopAPI.CreateEntityStore(createEntityStoreParam)
return err
}
func (p *PurchaseHandler) DeleteStore(db *dao.DaoDB, storeID int, userName string) (err error) {
return err
}
func (p *PurchaseHandler) RefreshAllStoresID(ctx *jxcontext.Context, parentTask tasksch.ITask, isAsync bool) (hint string, err error) {
return hint, err
}