作者 tangxvhui

Merge branch 'dev' into test

... ... @@ -365,6 +365,7 @@ type (
CompanyId int64 `json:",optional"`
Id int64 `json:"id"`
Show int `json:"show"` //[1 显示评论] [2: 隐藏评论]
Content string `json:"content,optional"`
CountAdminLove int `json:"countAdminLove,optional"`
}
... ...
... ... @@ -37,6 +37,7 @@ func (l *SystemEditAticleCommentLogic) SystemEditAticleComment(req *types.System
return nil, xerr.NewErrMsg("没有操作权限")
}
commetInfo.CountAdminLove = req.CountAdminLove
commetInfo.Content = req.Content
var increaseCount int
switch req.Show {
case 1:
... ... @@ -52,7 +53,7 @@ func (l *SystemEditAticleCommentLogic) SystemEditAticleComment(req *types.System
increaseCount = -1
}
}
commetInfo.Show = domain.CommentShowEnable
// 变更回复数量
err = transaction.UseTrans(l.ctx, conn.DB(), func(ctx context.Context, c transaction.Conn) error {
_, err = l.svcCtx.ArticleCommentRepository.Update(ctx, c, commetInfo)
... ...
... ... @@ -268,6 +268,7 @@ type SystemEditCommentRequest struct {
CompanyId int64 `json:",optional"`
Id int64 `json:"id"`
Show int `json:"show"` //[1 显示评论] [2: 隐藏评论]
Content string `json:"content,optional"`
CountAdminLove int `json:"countAdminLove,optional"`
}
... ...