From 2df553eb8be1993ee6c390b0d36ddaa437ebd293 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Sun, 27 Sep 2020 18:21:42 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BF=94=E5=9B=9Ehint?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- business/jxstore/cms/store.go | 6 +++--- controllers/cms_store.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/business/jxstore/cms/store.go b/business/jxstore/cms/store.go index b84544e4c..7d742adde 100644 --- a/business/jxstore/cms/store.go +++ b/business/jxstore/cms/store.go @@ -3612,10 +3612,10 @@ func GetStoreAudit(ctx *jxcontext.Context, statuss []int, keyword, applyTimeStar return pagedInfo, err } -func StoreAudit(ctx *jxcontext.Context, storeAudits []*model.StoreAudit, status int) (err error) { +func StoreAudit(ctx *jxcontext.Context, storeAudits []*model.StoreAudit, status int) (hint string, err error) { db := dao.GetDB() if status != model.StoreAuditStatusCreated && status != model.StoreAuditStatusRejected { - return fmt.Errorf("审核标志不正确!") + return "", fmt.Errorf("审核标志不正确!") } task := tasksch.NewParallelTask("StoreAudit", tasksch.NewParallelConfig().SetParallelCount(5).SetIsContinueWhenError(true), ctx, func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) { @@ -3662,6 +3662,6 @@ func StoreAudit(ctx *jxcontext.Context, storeAudits []*model.StoreAudit, status return retVal, err }, storeAudits) tasksch.HandleTask(task, nil, true).Run() - task.GetID() + hint = task.GetID() return err } diff --git a/controllers/cms_store.go b/controllers/cms_store.go index da28300eb..410a2a3df 100644 --- a/controllers/cms_store.go +++ b/controllers/cms_store.go @@ -898,7 +898,7 @@ func (c *StoreController) StoreAudit() { c.callStoreAudit(func(params *tStoreStoreAuditParams) (retVal interface{}, errCode string, err error) { var stores []*model.StoreAudit if err = utils.UnmarshalUseNumber([]byte(params.Payload), &stores); err == nil { - err = cms.StoreAudit(params.Ctx, stores, params.Status) + retVal, err = cms.StoreAudit(params.Ctx, stores, params.Status) } return retVal, "", err })