|
|
@@ -326,7 +326,7 @@ |
|
|
|
|
|
|
|
<!-- 地图对话框 --> |
|
|
|
<el-dialog :title="title" :visible.sync="openMap" width="1200px" append-to-body> |
|
|
|
<el-divider><h3 class="header-anchor">地图信息:绿色地块表示该地块,蓝色表示本账套已标记的其他地块</h3></el-divider> |
|
|
|
<el-divider><h3 class="header-anchor">地图信息:绿色地块表示该地块,青色表示本组织已标记的其他地块</h3></el-divider> |
|
|
|
<div id="full-screen-acceptance" style="width: 100%;height:65vh;"> |
|
|
|
<!--<div id="landMapDiv"></div>--> |
|
|
|
<div id="mapWrap"></div> |
|
|
@@ -348,7 +348,8 @@ |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import { listLand, getLand, getLandDetail, getLandDetailByDkbm, delLand, addLand, updateLand, printLand,clearTheGeom } from "@/api/resource/land" |
|
|
|
import { listLand, listLandQuery,getLand, getLandDetail, getLandDetailByDkbm, delLand, addLand, updateLand, printLand } from "@/api/resource/land" |
|
|
|
import { areaSavePri, cleanSavePri } from "@/api/gis/map" |
|
|
|
import { getToken } from "@/utils/auth" |
|
|
|
import Treeselect from "@riophae/vue-treeselect"; |
|
|
|
import { Splitpanes, Pane } from "splitpanes" |
|
|
@@ -356,7 +357,7 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css" |
|
|
|
import "splitpanes/dist/splitpanes.css" |
|
|
|
import { deptTreeSelect } from "@/api/system/user" |
|
|
|
import {getConfigKey} from "@/api/system/config"; |
|
|
|
import {getDept,getDeptByOrgCode} from "@/api/system/dept"; |
|
|
|
import {getDept,getInfoByImportCode} from "@/api/system/dept"; |
|
|
|
import MapField from "@/components/house/MapField"; |
|
|
|
import $ from "jquery"; |
|
|
|
|
|
|
@@ -764,8 +765,11 @@ export default { |
|
|
|
}, |
|
|
|
// 获取当前部门的位置 |
|
|
|
getCurrentDeptLocation() { |
|
|
|
var id = 100; |
|
|
|
getDept(id).then(response => { |
|
|
|
var deptId = this.queryParams.deptId; |
|
|
|
if(deptId){ |
|
|
|
deptId = 100; |
|
|
|
} |
|
|
|
getDept(deptId).then(response => { |
|
|
|
let insertCode = response.data; |
|
|
|
if (insertCode != null) { |
|
|
|
this.tGeoOrganizationLat = insertCode.latitude; |
|
|
@@ -776,18 +780,21 @@ export default { |
|
|
|
/** 地图修改按钮操作 */ |
|
|
|
handleMap(row) { |
|
|
|
this.mapTheGeomId = row; |
|
|
|
getDeptByOrgCode(row.importCode).then((res) => { |
|
|
|
let insertCode = res.data; |
|
|
|
if (insertCode != null) { |
|
|
|
this.tGeoOrganizationLat = insertCode.latitude; |
|
|
|
this.tGeoOrganizationLng = insertCode.longitude; |
|
|
|
} |
|
|
|
listLand().then(response => { |
|
|
|
this.openMap = true; |
|
|
|
this.title = "修改地图"; |
|
|
|
setTimeout(() => { |
|
|
|
this.pointDarw(response.rows); |
|
|
|
}, 500); |
|
|
|
getLandDetail(row.fid).then((res) => { |
|
|
|
getInfoByImportCode(row.importCode).then((res) => { |
|
|
|
let insertCode = res.data; |
|
|
|
if (insertCode != null) { |
|
|
|
this.tGeoOrganizationLat = insertCode.latitude; |
|
|
|
this.tGeoOrganizationLng = insertCode.longitude; |
|
|
|
} |
|
|
|
const tableRow = { importCode: row.importCode }; |
|
|
|
listLandQuery(tableRow).then(response => { |
|
|
|
this.openMap = true; |
|
|
|
this.title = "修改地图"; |
|
|
|
setTimeout(() => { |
|
|
|
this.pointDarw(response.rows); |
|
|
|
}, 500); |
|
|
|
}); |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
@@ -797,8 +804,9 @@ export default { |
|
|
|
if(this.drawInsert !=null && this.drawInsert !=""){ |
|
|
|
this.mapTheGeomId.theGeom = JSON.stringify(this.drawInsert); |
|
|
|
} |
|
|
|
let sysGis = { tableName: 't_resource_land',priId: 'fid',id: this.mapTheGeomId.fid,theGeom: this.mapTheGeomId.theGeom }; |
|
|
|
if (this.mapTheGeomId != null) { |
|
|
|
updateLand(this.mapTheGeomId).then(response => { |
|
|
|
areaSavePri(sysGis).then(response => { |
|
|
|
this.$modal.msgSuccess("修改成功"); |
|
|
|
this.openMap = false; |
|
|
|
this.getList(); |
|
|
@@ -808,7 +816,8 @@ export default { |
|
|
|
}, |
|
|
|
/** 清除坐标点图层 */ |
|
|
|
clearMapLayer() { |
|
|
|
clearTheGeom(this.mapTheGeomId.fid).then(response => { |
|
|
|
let sysGis = { tableName: 't_resource_land',priId: 'fid',id: this.mapTheGeomId.fid}; |
|
|
|
cleanSavePri(sysGis).then(response => { |
|
|
|
this.$modal.msgSuccess("清除成功"); |
|
|
|
this.openMap = false; |
|
|
|
this.getList(); |
|
|
@@ -823,6 +832,10 @@ export default { |
|
|
|
var vector_drawing; |
|
|
|
var startDarw =false; |
|
|
|
var openDarw = false; |
|
|
|
this.mapTheGeomId = resourceList.find((land) => { |
|
|
|
//model就是上面的数据源 |
|
|
|
return land.fid === this.mapTheGeomId.fid; //筛选出匹配数据 |
|
|
|
}); |
|
|
|
if (this.mapTheGeomId.theGeom != null && this.mapTheGeomId.theGeom != "" |
|
|
|
&& this.mapTheGeomId.theGeom != undefined) { |
|
|
|
startDarw = true; |
|
|
@@ -879,7 +892,7 @@ export default { |
|
|
|
url: this.mapGeoServerUrl + '/wms', |
|
|
|
params: { |
|
|
|
LAYERS: this.villageBorderLayerName, |
|
|
|
cql_filter: "dept_id = '" + this.$store.state.user.loginDeptId + "'", |
|
|
|
cql_filter: "import_code = '" + this.mapTheGeomId.importCode + "'", |
|
|
|
SRID: 3857, |
|
|
|
}, |
|
|
|
}), |
|
|
@@ -1049,7 +1062,7 @@ export default { |
|
|
|
url: this.mapGeoServerUrl + '/wms', |
|
|
|
params: { |
|
|
|
LAYERS: this.villageBorderLayerName, |
|
|
|
cql_filter: "dept_id = '" + this.$store.state.user.loginDeptId + "'", |
|
|
|
cql_filter: "import_code = '" + this.mapTheGeomId.importCode + "'", |
|
|
|
SRID: 3857, |
|
|
|
}, |
|
|
|
}), |
|
|
|