初始
This commit is contained in:
139
api/v1/system/qianqi_dxf.go
Normal file
139
api/v1/system/qianqi_dxf.go
Normal file
@ -0,0 +1,139 @@
|
||||
// ==========================================================================
|
||||
// GFast自动生成api操作代码。
|
||||
// 生成日期:2023-07-31 11:20:54
|
||||
// 生成路径: api/v1/system/qianqi_fangzhen.go
|
||||
// 生成人:gfast
|
||||
// desc:方阵相关参数
|
||||
// company:云南奇讯科技有限公司
|
||||
// ==========================================================================
|
||||
|
||||
package system
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
commonApi "github.com/tiger1103/gfast/v3/api/v1/common"
|
||||
)
|
||||
|
||||
type DxfGetReq struct {
|
||||
g.Meta `path:"/dxfGetReq" tags:"dxf" method:"post" summary:"dxf得到json"`
|
||||
commonApi.Author
|
||||
}
|
||||
type DxfGetRes struct {
|
||||
commonApi.EmptyRes
|
||||
}
|
||||
|
||||
type DxfDataReq struct {
|
||||
g.Meta `path:"/dxfDataReq" tags:"dxf" method:"post" summary:"json数据"`
|
||||
commonApi.Author
|
||||
}
|
||||
type DxfDataRes struct {
|
||||
commonApi.EmptyRes
|
||||
Map map[string]interface{} `p:"map" `
|
||||
}
|
||||
|
||||
// 方阵
|
||||
type FzReq struct {
|
||||
g.Meta `path:"/fz" tags:"dxf" method:"post" summary:"方正数据新增"`
|
||||
commonApi.Author
|
||||
Point []FacGeoJsonByPoint `p:"point" dc:"名称"`
|
||||
Plane []FacGeoJsonByPlane `p:"plane" dc:"经纬度"`
|
||||
ProjectId string `p:"projectId" v:"required#项目id不能为空"`
|
||||
SubProjectId string `p:"subProjectId" v:"required#子项目id不能为空"`
|
||||
}
|
||||
type FzRes struct {
|
||||
commonApi.EmptyRes
|
||||
}
|
||||
|
||||
// 光伏板
|
||||
type GfbReq struct {
|
||||
g.Meta `path:"/gfb" tags:"dxf" method:"post" summary:"光伏板新增"`
|
||||
commonApi.Author
|
||||
Point []FacGeoJsonByPoint `p:"point" dc:"名称"`
|
||||
Plane []FacGeoJsonByPlane `p:"plane" dc:"经纬度"`
|
||||
ProjectId string `p:"projectId" v:"required#项目id不能为空"`
|
||||
SubProjectId string `p:"subProjectId" v:"required#子项目id不能为空"`
|
||||
}
|
||||
type GfbRes struct {
|
||||
commonApi.EmptyRes
|
||||
}
|
||||
|
||||
// 逆变器
|
||||
type NbqReq struct {
|
||||
g.Meta `path:"/nbq" tags:"dxf" method:"post" summary:"逆变器新增"`
|
||||
commonApi.Author
|
||||
Point []FacGeoJsonByPoint `p:"point" dc:"名称"`
|
||||
Plane []FacGeoJsonByPoint `p:"plane" dc:"经纬度"`
|
||||
ProjectId string `p:"projectId" v:"required#项目id不能为空"`
|
||||
SubProjectId string `p:"subProjectId" v:"required#子项目id不能为空"`
|
||||
}
|
||||
type NbqRes struct {
|
||||
commonApi.EmptyRes
|
||||
}
|
||||
|
||||
// 箱变
|
||||
type XbReq struct {
|
||||
g.Meta `path:"/xb" tags:"dxf" method:"post" summary:"箱变新增"`
|
||||
commonApi.Author
|
||||
Point []FacGeoJsonByPoint `p:"point" dc:"名称"`
|
||||
Plane []FacGeoJsonByPoint `p:"plane" dc:"经纬度"`
|
||||
ProjectId string `p:"projectId" v:"required#项目id不能为空"`
|
||||
SubProjectId string `p:"subProjectId" v:"required#子项目id不能为空"`
|
||||
}
|
||||
type XbRes struct {
|
||||
commonApi.EmptyRes
|
||||
}
|
||||
|
||||
// 桩点、立柱、支架
|
||||
type ZdReq struct {
|
||||
g.Meta `path:"/zd" tags:"dxf" method:"post" summary:"桩点、立柱、支架新增"`
|
||||
commonApi.Author
|
||||
Plane []FacGeoJsonByPoint `p:"plane" dc:"经纬度"`
|
||||
ProjectId string `p:"projectId" v:"required#项目id不能为空"`
|
||||
SubProjectid string `p:"subprojectid" v:"required#子项目id不能为空"`
|
||||
}
|
||||
type ZdRes struct {
|
||||
commonApi.EmptyRes
|
||||
}
|
||||
|
||||
//公共结构体
|
||||
|
||||
type FacGeoJsonByPlane struct {
|
||||
Name string `json:"name"`
|
||||
Type string `json:"type"`
|
||||
Features []FacFeatureByPlane `json:"features"`
|
||||
}
|
||||
|
||||
type FacFeatureByPlane struct {
|
||||
Type string `json:"type"`
|
||||
Geometry FacGeometryByPlane `json:"geometry"`
|
||||
Properties FacProperties `json:"properties"`
|
||||
}
|
||||
|
||||
type FacGeometryByPlane struct {
|
||||
Type string `json:"type"`
|
||||
Coordinates [][][]float64 `json:"coordinates"`
|
||||
ID int64 `json:"id"`
|
||||
}
|
||||
|
||||
type FacGeoJsonByPoint struct {
|
||||
Name string `json:"name"`
|
||||
Type string `json:"type"`
|
||||
Features []FacFeatureByPoint `json:"features"`
|
||||
}
|
||||
|
||||
type FacFeatureByPoint struct {
|
||||
Type string `json:"type"`
|
||||
Geometry FacGeometryByPoint `json:"geometry"`
|
||||
Properties FacProperties `json:"properties"`
|
||||
}
|
||||
|
||||
type FacGeometryByPoint struct {
|
||||
Type string `json:"type"`
|
||||
Coordinates []float64 `json:"coordinates"`
|
||||
ID int64 `json:"id"`
|
||||
}
|
||||
|
||||
type FacProperties struct {
|
||||
Type string `json:"type"`
|
||||
Text string `json:"text"`
|
||||
}
|
Reference in New Issue
Block a user