Merge pull request 'by Robin at 20240729' (#662) from BUG-20240729 into main
Reviewed-on: http://121.41.31.146:3000/wishpal_ironfan/service/pulls/662
This commit is contained in:
commit
d24ed470b0
|
@ -1464,12 +1464,18 @@ func (s *Service) OpReviewMoment(ctx *gin.Context, req *momentproto.OpReviewReq)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// 更新动态的状态
|
// 更新请求,如果是通过,则恢复删除标志
|
||||||
err := _DefaultMoment.OpUpdateByIdsAndStatus(ctx, &momentproto.OpUpdateReq{
|
updateReq := &momentproto.OpUpdateReq{
|
||||||
Moment: &dbstruct.Moment{
|
Moment: &dbstruct.Moment{
|
||||||
Status: goproto.Int64(finalMomentStatus),
|
Status: goproto.Int64(finalMomentStatus),
|
||||||
},
|
},
|
||||||
}, req.MomentIds, consts.Moment_ManuallyReviewing)
|
}
|
||||||
|
if req.OpType == consts.MomentManuallyReview_Pass {
|
||||||
|
updateReq.Moment.DelFlag = goproto.Int64(consts.Exist)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 更新动态的状态
|
||||||
|
err := _DefaultMoment.OpUpdateByIdsAndStatus(ctx, updateReq, req.MomentIds, consts.Moment_ManuallyReviewing)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.Error("_DefaultMoment OpUpdateByIds fail, req: %v, err: %v", util.ToJson(req), err)
|
logger.Error("_DefaultMoment OpUpdateByIds fail, req: %v, err: %v", util.ToJson(req), err)
|
||||||
ec = errcode.ErrCodeMomentSrvFail
|
ec = errcode.ErrCodeMomentSrvFail
|
||||||
|
|
Loading…
Reference in New Issue