From 407af0be27179bba9677f1761dd6233a9a5fcda0 Mon Sep 17 00:00:00 2001 From: liujun Date: Mon, 29 Apr 2024 16:21:23 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E6=A0=BC=E5=BC=8F=E5=8C=96?= =?UTF-8?q?=EF=BC=8C=E6=B2=A1=E7=94=A8=E6=9B=B4=E6=94=B9=E4=BB=BB=E4=BD=95?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../firefighting/points/components/edit.vue | 43 ++++++++++--------- .../promise_book/components/list.vue | 20 ++++----- 2 files changed, 33 insertions(+), 30 deletions(-) diff --git a/src/views/firefighting/points/components/edit.vue b/src/views/firefighting/points/components/edit.vue index 9f1ca74..f5325f5 100644 --- a/src/views/firefighting/points/components/edit.vue +++ b/src/views/firefighting/points/components/edit.vue @@ -167,11 +167,12 @@ import { upload } from '@/utils/upload' import SelectTree from '@/components/SelectTree' import waves from '@/directive/waves' // waves directive import TiandiMap from '@/components/TianMap/TiandiMap.vue' -import RyDragEntity from "../../../map/js/ry_dragentity"; -import DragEntity from "../../../map/js/dragentity"; +import RyDragEntity from '../../../map/js/ry_dragentity' +import DragEntity from '../../../map/js/dragentity' let viewer = null let drag = null +// eslint-disable-next-line no-unused-vars let ry_drag = null var tiandituTk = 'e8a16137fd226a62a23cc7ba5c9c78ce' var subdomains = ['0', '1', '2', '3', '4', '5', '6', '7'] @@ -278,7 +279,7 @@ export default { }, center: { longitude: 119.6486945226887, latitude: 39.93555616569192, height: 900000 }, poinEntity: {}, - dichitype :0 + dichitype: 0 } }, watch: { @@ -328,7 +329,7 @@ export default { }, initMap2() { console.info(viewer) - if (this.dichitype ===2){ + if (this.dichitype === 2) { return } viewer = new Cesium.Viewer('cesiumContainer', { @@ -372,9 +373,9 @@ export default { this.initInfo() this.leftDownAction() console.log(this.LATITUDE) - if(this.LATITUDE){ + if (this.LATITUDE) { console.log('LATITUDE') - this.dfdfd (this.LONGTITUDE,this.LATITUDE) + this.dfdfd(this.LONGTITUDE, this.LATITUDE) } this.loadTilesetHandler() @@ -383,17 +384,16 @@ export default { }) this.dichitype = 2 }, - leftDownAction(){ + leftDownAction() { // 去掉entity的点击事件 start viewer.cesiumWidget.screenSpaceEventHandler.removeInputAction(Cesium.ScreenSpaceEventType.LEFT_DOUBLE_CLICK) viewer.cesiumWidget.screenSpaceEventHandler.removeInputAction(Cesium.ScreenSpaceEventType.LEFT_CLICK) // 去掉entity的点击事件 end this.handler = new Cesium.ScreenSpaceEventHandler(viewer.scene.canvas) - let id this.handler.setInputAction(movement => { + // eslint-disable-next-line no-unused-vars var cartesian = this.getCatesian3FromPX(movement.position) }, Cesium.ScreenSpaceEventType.LEFT_CLICK) - }, getCatesian3FromPX: function(px) { if (viewer && px) { @@ -421,8 +421,11 @@ export default { if (cartesian) { const cartographic = Cesium.Cartographic.fromCartesian(cartesian) if (cartographic.height < 0) cartographic.height = 0 + // eslint-disable-next-line prefer-const,one-var let lon = Cesium.Math.toDegrees(cartographic.longitude), + // eslint-disable-next-line prefer-const lat = Cesium.Math.toDegrees(cartographic.latitude), + // eslint-disable-next-line prefer-const height = cartographic.height cartesian = this.transformWGS84ToCartesian({ lng: lon, @@ -461,26 +464,26 @@ export default { const height = cartographic.height // 高度 this.LONGTITUDE = lng this.LATITUDE = lat - this.dfdfd(lng,lat) + this.dfdfd(lng, lat) return `CGCS2000 坐标: 经度 ${lng}, 纬度 ${lat}, 高度 ${height}` } }, transformWGS84ToCartesian: function(position, alt) { // eslint-disable-next-line no-return-assign return position ? Cesium.Cartesian3.fromDegrees( - position.lng || position.lon, - position.lat, - position.alt = alt || position.alt, - Cesium.Ellipsoid.WGS84 - ) + position.lng || position.lon, + position.lat, + position.alt = alt || position.alt, + Cesium.Ellipsoid.WGS84 + ) : Cesium.Cartesian3.ZERO }, - dfdfd (LONGITUDE,LATITUDE){ + dfdfd(LONGITUDE, LATITUDE) { let dianweiName = '消防点位' - if(this.form.FIRE_POINT_NAME){ + if (this.form.FIRE_POINT_NAME) { dianweiName = this.form.FIRE_POINT_NAME } - var initPoint = [ + var initPoint = [ { 'id': '00002', 'data_id': '00002', @@ -503,7 +506,7 @@ export default { }, // 加载点 dragAreaEntity(pointArr) { - console.log('pointArr',pointArr) + console.log('pointArr', pointArr) console.log('') this.poinEntity = {} @@ -716,7 +719,7 @@ export default { handleMap() { this.dialogFormMap = true this.$nextTick(() => { - if (!this.map){ + if (!this.map) { // this.initMap(this.LONGTITUDE, this.LATITUDE, 16) this.initCorpInfo() } else { diff --git a/src/views/security_commitment/promise_book/components/list.vue b/src/views/security_commitment/promise_book/components/list.vue index 5de4a8c..cb52373 100644 --- a/src/views/security_commitment/promise_book/components/list.vue +++ b/src/views/security_commitment/promise_book/components/list.vue @@ -54,13 +54,13 @@ + v-model="ADDTIME" + type="daterange" + value-format="yyyy-MM-dd" + range-separator="至" + start-placeholder="开始日期" + end-placeholder="结束日期" + class="filter-item"/> @@ -189,7 +189,7 @@ export default { }, // 搜索 getQuery() { - if (this.ADDTIME == null | this.ADDTIME == undefined ){ + if (this.ADDTIME == null | this.ADDTIME == undefined) { this.ADDTIME = [] } this.getList() @@ -218,8 +218,8 @@ export default { DEPARTMENT_IDS: this.DEPARTMENT_ID.join(','), LEVEL: this.LEVEL, STATUS: this.STATUS, - ADDSTART: this.ADDTIME==undefined?'':this.ADDTIME[0], - ADDEND: this.ADDTIME==undefined?'':this.ADDTIME[1] + ADDSTART: this.ADDTIME == undefined ? '' : this.ADDTIME[0], + ADDEND: this.ADDTIME == undefined ? '' : this.ADDTIME[1] } ).then((data) => { this.listLoading = false