| | |
| | | <template> |
| | | <div class="dispatch"> |
| | | <el-tabs v-model="activeName" @tab-click="handleClick"> |
| | | <!-- 基本信息 --> |
| | | <el-tab-pane label="基本信息" name="tab1"> |
| | |
| | | ></farmPaper> |
| | | </el-tab-pane> |
| | | </el-tabs> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | res: "data", |
| | | url: "url" |
| | | }, |
| | | action: "/api/blade-resource/oss/endpoint/put-file" |
| | | action: "/api/blade-resource/oss/endpoint/put-files" |
| | | }, |
| | | { |
| | | label: "农场位置", |
| | |
| | | }; |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userInfo", "permission", "polygons"]), |
| | | ...mapGetters(["userInfo", "permission", "polygonsFarm"]), |
| | | }, |
| | | mounted() { |
| | | var that = this; |
| | |
| | | methods: { |
| | | //农场基本信息提交 |
| | | submitBase(form, loading, done) { |
| | | if (this.polygons.length == 0) { |
| | | if (this.polygonsFarm.length == 0) { |
| | | //没有面的数据 |
| | | this.$refs.getMapData.isCheck = true; |
| | | loading(); |
| | | } else { |
| | | //如果有值,空间坐标转换 |
| | | let pol = this.polygons; |
| | | let polLength = this.polygons.length - 1; |
| | | let pol = this.polygonsFarm; |
| | | let polLength = this.polygonsFarm.length - 1; |
| | | let usePolygons = ""; |
| | | for (let k in pol) { |
| | | usePolygons += pol[k].lng + "," + pol[k].lat; |