diff --git a/business/jxstore/tempop/tempop.go b/business/jxstore/tempop/tempop.go index 89cb8a02f..69ca22e15 100644 --- a/business/jxstore/tempop/tempop.go +++ b/business/jxstore/tempop/tempop.go @@ -8,6 +8,8 @@ import ( "strings" "time" + "git.rosy.net.cn/jx-callback/business/jxstore/act" + "git.rosy.net.cn/jx-callback/business/auth2/authprovider/weixin" "git.rosy.net.cn/jx-callback/business/partner/delivery" "github.com/360EntSecGroup-Skylar/excelize" @@ -1583,7 +1585,22 @@ func UploadJdsImage(ctx *jxcontext.Context) (err error) { // fmt.Println("addList2", addList) // fmt.Println("updateList2", utils.Format4Output(updateList, false)) // fmt.Println("deleteList2", deleteList) - cms.SyncSkuExperfixAndWatermark(jxcontext.AdminCtx) + storeIDs := []int{667402, 666913, 666864, 666858, 666854, 666853, 666850, 666844} + var actStoreSkuParam []*act.ActStoreSkuParam + for _, storeID := range storeIDs { + acts, _ := dao.QueryActs(dao.GetDB(), 0, 0, 50, -1, "", -1, []int{1}, []int{0, 3, 4}, nil, storeID, nil, 0, utils.ZeroTimeValue, utils.ZeroTimeValue, utils.ZeroTimeValue, utils.ZeroTimeValue) + for _, v := range acts.Data { + _, actStoreSkus, _ := dao.GetActStoreSkuVendorList(dao.GetDB(), v.ID, nil, nil, nil, "", 0, 99999) + for _, actStoreSku := range actStoreSkus { + if actStoreSku.StoreID == storeID { + aa := &act.ActStoreSkuParam{} + actStoreSkuParam = append(actStoreSkuParam, aa) + } + } + } + } + fmt.Println("actStoreSkuParam", utils.Format4Output(actStoreSkuParam, false)) + // act.DeleteActStoreSkuBind(ctx, dao.GetDB(), v.ID, actStoreSkuParam) return err } diff --git a/business/partner/purchase/jdshop/callback.go b/business/partner/purchase/jdshop/callback.go index d2e0b602d..1ce845dbc 100644 --- a/business/partner/purchase/jdshop/callback.go +++ b/business/partner/purchase/jdshop/callback.go @@ -1,14 +1,17 @@ package jdshop import ( - "fmt" - + "git.rosy.net.cn/baseapi/platformapi/jcqapi" "git.rosy.net.cn/baseapi/platformapi/jdshopapi" - "git.rosy.net.cn/baseapi/utils" ) -func OnCallbackMsg(msg *jdshopapi.CallBackResult) { - fmt.Println("testcallback", utils.Format4Output(msg, false)) +func OnCallbackMsg(msg *jdshopapi.CallBackResult) (err error) { + msgType := msg.MsgType + switch msgType { + case jcqapi.TopicOrderPay: + default: + return + } // if CurPurchaseHandler != nil { // if msg.Cmd == mtwmapi.MsgTypeStoreStatusChanged { // response = CurPurchaseHandler.onStoreStatusChanged(msg) @@ -32,5 +35,5 @@ func OnCallbackMsg(msg *jdshopapi.CallBackResult) { // } */ // } // } - // return response + return err }