- remove RunParallelTask

- refactor partner.SyncStoreCategory.
This commit is contained in:
gazebo
2018-10-26 13:38:35 +08:00
parent 5f35965fee
commit 6c7b9afd10
8 changed files with 30 additions and 42 deletions

View File

@@ -337,11 +337,10 @@ func (v *VendorSync) LoopStoresMap(ctx *jxcontext.Context, db *dao.DaoDB, taskNa
task := tasksch.NewParallelTask(taskName, nil, ctx.GetUserName(), handler, loopInfoList)
ctx.SetTaskOrAddChild(task, nil)
tasksch.ManageTask(task).Run()
hint = task.ID
if !isAsync {
_, err = task.GetResult(0)
}
return hint, makeSyncError(err)
return task.ID, makeSyncError(err)
}
func (v *VendorSync) LoopMultiStoresVendors(ctx *jxcontext.Context, db *dao.DaoDB, taskName string, isAsync bool, userName string, handler tasksch.WorkFunc) (hint string, err error) {