【增加发布排序字段】
This commit is contained in:
parent
f2c13335c2
commit
6e3f0f64f7
|
@ -23,7 +23,7 @@ func PageQueryPublished(req *dto.PagePublishedReqDto) *dto.PageDto {
|
|||
).
|
||||
LeftJoin(pv, p.DataID.EqCol(pv.ID)).
|
||||
LeftJoin(u, pv.UserID.EqCol(u.ID)).
|
||||
Order(pv.PublishAt.Desc())
|
||||
Order(p.Status.Desc(), pv.PublishAt.Desc())
|
||||
if req.Name != "" {
|
||||
where = where.Where(p.Code.Like(fmt.Sprintf("%%%s%%", req.Name)))
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue