Merge pull request 'by Robin at 20240517' (#452) from feat-IRONFANS-120-Robin into main

Reviewed-on: http://121.41.31.146:3000/wishpal_ironfan/service/pulls/452
This commit is contained in:
chenhao 2024-05-17 18:42:19 +08:00
commit 24a9e2236f
1 changed files with 4 additions and 3 deletions

View File

@ -931,6 +931,10 @@ func (s *Service) utilUnThumbsZoneMoment(ctx *gin.Context, req *zonemomentproto.
// 加密未解锁身份的动态
func (s *Service) utilEncryptInaccessibleZoneMoment(vo *zonemomentproto.ApiZoneMomentVO) {
if vo.GetIsCreatingPaidText() == consts.IsCreatingPaidText_Yes {
vo.Text = goproto.String(vo.GetText()[:len(vo.GetText())-len(vo.GetPaidText())])
vo.PaidText = nil
}
if vo.GetMType() == consts.MediaTypeImg {
imageIds := vo.MediaComp.GetImageIds()
mediaVisibleRange := vo.GetMediaVisibleRange()
@ -944,9 +948,6 @@ func (s *Service) utilEncryptInaccessibleZoneMoment(vo *zonemomentproto.ApiZoneM
imageIds = imageIds[:mediaVisibleRange]
vo.MediaComp.ImageIds = util.Int64Slice(imageIds)
}
if vo.GetIsCreatingPaidText() == consts.IsCreatingPaidText_Yes {
vo.Text = goproto.String(vo.GetText()[:len(vo.GetText())-len(vo.GetPaidText())])
}
}
// 填充动态是否解锁