82264bc9 by 杨威

删除图形删除界址点 界址线

1 parent baf514d1
...@@ -162,6 +162,27 @@ export function jzxsbatchModify(data) { ...@@ -162,6 +162,27 @@ export function jzxsbatchModify(data) {
162 }) 162 })
163 } 163 }
164 164
165 /*
166 删除界址点
167 */
168 export function delJzdByBsm(data){
169 return request({
170 url: '/zd/qjJzd/',
171 method: 'delete',
172 params: data
173 })
174 }
175 /*
176 删除界址线
177 */
178 export function delJzxByBsm(data){
179 return request({
180 url: '/zd/qjJzx/',
181 method: 'delete',
182 params: data
183 })
184 }
185
165 /**x 186 /**x
166 *根据宗地Bsm删除宗地信息 187 *根据宗地Bsm删除宗地信息
167 */ 188 */
......
...@@ -127,7 +127,7 @@ ...@@ -127,7 +127,7 @@
127 </template> 127 </template>
128 <script> 128 <script>
129 import lineItem from "./lineItem.vue"; 129 import lineItem from "./lineItem.vue";
130 import {deleteZdInfoByBsm,exportShp,exportExcel} from "@api/zd"; 130 import {deleteZdInfoByBsm,exportShp,exportExcel,delJzdByBsm,delJzxByBsm} from "@api/zd";
131 import Create from "../../views/panel/create/index"; 131 import Create from "../../views/panel/create/index";
132 import ImportGeo from './tx/importGeo' 132 import ImportGeo from './tx/importGeo'
133 import geoUtils from "@components/lineTree/tx/js/geoUtils"; 133 import geoUtils from "@components/lineTree/tx/js/geoUtils";
...@@ -529,7 +529,13 @@ export default { ...@@ -529,7 +529,13 @@ export default {
529 self.updateGraphic(featureUrl, features, function (res) { 529 self.updateGraphic(featureUrl, features, function (res) {
530 if(!res.updateFeatureResults[0].error){ 530 if(!res.updateFeatureResults[0].error){
531 self.$message.warning("删除成功!!!") 531 self.$message.warning("删除成功!!!")
532 self.addGeoByBsm(BSM,type,"testMap"); 532 //清除图层
533 self.clearHighlightLayer("testMap");
534 //self.addGeoByBsm(BSM,type,"testMap");
535 //删除界址点 界址线
536 if(type == 'zd'){
537 self.delJzdAndJzx(BSM);
538 }
533 } 539 }
534 540
535 }); 541 });
...@@ -538,6 +544,19 @@ export default { ...@@ -538,6 +544,19 @@ export default {
538 } 544 }
539 }); 545 });
540 }, 546 },
547 //删除宗地界址点 界址线
548 delJzdAndJzx(bsm){
549 delJzdByBsm({zdbsm:bsm}).then(res => {
550 if(res.success){
551 console.log("删除界址点成功!!!");
552 }
553 });
554 delJzxByBsm({zdbsm:bsm}).then(res => {
555 if(res.success){
556 console.log("删除界址线成功!!!");
557 }
558 })
559 },
541 /* 560 /*
542 * 导入图形 561 * 导入图形
543 * */ 562 * */
......
...@@ -381,8 +381,9 @@ export default { ...@@ -381,8 +381,9 @@ export default {
381 if(valid){ 381 if(valid){
382 //选择处理方式 382 //选择处理方式
383 var value = self.dealForm.method; 383 var value = self.dealForm.method;
384 self.currntDealGraphic.attributes = {};
384 switch (value) { 385 switch (value) {
385 case '1':self.currntDealGraphic.attributes.BGZT =1;self.saveZd(self.currntDealGraphic);break; 386 case '1':self.currntDealGraphic.attributes.BGZT = 1;self.saveZd(self.currntDealGraphic);break;
386 case "2":self.getDifference(self.currntDealGraphic,self.overResults,self.delOverGeo);break; 387 case "2":self.getDifference(self.currntDealGraphic,self.overResults,self.delOverGeo);break;
387 case "3":self.getResultsDif(self.overResults,self.currntDealGraphic,self.delOtherGeo,true);break; 388 case "3":self.getResultsDif(self.overResults,self.currntDealGraphic,self.delOtherGeo,true);break;
388 case "4":self.getResultsDif(self.overResults,self.currntDealGraphic,self.delOtherGeo,false);break; 389 case "4":self.getResultsDif(self.overResults,self.currntDealGraphic,self.delOtherGeo,false);break;
...@@ -395,6 +396,9 @@ export default { ...@@ -395,6 +396,9 @@ export default {
395 }, 396 },
396 //裁剪自己在保存 397 //裁剪自己在保存
397 delOverGeo(geometry){ 398 delOverGeo(geometry){
399 if(!this.currntDealGraphic.attributes){
400 this.currntDealGraphic.attributes = {};
401 }
398 this.currntDealGraphic.attributes.BGZT =2; 402 this.currntDealGraphic.attributes.BGZT =2;
399 if(geometry == null){ 403 if(geometry == null){
400 this.$message.warning("完全重叠,已删除图形信息!!!") 404 this.$message.warning("完全重叠,已删除图形信息!!!")
......
...@@ -508,6 +508,14 @@ export default { ...@@ -508,6 +508,14 @@ export default {
508 return; 508 return;
509 } 509 }
510 }); 510 });
511 } 511 },
512 //清空当前图层
513 clearHighlightLayer(viewId){
514 var view = maps[viewId];
515 var layer = view.map.findLayerById("highlightLayer");
516 if(layer){
517 layer.removeAll();
518 }
519 }
512 } 520 }
513 } 521 }
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -806,7 +806,7 @@ ...@@ -806,7 +806,7 @@
806 var qlrTableData = this.$refs.qlrxxModule.tableData; 806 var qlrTableData = this.$refs.qlrxxModule.tableData;
807 if(qlrTableData.length > 0){ 807 if(qlrTableData.length > 0){
808 for(var i = 0;i < qlrTableData.length;i++){ 808 for(var i = 0;i < qlrTableData.length;i++){
809 if(i == 0){ 809 if(i = 0){
810 self.geoAttributes[key] = qlrTableData[i].qlrmc; 810 self.geoAttributes[key] = qlrTableData[i].qlrmc;
811 }else{ 811 }else{
812 self.geoAttributes[key] += ','+ qlrTableData[i].qlrmc; 812 self.geoAttributes[key] += ','+ qlrTableData[i].qlrmc;
......