【发布列表增加厂家信息】
This commit is contained in:
parent
8f6fffc248
commit
bdec888de8
|
@ -35,6 +35,7 @@ type PublishedGiDto struct {
|
|||
Proto []byte `json:"proto"`
|
||||
UserID int32 `json:"userID"`
|
||||
Note string `json:"note"`
|
||||
Category string `json:"category" form:"category"`
|
||||
PublishAt dto.JsonTime `json:"publishAt" time_format:"2006-01-02 15:04:05"`
|
||||
}
|
||||
|
||||
|
@ -45,6 +46,7 @@ func ConvertFrom(gi *model.PublishedGi) *PublishedGiDto {
|
|||
Proto: gi.Proto,
|
||||
Note: gi.Note,
|
||||
UserID: gi.UserID,
|
||||
Category: gi.Category,
|
||||
PublishAt: dto.JsonTime(gi.PublishAt),
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@ func PageQueryPublishedGi(req *publishedGi.PublishedGiReqDto) *dto.PageDto {
|
|||
if req.Name != "" {
|
||||
where = where.Where(dp.Name.Like(fmt.Sprintf("%%%s%%", req.Name)))
|
||||
}
|
||||
result, count, err := where.Select(dp.ID, dp.Name, dp.Note, dp.PublishAt).Debug().FindByPage(req.Offset(), req.Size)
|
||||
result, count, err := where.Omit(dbquery.PublishedGi.Proto).Debug().FindByPage(req.Offset(), req.Size)
|
||||
if err != nil {
|
||||
panic(dto.ErrorDto{Code: dto.DataOperationError, Message: err.Error()})
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue