This commit is contained in:
苏尹岚
2020-10-16 17:29:37 +08:00
parent 5908e49da8
commit 3c6fe84d2f

View File

@@ -650,9 +650,17 @@ func (v *VendorSync) AmendAndPruneStoreStuff(ctx *jxcontext.Context, vendorIDs [
func (v *VendorSync) LoopStoresMap2(ctx *jxcontext.Context, parentTask tasksch.ITask, db *dao.DaoDB, taskName string, isAsync, isManageIt bool, vendorIDs []int, storeIDs []int, mustDirty bool, handler tasksch.WorkFunc, isContinueWhenError bool) (task tasksch.ITask, hint string, err error) {
var storeMapList []*model.StoreMap
if storeMapList, err = dao.GetStoresMapList2(db, vendorIDs, storeIDs, nil, model.StoreStatusAll, model.StoreIsSyncYes, "", "", mustDirty); err != nil {
var storeMapList2 []*model.StoreMap
if storeMapList2, err = dao.GetStoresMapList2(db, vendorIDs, storeIDs, nil, model.StoreStatusAll, model.StoreIsSyncYes, "", "", mustDirty); err != nil {
return nil, "", err
}
if len(storeIDs) == 1 {
storeMapList = storeMapList2
} else {
// for _, v := range storeMapList2 {
// storeList, _ := dao.GetStoreList(db, []int{v.StoreID}, nil, nil, nil, "")
// }
}
if len(storeMapList) == 0 {
return nil, "", nil
}