update
This commit is contained in:
@ -30,6 +30,7 @@ func NewStreetSnapHandler(svc service.StreetSnapService) *StreetSnapHandler {
|
||||
// 查询参数:
|
||||
// - page 页码,默认 1(服务端固定每页 StreetSnapFixedSize=24 条)
|
||||
// - year 年份(整数),0 表示不过滤
|
||||
// - city 地区/城市(精确匹配 city 列),'' 表示不过滤
|
||||
// - sort image_count(默认,按图片数降序)/ year_desc / year_asc
|
||||
// - locale cn / en
|
||||
//
|
||||
@ -51,6 +52,7 @@ func (h *StreetSnapHandler) parseListQuery(c *gin.Context) dto.StreetSnapQuery {
|
||||
Page: queryInt(c, "page", 1),
|
||||
Size: dto.StreetSnapFixedSize, // 服务端固定,前端不传
|
||||
Year: queryInt(c, "year", 0),
|
||||
City: c.DefaultQuery("city", ""),
|
||||
Sort: c.DefaultQuery("sort", "image_count"),
|
||||
Images: dto.StreetSnapFixedImages, // 服务端固定,前端不传
|
||||
Locale: parseLocale(c),
|
||||
|
||||
Reference in New Issue
Block a user