a
This commit is contained in:
@@ -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) {
|
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
|
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
|
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 {
|
if len(storeMapList) == 0 {
|
||||||
return nil, "", nil
|
return nil, "", nil
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user