京东page的cookie可能有问题
This commit is contained in:
@@ -2322,7 +2322,7 @@ func SyncStoresCourierInfo(ctx *jxcontext.Context, storeIDs []int, isAsync, isCo
|
||||
func SyncStoresQualify(ctx *jxcontext.Context, storeIDs []int, isAsync, isContinueWhenError bool) (hint string, err error) {
|
||||
if len(storeIDs) > 0 {
|
||||
db := dao.GetDB()
|
||||
task := tasksch.NewParallelTask(fmt.Sprintf("上传门店资质:%v", storeIDs), tasksch.NewParallelConfig().SetParallelCount(1).SetIsContinueWhenError(isContinueWhenError), ctx,
|
||||
task := tasksch.NewParallelTask(fmt.Sprintf("上传门店资质:%v", storeIDs), tasksch.NewParallelConfig().SetIsContinueWhenError(isContinueWhenError), ctx,
|
||||
func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) {
|
||||
vendorID := model.VendorIDJD
|
||||
if handler := partner.GetPurchasePlatformFromVendorID(vendorID).(partner.IStoreSyncQualifyHandler); handler != nil {
|
||||
|
||||
@@ -201,6 +201,16 @@ func GetCheckVendorCookie(ctx *jxcontext.Context, vendorIDs []int, isAuto bool)
|
||||
flag = true
|
||||
}
|
||||
}
|
||||
result2, err2 := api.JdPageAPI.GetCorporationInfo("11926674", "92510108MA68KK3M8P")
|
||||
if err2 != nil || result2 == nil {
|
||||
cc := &CheckCookie{}
|
||||
cc.VendorID = v
|
||||
cc.VendorOrgCode = "京东page账号"
|
||||
cc.Status = "无效"
|
||||
ccList = append(ccList, cc)
|
||||
errMsg += fmt.Sprintf(" 京东page账号:的Cookie无效了!", vv)
|
||||
flag = true
|
||||
}
|
||||
}
|
||||
cc.VendorID = v
|
||||
cc.VendorOrgCode = vv
|
||||
|
||||
@@ -6,8 +6,6 @@ import (
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"git.rosy.net.cn/baseapi/platformapi/jdapi"
|
||||
|
||||
"git.rosy.net.cn/jx-callback/business/partner/purchase/jx/localjx"
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
|
||||
@@ -252,8 +250,8 @@ func Init() {
|
||||
api.MtwmAPI.SetCookieWithStr(mtwmCookieStr)
|
||||
api.MtpsAPI.SetCookie("token", mtpsStoreToken)
|
||||
api.JdAPI.SetJdCookie(JdStorePageCookie)
|
||||
api.JdPageAPI.SetCookie(jdapi.AccessStorePageCookieName, JdStorePageCookie)
|
||||
api.JdPageAPI.SetCookie(jdapi.AccessStorePageCookieName2, JdStorePageCookie)
|
||||
// api.JdPageAPI.SetCookie(jdapi.AccessStorePageCookieName, JdStorePageCookie)
|
||||
// api.JdPageAPI.SetCookie(jdapi.AccessStorePageCookieName2, JdStorePageCookie)
|
||||
}
|
||||
|
||||
func syncStoreSku() {
|
||||
|
||||
Reference in New Issue
Block a user