| | |
| | | layerObj: { |
| | | menuName: 'menu name', |
| | | menuType: 'Menu Type', |
| | | menuName: 'Layer Name', |
| | | menuType: 'Layer Type', |
| | | serviceName: 'service name', |
| | | serviceType: 'service type', |
| | | serviceAddress: 'Service Address', |
| | |
| | | dataType: 'data type', |
| | | istrue: 'true', |
| | | isfalse: 'false', |
| | | enTableName: 'English Table Name', |
| | | prompt1: 'Please enter a layer name', |
| | | prompt2: 'Please select a layer type', |
| | | prompt3: 'Please select a service type', |
| | | prompt4: 'Please enter the service address', |
| | | |
| | | prompt6: 'Please enter the name of the English table (eg: m_geocontrollpoint)', |
| | | prompt7: 'Please enter note information', |
| | | prompt8: 'Please select a data type', |
| | | |
| | | }, |
| | | dataStaticObj: { |
| | |
| | | layerObj: { |
| | | menuName: '菜单名称', |
| | | menuType: '菜单类型', |
| | | menuName: '图层名称', |
| | | menuType: '图层类型', |
| | | serviceName: '服务名称', |
| | | serviceType: '服务类型', |
| | | serviceAddress: '服务地址', |
| | |
| | | dataType: '数据类型', |
| | | istrue: '是', |
| | | isfalse: '否', |
| | | enTableName: '英文表名称', |
| | | prompt1: '请输入图层名称', |
| | | prompt2: '请选择图层类型', |
| | | prompt3: '请选择服务类型', |
| | | prompt4: '请输入服务地址', |
| | | |
| | | prompt6: '请输入英文表名称(如:m_geocontrolpoint)', |
| | | prompt7: '请输入备注信息', |
| | | prompt8: '请选择数据类型', |
| | | }, |
| | | dataStaticObj: { |
| | | type1: '服务名称', |
| | |
| | | document.body.addEventListener('click', () => { |
| | | this.showFlag = null; |
| | | }, false); |
| | | |
| | | }, |
| | | computed: {}, |
| | | methods: { |
| | | closeSecondMenu() { |
| | | this.showFlag = null |
| | | }, |
| | | themeChange() { |
| | | this.$store.state.themeflag = !this.$store.state.themeflag; |
| | | if (this.$store.state.themeflag == true) { |
| | |
| | | if (this.$store.state.previewLayer) { |
| | | var res = this.$store.state.previewLayer; |
| | | var type = res.type; |
| | | if (res.url.indexOf('.png') != -1) { |
| | | if (type == 'DEM') { |
| | | window.terrainLayer.deleteObject(); |
| | | window.terrainLayer = null; |
| | | window.terrainLayer = new Cesium.CesiumTerrainProvider({ |
| | | url: res.url |
| | | }); |
| | | Viewer.terrainProvider = window.terrainLayer |
| | | Viewer.camera.flyTo({ |
| | | destination: Cesium.Cartesian3.fromDegrees(113.229279, 31.215949, 1000), |
| | | orientation: { |
| | | heading: 6.08434611923462, |
| | | pitch: Cesium.Math.toRadians(-45.0), |
| | | roll: 0.0 |
| | | } |
| | | }); |
| | | |
| | | } else if (res.url.indexOf('.png') != -1) { |
| | | var wkt = this.$wkt.parse(res.geom); |
| | | var height = this.getHeight(wkt.coordinates[2]) |
| | | window.BaseMapLayer = Viewer.imageryLayers.addImageryProvider( |
| | |
| | | Viewer.camera.flyTo({ |
| | | destination: Cesium.Cartesian3.fromDegrees(wkt.coordinates[1], wkt.coordinates[0], height), |
| | | }); |
| | | } else if (res.url.indexOf('.json') != -1) { |
| | | } else if (type == '3dml') { |
| | | if (this.app.tileset) viewer.scene.primitives.remove(this.app.tileset); |
| | | this.app.tileset = this.createTileset(res); |
| | | var that = this; |
| | |
| | | <!--入库质检---> |
| | | <template> |
| | | <div class="wareBox"> |
| | | <div |
| | | class="wareBox" |
| | | id="wareBox" |
| | | > |
| | | <iframe |
| | | id="ifream" |
| | | id="iframeContainer" |
| | | style="border:none" |
| | | width="100%" |
| | | height="100%" |
| | |
| | | ></iframe> |
| | | </div> |
| | | </template> |
| | | |
| | | |
| | | |
| | | <script> |
| | | import { getToken } from "@/utils/auth"; |
| | | export default { |
| | |
| | | } |
| | | }, |
| | | methods: { |
| | | closeNaveMenu() { |
| | | this.$bus.$emit('closeNaveMenu', true) |
| | | }, |
| | | langreash(res) { |
| | | |
| | | this.$router.push('/QualityInspection') |
| | | this.$router.push('/QualityInspection') |
| | | |
| | | }, |
| | | refreash(res) { |
| | | |
| | | this.$router.push('/QualityInspection') |
| | | |
| | | this.$router.push('/QualityInspection') |
| | | |
| | | }, |
| | | showChangeIfream(res) { |
| | | // |
| | |
| | | setLiClick(res, index) { |
| | | var timer = setTimeout(function () { |
| | | if (res.indexOf('http') != -1) { |
| | | this.$store.reporturl = res; |
| | | // sessionStorage.setItem('iframehttpurl', this.$store.reporturl) |
| | | this.$router.push('/QualityInspection'); |
| | | this.$store.reporturl = res; |
| | | // sessionStorage.setItem('iframehttpurl', this.$store.reporturl) |
| | | this.$router.push('/QualityInspection'); |
| | | // if (location.href.indexOf('/WareInspection') == -1) { |
| | | // this.$store.reporturl = res.url; |
| | | // this.$router.push('/WareInspection'); |
| | |
| | | }, |
| | | }, |
| | | mounted() { |
| | | // console.log(sessionStorage.getItem('iframehttpurl')) |
| | | // |
| | | |
| | | // var iframe = document.getElementById('iframeContainer'); |
| | | // iframe.onload = function (res) { |
| | | |
| | | // } |
| | | |
| | | // $('#iframeContainer').click = function () { |
| | | // console.log('点击了iframe页面') |
| | | // // if (window.sessionStorage.getItem('xxxLastTime') !== null) { |
| | | // // window.sessionStorage.setItem('xxxLastTime', new Date().getTime()) |
| | | // // } |
| | | // }; |
| | | if (sessionStorage.getItem('routerName') === '/WareInspection') { |
| | | |
| | | |
| | | this.showChangeIfream(sessionStorage.getItem('iframehttpurl')) |
| | | this.setLiClick(sessionStorage.getItem('iframehttpurl')) |
| | | |
| | |
| | | style="border: 1px solid #dcdfe6;" |
| | | > |
| | | <div> |
| | | <el-input v-model="filterText"></el-input> |
| | | <el-input |
| | | v-model="filterText" |
| | | :placeholder="$t('dataManage.layerObj.prompt1')" |
| | | suffix-icon="el-icon-search" |
| | | ></el-input> |
| | | |
| | | <el-tree |
| | | ref="tree" |
| | |
| | | <!-- 菜单名称 --> |
| | | <el-form-item :label="$t('dataManage.layerObj.menuName')"> |
| | | <el-input |
| | | :placeholder="$t('dataManage.layerObj.prompt1')" |
| | | style="width: 60%;" |
| | | v-model="formInline.cnName" |
| | | ></el-input> |
| | |
| | | <!-- 菜单类型 --> |
| | | <el-form-item :label="$t('dataManage.layerObj.menuType')"> |
| | | <el-select |
| | | :placeholder="$t('dataManage.layerObj.prompt2')" |
| | | clearable |
| | | style="width: 60%;" |
| | | v-model="formInline.type" |
| | | placeholder=" " |
| | | > |
| | | <el-option |
| | | label="目录" |
| | |
| | | clearable |
| | | style="width: 60%;" |
| | | v-model="formInline.serveType" |
| | | placeholder=" " |
| | | :placeholder="$t('dataManage.layerObj.prompt3')" |
| | | > |
| | | <el-option |
| | | v-for="item in serveType" |
| | |
| | | :label="$t('dataManage.layerObj.serviceAddress')" |
| | | > |
| | | <el-input |
| | | :placeholder="$t('dataManage.layerObj.prompt4')" |
| | | style="width: 60%;" |
| | | v-model="formInline.url" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <!-- 英文表名 --> |
| | | <el-form-item |
| | | v-show="formInline.type == 2 && formInline.serveType =='WMS'" |
| | | :label="$t('dataManage.layerObj.enTableName')" |
| | | > |
| | | <el-input |
| | | :placeholder="$t('dataManage.layerObj.prompt6')" |
| | | style="width: 60%;" |
| | | v-model="formInline.enName" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <!-- 数据类型 --> |
| | |
| | | clearable |
| | | style="width: 60%;" |
| | | v-model="formInline.dataType" |
| | | placeholder=" " |
| | | :placeholder="$t('dataManage.layerObj.prompt8')" |
| | | > |
| | | <el-option |
| | | v-for="item in dataType" |
| | |
| | | <el-input |
| | | style="width: 60%;" |
| | | v-model="formInline.bak" |
| | | :placeholder="$t('dataManage.layerObj.prompt7')" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <el-form-item v-show="menuStatus.update"> |
| | |
| | | <el-input |
| | | style="width: 80%;" |
| | | v-model="insertData.cnName" |
| | | :placeholder="$t('dataManage.layerObj.prompt1')" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <!-- 菜单类型 --> |
| | |
| | | clearable |
| | | style="width: 80%;" |
| | | v-model="insertData.type" |
| | | placeholder=" " |
| | | :placeholder="$t('dataManage.layerObj.prompt2')" |
| | | > |
| | | <el-option |
| | | label="目录" |
| | |
| | | clearable |
| | | style="width: 80%;" |
| | | v-model="insertData.serveType" |
| | | placeholder=" " |
| | | :placeholder="$t('dataManage.layerObj.prompt3')" |
| | | > |
| | | <el-option |
| | | v-for="item in serveType" |
| | |
| | | :label="$t('dataManage.layerObj.serviceAddress')" |
| | | > |
| | | <el-input |
| | | :placeholder="$t('dataManage.layerObj.prompt4')" |
| | | style="width: 80%;" |
| | | v-model="insertData.url" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <!-- 英文表名 --> |
| | | <el-form-item |
| | | v-show="insertData.type == 2 && insertData.serveType =='WMS'" |
| | | :label="$t('dataManage.layerObj.enTableName')" |
| | | > |
| | | <el-input |
| | | :placeholder="$t('dataManage.layerObj.prompt6')" |
| | | style="width: 80%;" |
| | | v-model="insertData.enName" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <!-- 数据类型 --> |
| | |
| | | clearable |
| | | style="width: 80%;" |
| | | v-model="insertData.dataType" |
| | | placeholder=" " |
| | | :placeholder="$t('dataManage.layerObj.prompt8')" |
| | | > |
| | | <el-option |
| | | v-for="item in dataType" |
| | |
| | | <!-- 描述 --> |
| | | <el-form-item :label="$t('common.bak')"> |
| | | <el-input |
| | | :placeholder="$t('dataManage.layerObj.prompt7')" |
| | | style="width: 80%;" |
| | | v-model="insertData.bak" |
| | | ></el-input> |
| | |
| | | var val = JSON.parse(JSON.stringify(res)) |
| | | |
| | | var data = this.$refs.tree.getNode(val.id).data; |
| | | |
| | | this.backUpData = JSON.stringify(data) |
| | | this.currentData = JSON.stringify(data) |
| | | this.formInline = data; |
| | | this.formInline.type = data.type.toString(); |
| | | this.formInline.isShow = data.isShow.toString(); |
| | | this.formInline.isProject = data.isProject.toString(); |
| | | var result = JSON.parse(JSON.stringify(data)) |
| | | this.backUpData = JSON.stringify(result) |
| | | this.currentData = JSON.stringify(result) |
| | | this.formInline = result; |
| | | this.formInline.type = result.type.toString(); |
| | | this.formInline.isShow = result.isShow.toString(); |
| | | this.formInline.isProject = result.isProject.toString(); |
| | | }, |
| | | //图层列表点击事件 |
| | | handleNodeClick(data, node) { |
| | |
| | | v-model="insertLayer.number" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <el-form-item :label="$t('dataManage.vmobj.labe14')"> |
| | | <el-form-item |
| | | :label="$t('dataManage.vmobj.labe14')" |
| | | v-show="formInline.type =='DOM'" |
| | | > |
| | | <el-select |
| | | style="width:100%" |
| | | v-model="insertLayer.noData" |
| | |
| | | value: 'DOM', |
| | | label: '影像数据(.tif, .img)' |
| | | }, { |
| | | value: 'DEM', |
| | | label: '高程数据(.tif)' |
| | | }, { |
| | | value: 'MPT', |
| | | label: '场景数据(.mpt)' |
| | | }, { |
| | |
| | | this.$message("请选择要发布的数据") |
| | | return |
| | | } |
| | | if (this.formInline.type == "DOM") { |
| | | if (this.formInline.type == "DOM" || this.formInline.type == "DEM") { |
| | | this.insertLayer.name = this.formInline.dirName; |
| | | this.insertLayer.number = this.multipleSelection.length |
| | | this.insertLayer.noData = '0'; |
| | |
| | | |
| | | <el-form-item> |
| | | <el-link |
| | | @click="setMapAddDraw()" |
| | | @click="drawRegularPolygon()" |
| | | :underline="false" |
| | | ><i class="el-icon-edit-outline"></i>绘制</el-link> |
| | | </el-form-item> |
| | |
| | | :underline="false" |
| | | >矢量</el-link> |
| | | </el-form-item> |
| | | <el-form-item label="旋转角度"> |
| | | <!-- <el-form-item label="旋转角度"> |
| | | <el-input |
| | | v-model="formInline.role" |
| | | placeholder="请输入内容" |
| | | @change="setMapRole" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-form-item> --> |
| | | </el-form> |
| | | </div> |
| | | <div |
| | |
| | | > |
| | | <el-form-item label="出图名称"> |
| | | <el-input v-model="form.name"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="旋转角度"> |
| | | <el-input |
| | | v-model="formInline.role" |
| | | placeholder="请输入旋转角度(0-360)" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <div style="padding: 1%; "> |
| | |
| | | import TileLayer from "ol/layer/Tile" |
| | | import { transform } from "ol/proj" |
| | | import Draw, { createRegularPolygon, createBox } from "ol/interaction/Draw.js" |
| | | |
| | | |
| | | import { OSM, Vector as VectorSource } from "ol/source" |
| | | import { Vector as VectorLayer } from "ol/layer" |
| | | import LayerVector from "ol/layer/Vector" |
| | |
| | | resolution: "20米", |
| | | date: this.getYMD(), |
| | | layers: res.toString(), |
| | | rotation: 0, |
| | | rotation: this.form.role, |
| | | xmin: this.layerExtent.xmin, |
| | | ymin: this.layerExtent.ymin, |
| | | xmax: this.layerExtent.xmax, |
| | |
| | | } |
| | | this.layerExtent = null |
| | | }, |
| | | stopDraw() { |
| | | // if (this.draw !== null) { |
| | | // this.map.removeInteraction(this.draw) |
| | | // } |
| | | if (this.draw != null) { |
| | | mapView.removeLayer(this.vector) |
| | | } |
| | | this.layerExtent = null |
| | | }, |
| | | drawRegularPolygon() { |
| | | this.stopDraw(); |
| | | |
| | | |
| | | this.source = new VectorSource({ wrapX: false }) |
| | | |
| | | this.vector = new VectorLayer({ |
| | | source: this.source, |
| | | }) |
| | | mapView.addLayer(this.vector) |
| | | |
| | | let type = 'Circle' |
| | | let geometryFunction2 = createRegularPolygon(4) |
| | | this.draw = new Draw({ |
| | | source: this.source, |
| | | type: type, |
| | | geometryFunction: geometryFunction2 |
| | | }) |
| | | mapView.addInteraction(this.draw) |
| | | this.draw.on("drawend", e => { |
| | | let feature = e.feature |
| | | let geom = feature.getGeometry() |
| | | var extent = geom.getExtent() |
| | | var a1 = transform([extent[0], extent[1]], "EPSG:3857", "EPSG:4326") |
| | | var a2 = transform([extent[2], extent[3]], "EPSG:3857", "EPSG:4326") |
| | | |
| | | this.layerExtent = { |
| | | xmin: a1[0], |
| | | ymin: a1[1], |
| | | xmax: a2[0], |
| | | ymax: a2[1], |
| | | } |
| | | |
| | | mapView.removeInteraction(this.draw) |
| | | }) |
| | | |
| | | }, |
| | | //绘制图形 |
| | | setMapAddDraw() { |
| | | this.setMapRemoveDraw() |
| | | |