取消门店活动输出一下

This commit is contained in:
苏尹岚
2020-07-30 08:38:50 +08:00
parent fa1c22322a
commit 09b6830da1
2 changed files with 27 additions and 7 deletions

View File

@@ -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
}

View File

@@ -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
}