Merge branch 'master' of http://yun.pashanhoo.com:9090/renchao/CadastralSystem
Showing
9 changed files
with
95 additions
and
14 deletions
... | @@ -7,5 +7,20 @@ | ... | @@ -7,5 +7,20 @@ |
7 | "layerName": "ZRZ", | 7 | "layerName": "ZRZ", |
8 | "layerUrl": "http://192.168.2.201:6080/arcgis/rest/services/%E4%BA%92%E8%81%94%E7%BD%91%E5%8A%A0%E4%B8%8D%E5%8A%A8%E4%BA%A7/XA_%E4%B8%8D%E5%8A%A8%E4%BA%A7/MapServer", | 8 | "layerUrl": "http://192.168.2.201:6080/arcgis/rest/services/%E4%BA%92%E8%81%94%E7%BD%91%E5%8A%A0%E4%B8%8D%E5%8A%A8%E4%BA%A7/XA_%E4%B8%8D%E5%8A%A8%E4%BA%A7/MapServer", |
9 | "id": "10" | 9 | "id": "10" |
10 | }, | ||
11 | { | ||
12 | "layerName": "DJQ", | ||
13 | "layerUrl": "http://192.168.2.201:6080/arcgis/rest/services/%E4%BA%92%E8%81%94%E7%BD%91%E5%8A%A0%E4%B8%8D%E5%8A%A8%E4%BA%A7/XA_%E4%B8%8D%E5%8A%A8%E4%BA%A7/MapServer", | ||
14 | "id": "13" | ||
15 | }, | ||
16 | { | ||
17 | "layerName": "DJZQ", | ||
18 | "layerUrl": "http://192.168.2.201:6080/arcgis/rest/services/%E4%BA%92%E8%81%94%E7%BD%91%E5%8A%A0%E4%B8%8D%E5%8A%A8%E4%BA%A7/XA_%E4%B8%8D%E5%8A%A8%E4%BA%A7/MapServer", | ||
19 | "id": "14" | ||
20 | }, | ||
21 | { | ||
22 | "layerName": "XJZQ", | ||
23 | "layerUrl": "http://192.168.2.201:6080/arcgis/rest/services/%E4%BA%92%E8%81%94%E7%BD%91%E5%8A%A0%E4%B8%8D%E5%8A%A8%E4%BA%A7/XA_%E4%B8%8D%E5%8A%A8%E4%BA%A7/MapServer", | ||
24 | "id": "19" | ||
10 | } | 25 | } |
11 | ] | 26 | ] |
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
... | @@ -196,11 +196,19 @@ export default { | ... | @@ -196,11 +196,19 @@ export default { |
196 | attributes:self.currentClickZd, | 196 | attributes:self.currentClickZd, |
197 | geometry:geometry | 197 | geometry:geometry |
198 | } | 198 | } |
199 | if(self.propertyInfo.type == "zd"){ | 199 | self.geoJoint(geometry,function (isJoint,message) { |
200 | self.saveZd(graphic); | 200 | if(isJoint){ |
201 | }else{ | 201 | self.$message.warning(message) |
202 | self.saveZRZ(graphic); | 202 | return; |
203 | } | 203 | }else { |
204 | if(self.propertyInfo.type == "zd"){ | ||
205 | self.saveZd(graphic); | ||
206 | }else{ | ||
207 | self.saveZRZ(graphic); | ||
208 | } | ||
209 | } | ||
210 | }); | ||
211 | |||
204 | } else { | 212 | } else { |
205 | console.log('error submit!!'); | 213 | console.log('error submit!!'); |
206 | return false; | 214 | return false; | ... | ... |
... | @@ -4,6 +4,7 @@ | ... | @@ -4,6 +4,7 @@ |
4 | 4 | ||
5 | import layers from '@/assets/json/layers.json' | 5 | import layers from '@/assets/json/layers.json' |
6 | import queryUtils from "@libs/map/queryUtils"; | 6 | import queryUtils from "@libs/map/queryUtils"; |
7 | import identifyUtils from '@/libs/map/IdentifyUtils' | ||
7 | import {loadModules} from "esri-loader" | 8 | import {loadModules} from "esri-loader" |
8 | import arcgisParser from 'terraformer-arcgis-parser' | 9 | import arcgisParser from 'terraformer-arcgis-parser' |
9 | import wktParse from 'terraformer-wkt-parser' | 10 | import wktParse from 'terraformer-wkt-parser' |
... | @@ -155,6 +156,54 @@ export default { | ... | @@ -155,6 +156,54 @@ export default { |
155 | primitive.type = "Polygon" | 156 | primitive.type = "Polygon" |
156 | }*/ | 157 | }*/ |
157 | return arcgisParser.convert(primitive) | 158 | return arcgisParser.convert(primitive) |
159 | }, | ||
160 | //导入空间图形是 先判断数据是否跨界 | ||
161 | geoJoint(geometry,callBacFunction){ | ||
162 | var self = this; | ||
163 | loadModules([ | ||
164 | "esri/geometry/geometryEngine", | ||
165 | "esri/geometry/Polygon" | ||
166 | ]).then(([ | ||
167 | geometryEngine, | ||
168 | Polygon | ||
169 | ]) => { | ||
170 | var djqLayer = null,djzqLayer = null,xjzqLayer = null; | ||
171 | djqLayer = self.getLayerByName("DJQ"); | ||
172 | djzqLayer = self.getLayerByName("DJZQ"); | ||
173 | xjzqLayer = self.getLayerByName("XJZQ"); | ||
174 | var layerIds = []; | ||
175 | layerIds.push(djqLayer.id); | ||
176 | layerIds.push(djzqLayer.id); | ||
177 | layerIds.push(xjzqLayer.id); | ||
178 | var polygon = new Polygon(geometry); | ||
179 | identifyUtils.methods.identify(djqLayer.layerUrl,layerIds,polygon,function (res) { | ||
180 | var results = res.results; | ||
181 | var isJoint = false,layerName = "",message=""; | ||
182 | if(!results || results.length == 0){ | ||
183 | callBacFunction(true,"不在行政区内,请检查空间位置信息!!!"); | ||
184 | } | ||
185 | for(var i = 0;i < results.length;i++){ | ||
186 | var feature = results[i].feature; | ||
187 | var flag = geometryEngine.disjoint(polygon,feature.geometry); | ||
188 | if(flag){ | ||
189 | isJoint = true; | ||
190 | layerName = results[i].layerName; | ||
191 | switch (layerName) { | ||
192 | case 'DJQ':message = "地块跨越地籍区,数据不合法!!!";break; | ||
193 | case 'DJZQ':message = "地块跨越地籍子区,数据不合法!!!";break; | ||
194 | case 'XJZQ':message = "地块跨越行政区,数据不合法!!!";break; | ||
195 | } | ||
196 | break | ||
197 | } | ||
198 | } | ||
199 | if(callBacFunction && typeof callBacFunction == "function"){ | ||
200 | callBacFunction(isJoint,message); | ||
201 | } | ||
202 | }) | ||
203 | }).catch(err => { | ||
204 | console.log(err); | ||
205 | throw (err); | ||
206 | }) | ||
158 | } | 207 | } |
159 | 208 | ||
160 | } | 209 | } | ... | ... |
... | @@ -10,17 +10,20 @@ export default { | ... | @@ -10,17 +10,20 @@ export default { |
10 | "esri/tasks/support/IdentifyParameters" | 10 | "esri/tasks/support/IdentifyParameters" |
11 | ]).then(([ | 11 | ]).then(([ |
12 | IdentifyTask, | 12 | IdentifyTask, |
13 | IdentifyParameters | 13 | IdentifyParameters |
14 | ]) => { | 14 | ]) => { |
15 | var identifyTask = new IdentifyTask({ | 15 | var identifyTask = new IdentifyTask({ |
16 | url:url | 16 | url:url |
17 | }), | 17 | }), |
18 | identifyParameters = new identifyParameters(); | 18 | identifyParameters = new IdentifyParameters(); |
19 | identifyParameters.geometry = geometry; | 19 | identifyParameters.geometry = geometry; |
20 | if(layerIds){ | 20 | if(layerIds){ |
21 | identifyParameters.layerIds = layerIds; | 21 | identifyParameters.layerIds = layerIds; |
22 | } | 22 | } |
23 | identifyParameters.layerOption = "all"; | 23 | identifyParameters.layerOption = "all"; |
24 | identifyParameters.tolerance = 3; | ||
25 | identifyParameters.mapExtent = geometry.extent; | ||
26 | identifyParameters.returnGeometry = true; | ||
24 | identifyParameters.spatialReference = geometry.spatialReference; | 27 | identifyParameters.spatialReference = geometry.spatialReference; |
25 | identifyTask.execute(identifyParameters).then(result => { | 28 | identifyTask.execute(identifyParameters).then(result => { |
26 | if(callBackFunction && typeof callBackFunction == 'function'){ | 29 | if(callBackFunction && typeof callBackFunction == 'function'){ | ... | ... |
... | @@ -135,7 +135,13 @@ | ... | @@ -135,7 +135,13 @@ |
135 | default: | 135 | default: |
136 | break; | 136 | break; |
137 | } | 137 | } |
138 | this.$router.push(path); | 138 | this.$router.push({ |
139 | path: path, | ||
140 | query: { | ||
141 | bsm: row.glbsm, | ||
142 | source: 2 | ||
143 | } | ||
144 | }); | ||
139 | }, | 145 | }, |
140 | }, | 146 | }, |
141 | computed: {}, | 147 | computed: {}, | ... | ... |
This diff is collapsed.
Click to expand it.
... | @@ -372,7 +372,7 @@ | ... | @@ -372,7 +372,7 @@ |
372 | return { | 372 | return { |
373 | tabName: 'zd', | 373 | tabName: 'zd', |
374 | centerDialogVisible: false, | 374 | centerDialogVisible: false, |
375 | bgqData: [], | 375 | zdFgqData: [], |
376 | hbhData: {}, | 376 | hbhData: {}, |
377 | fgBoxWidth: 0, | 377 | fgBoxWidth: 0, |
378 | xzq: [], | 378 | xzq: [], |
... | @@ -462,10 +462,10 @@ | ... | @@ -462,10 +462,10 @@ |
462 | }, | 462 | }, |
463 | addData: function (val) { | 463 | addData: function (val) { |
464 | this.centerDialogVisible = false; | 464 | this.centerDialogVisible = false; |
465 | this.bgqData.push(val) | 465 | this.zdFgqData.push(val) |
466 | }, | 466 | }, |
467 | getData: function (data) { | 467 | getData: function (data) { |
468 | this.bgqData.push(data) | 468 | this.zdFgqData.push(data) |
469 | }, | 469 | }, |
470 | }, | 470 | }, |
471 | computed: {}, | 471 | computed: {}, | ... | ... |
... | @@ -8,6 +8,7 @@ | ... | @@ -8,6 +8,7 @@ |
8 | :before-remove="beforeRemove" | 8 | :before-remove="beforeRemove" |
9 | :on-success="uploadSuccess" | 9 | :on-success="uploadSuccess" |
10 | :on-error="uploadError" | 10 | :on-error="uploadError" |
11 | :show-file-list="false" | ||
11 | multiple | 12 | multiple |
12 | :limit="3" | 13 | :limit="3" |
13 | :on-exceed="handleExceed" | 14 | :on-exceed="handleExceed" |
... | @@ -107,7 +108,6 @@ | ... | @@ -107,7 +108,6 @@ |
107 | }, | 108 | }, |
108 | uploadSuccess(res, file, fileList) { | 109 | uploadSuccess(res, file, fileList) { |
109 | this.filesData.list = res.result; | 110 | this.filesData.list = res.result; |
110 | console.log(res, "res=========") | ||
111 | insertFile(this.filesData).then(res => { | 111 | insertFile(this.filesData).then(res => { |
112 | if (res.success) { | 112 | if (res.success) { |
113 | Message.success("上传成功") | 113 | Message.success("上传成功") | ... | ... |
-
Please register or sign in to post a comment