Files
easygoadmin/app/dto/city.go
yaoyilin 1b36bd8fbe feat: 初始化项目
初始化项目
2022-10-31 22:29:16 +08:00

46 lines
1.9 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/**
* 城市Dto
* @author
* @since 2021/11/13
* @File : city
*/
package dto
// 列表查询条件
type CityQueryReq struct {
Name string `form:"name"` // 城市名称
Pid int `form:"pid"` // 上级ID
}
// 添加城市
type CityAddReq struct {
Pid string `form:"pid"` // 父级编号
Level string `form:"level" binding:"required"` // 城市级别1省 2市 3区
Name string `form:"name" binding:"required"` // 城市名称
Citycode string `form:"citycode"` // 城市编号(区号)
PAdcode string `form:"pAdcode"` // 父级地理编号
Adcode string `form:"adcode"` // 地理编号
Lng string `form:"lng"` // 城市坐标中心点经度(* 1e6如果是中国此值是 1e7
Lat string `form:"lat"` // 城市坐标中心点纬度(* 1e6
Sort string `form:"sort"` // 排序号
}
// 编辑城市
type CityUpdateReq struct {
Id string `form:"id" binding:"required"` // 主键ID
Pid string `form:"pid"` // 父级编号
Level string `form:"level" binding:"required"` // 城市级别1省 2市 3区
Name string `form:"name" binding:"required"` // 城市名称
Citycode string `form:"citycode"` // 城市编号(区号)
PAdcode string `form:"pAdcode"` // 父级地理编号
Adcode string `form:"adcode"` // 地理编号
Lng string `form:"lng"` // 城市坐标中心点经度(* 1e6如果是中国此值是 1e7
Lat string `form:"lat"` // 城市坐标中心点纬度(* 1e6
Sort string `form:"sort"` // 排序号
}
// 获取子级城市
type CityChildReq struct {
CityCode string `form:"citycode" binding:"required"`
}