diff --git a/app/mix/service/apiservice.go b/app/mix/service/apiservice.go index b9b24c9c..b93b708e 100644 --- a/app/mix/service/apiservice.go +++ b/app/mix/service/apiservice.go @@ -3276,7 +3276,10 @@ func (s *Service) ApiHvyogoQueryAgreeState(ctx *gin.Context, req *hvyogoproto.Ap } if workerId == nil { logger.Error("No worker_id entity was found") - ec = errcode.ErrCodeWorkerIdNotExist + data = &hvyogoproto.ApiQueryAgreeStateData{ + StatusCode: response.StatusCodeFail, + StatusText: "用户尚未认证", + } return } @@ -3316,7 +3319,10 @@ func (s *Service) ApiHvyogoWorkerFindDetail(ctx *gin.Context, req *hvyogoproto.A } if workerId == nil { logger.Error("No worker_id entity was found") - ec = errcode.ErrCodeWorkerIdNotExist + data = &hvyogoproto.ApiWorkerFindDetailData{ + StatusCode: response.StatusCodeFail, + StatusText: "用户尚未认证", + } return } @@ -3459,6 +3465,11 @@ func (s *Service) ApiHvyogoSingleDistribute(ctx *gin.Context, req *hvyogoproto.A logger.Error("_DefaultSingleDistributeHis OpUpdate fail, err: %v", err) } + if resp.StatusCode != response.StatusCodeSuccess { + err = fmt.Errorf("single distribution fail") + return resp, err + } + return resp, nil } @@ -3495,7 +3506,10 @@ func (s *Service) ApiHvyogoWorkerUpdate(ctx *gin.Context, req *hvyogoproto.ApiWo } if workerId == nil { logger.Error("No worker_id entity was found") - ec = errcode.ErrCodeWorkerIdNotExist + data = &hvyogoproto.ApiWorkerUpdateData{ + StatusCode: response.StatusCodeFail, + StatusText: "用户尚未认证", + } return }