f
This commit is contained in:
@@ -62,6 +62,10 @@ func (l *QueryDetailByOrderNoLogic) QueryDetailByOrderNo(req *types.QueryDetailB
|
|||||||
|
|
||||||
queryModel, err := l.svcCtx.QueryModel.FindOneByOrderId(l.ctx, order.Id)
|
queryModel, err := l.svcCtx.QueryModel.FindOneByOrderId(l.ctx, order.Id)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
// 订单已支付但报告记录尚未生成(异步队列未处理完),返回“报告生成中”便于前端轮询
|
||||||
|
if errors.Is(err, model.ErrNotFound) {
|
||||||
|
return "", errors.Wrapf(xerr.NewErrCodeMsg(xerr.LOGIC_QUERY_WAIT, "报告生成中,请稍后再试"), "")
|
||||||
|
}
|
||||||
return "", errors.Wrapf(xerr.NewErrCode(xerr.DB_ERROR), "报告查询, 查找报告错误: %v", err)
|
return "", errors.Wrapf(xerr.NewErrCode(xerr.DB_ERROR), "报告查询, 查找报告错误: %v", err)
|
||||||
}
|
}
|
||||||
respStr, buildErr := BuildEncryptedQuery(l.ctx, l.svcCtx, queryModel)
|
respStr, buildErr := BuildEncryptedQuery(l.ctx, l.svcCtx, queryModel)
|
||||||
|
|||||||
Reference in New Issue
Block a user