From f6e2c7d08bb4f29f38a77b9f789c6d7a47d5bebe Mon Sep 17 00:00:00 2001 From: chenyabin <Chenab123!> Date: 星期五, 14 五月 2021 11:20:10 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/develop' into develop --- src/components/LayerController/logic/WasteGas.js | 2 src/components/panel/topicSearch/GasWasteSearch.vue | 86 ++-------------- src/conf/layers/LayerAirQuality.js | 3 src/conf/layers/LayerPlate.js | 30 +---- src/components/panel/topicSearch/SewersSelect/EnterpriseEmergency/ResourcesQuery.vue | 9 - src/conf/layers/LayerArea.js | 2 src/conf/layers/LayerBasin.js | 18 -- src/components/panel/topicSearch/SolidWasteSearch.vue | 2 src/components/LayerController/service/WmsLayerService.js | 6 src/components/panel/topicSearch/WaterWasteSearch.vue | 96 ++----------------- src/conf/Constants.js | 7 src/conf/layers/LayerEnvRisk.js | 8 - src/components/LayerController/logic/WasteWater.js | 2 13 files changed, 46 insertions(+), 225 deletions(-) diff --git a/src/components/LayerController/logic/WasteGas.js b/src/components/LayerController/logic/WasteGas.js index 2fe606c..17706bc 100644 --- a/src/components/LayerController/logic/WasteGas.js +++ b/src/components/LayerController/logic/WasteGas.js @@ -72,7 +72,7 @@ storagePlaceId: res } }, - title: title // 鏍囬 + title: '澶╂触鐭冲寲' + title // 鏍囬 }) this.animalService.setPanTo(e.latlng, 150) } diff --git a/src/components/LayerController/logic/WasteWater.js b/src/components/LayerController/logic/WasteWater.js index 3d9587e..6f67ed6 100644 --- a/src/components/LayerController/logic/WasteWater.js +++ b/src/components/LayerController/logic/WasteWater.js @@ -68,7 +68,7 @@ storagePlaceId: res } }, - title: title // 鏍囬 + title: '澶╂触鐭冲寲' + title // 鏍囬 }) this.animalService.setPanTo(e.latlng, 150) } diff --git a/src/components/LayerController/service/WmsLayerService.js b/src/components/LayerController/service/WmsLayerService.js index a20dad6..076340e 100644 --- a/src/components/LayerController/service/WmsLayerService.js +++ b/src/components/LayerController/service/WmsLayerService.js @@ -1,5 +1,5 @@ import AjaxUtils from '../../../utils/AjaxUtils' -import { PIPELINE_WMS } from '../../../conf/Constants' +import { WMS_URL } from '../../../conf/Constants' import Popup from '@views/popup/Popup' import WmsLayerList from '../dataset/WmsLayerList' @@ -80,7 +80,7 @@ if (filter.length > 0) { params.cql_filter = filter } - this.wmsLayer = this.L.tileLayer.wms(PIPELINE_WMS, params).addTo(this.map) + this.wmsLayer = this.L.tileLayer.wms(WMS_URL, params).addTo(this.map) } clickListener () { @@ -102,7 +102,7 @@ Y: Math.round(point.y), BBOX: this.map.getBounds().toBBoxString() }, this.params) - AjaxUtils.get4JsonDataByUrl(PIPELINE_WMS, params, (res) => { + AjaxUtils.get4JsonDataByUrl(WMS_URL, params, (res) => { const features = res.data.features /** * { diff --git a/src/components/panel/topicSearch/GasWasteSearch.vue b/src/components/panel/topicSearch/GasWasteSearch.vue index b4d485f..ad63218 100644 --- a/src/components/panel/topicSearch/GasWasteSearch.vue +++ b/src/components/panel/topicSearch/GasWasteSearch.vue @@ -98,16 +98,14 @@ <script> import mapApi from '@/api/mapApi' -import publicBounced from '@/components/BaseNav/PublicBounced/PublicBounced'// import WfsHelper from '@components/helpers/WfsHelper' -import ImagGreen from '../../../../public/assets/images/map/exhaust/fq_green2.png' +import WasteWaterIndex from '../../BaseNav/WasteWater/WasteWaterIndex' + export default { name: 'GasWasteSearch', + props: ['title'], data () { return { - layer: window.map, - L: window.L, gdVisible: true, - instance: null, list: [], total: 0, inareaTypeOptions: [], @@ -121,8 +119,6 @@ }, // pageSize: 10, // current: 1, - isWaybillHover: true, - isRouteHover: false, levelOfRisk: [ { name: '鍏ㄩ儴', value: '1' }, { name: '姝e父', value: '2' }, @@ -132,7 +128,6 @@ ] } }, - props: ['title'], methods: { // 鍖哄煙绛涢�� areaType (val) { @@ -171,73 +166,16 @@ console.log(val) const pos = [val.Latitude, val.Longitude] window.map.flyTo(pos, 15) - const positionX = val.Latitude - const positionY = val.Longitude - - // 瀹氫箟绫诲瀷 鐢ㄦ潵鍖哄垎鏁版嵁鐨勪笉鍚� 1.鎺ュ彛鎺ュ彛鏁版嵁鏉ヨ繘琛屾暟鎹殑鍒ゆ柇 2.鏍规嵁鏁版嵁绫诲瀷鐨勪笉鍚岋紝杩涜涓嶅悓绫诲瀷鐨勫浘鐗囨樉绀� - const ContrLevel = val.ContrLevel - var iconUrl = this.differentTypes(ContrLevel) - - const marker = this.L.marker([positionX, positionY], { - icon: this.L.icon({ - iconUrl: iconUrl, - iconSize: [30, 30], - iconAnchor: [15, 15] - }) + window.$layer.open({ + content: { + content: WasteWaterIndex, // 缁勪欢 + parent: this, // 鐖剁粍浠� + data: { // 浼犻�掔殑鍙傛暟 + storagePlaceId: val + } + }, + title: '澶╂触鐭冲寲 ' + val.Name }) - this.layer.addLayer(marker) - const t1 = setTimeout(async () => { - const dataValue = { - StoragePlaceId: val.StoragePlaceId - } - // 寮规鏍囬 - const title = val - console.log(title) - // 鍩烘湰淇℃伅 tabs - const result = await mapApi.getWasteGas(dataValue) - const GasOnlinedata = { - onLineMonEmissPointId: '23', - monItemId: '28,31', - beginTime: '2020-04-06 15:13:20', - endTime: '2020-04-07 15:13:20', - dataType: '1' - } - const GasManualData = { - companyId: '3900100145', - labMonPointId: '219', - beginTime: '2020-04-06 15:13:20', - endTime: ' 2020-04-07 15:13:20' - } - const ManualData = await mapApi.getWasteGasManualData(GasManualData) - const Mondata = await mapApi.getWasteGasMonData(GasOnlinedata) - // 缁戝畾寮规瀹炰緥 - this.instance && this.instance.closePopup() - const PublicBounced = window.Vue.extend(publicBounced) - this.instance = new PublicBounced().$mount() - document.body.appendChild(this.instance.$el) - // document.body.removeChild(instance.$el) - // 閫氳繃鏂规硶 鍚戠粦瀹氬脊妗嗕紶閫掓暟鎹� - this.instance.setGasData(title, result.Result.DataInfo, Mondata.Result.DataInfo, ManualData.Result.DataInfo, 'feiqi') - // console.log(title, result.Result.DataInfo, Mondata.Result.DataInfo, ManualData.Result.DataInfo) - // this.setPanTo(pos, 250) - }, 100) - console.log(t1) - }, - // 涓嶅悓绫诲瀷鍥剧墖鍔犺浇 - differentTypes (ContrLevel) { - // effectOfChange - /* - if (ContrLevel === 1) { - effectOfChange = ImgBlue - } else if (ContrLevel === 2) { - */ - const effectOfChange = ImagGreen - // } else if (ContrLevel === 3) { - // effectOfChange = ImagBright - // } else { - // effectOfChange = ImgGray - // } - return effectOfChange } } } diff --git a/src/components/panel/topicSearch/SewersSelect/EnterpriseEmergency/ResourcesQuery.vue b/src/components/panel/topicSearch/SewersSelect/EnterpriseEmergency/ResourcesQuery.vue index 856850d..5a88c59 100644 --- a/src/components/panel/topicSearch/SewersSelect/EnterpriseEmergency/ResourcesQuery.vue +++ b/src/components/panel/topicSearch/SewersSelect/EnterpriseEmergency/ResourcesQuery.vue @@ -53,7 +53,6 @@ </template> <script> -// import { LayerEntEmer } from '../../../../../conf/layers/LayerEntEmer' import WfsHelper from '@components/helpers/WfsHelper' import AjaxUtils from '@utils/AjaxUtils' @@ -79,8 +78,6 @@ list: [], items: [LayerEmergencySource, LayerSurroundings], subItems: LayerEmergencySource.layers || LayerSurroundings.layers, - // subItems: [{ name: '鍏ㄩ儴璧勬簮' }, { name: '搴旀�ョ墿璧�' }, { name: '搴旀�ヨ溅杈�(鑸�)' }, { name: '搴旀�ラ槦浼�(鍚秷闃插崟浣�)' }], - // subItemsT: [{ name: '鍏ㄩ儴鐜' }, { name: '鍖婚櫌', icon: 'sewers/鍖婚櫌.png' }, { name: '瀛︽牎' }, { name: '姘翠綋' }, { name: '鑷劧淇濇姢鍖�' }, { name: '鏁忔劅鐩爣' }], WfsHelper: null } }, @@ -89,7 +86,7 @@ }, methods: { getImgSrc (type) { - console.log(type) + // console.log(type) // const icon = this.form.dataType.icon return 'assets/images/map/sewers/' + type + '.png' }, @@ -105,8 +102,8 @@ } if (this.form.pipelineType === '搴旀�ヨ祫婧�') { this.subItems = LayerEmergencySource.layers - } else { - this.subItems = LayerSurroundings.layers // (this.form.pipelineType === '鍛ㄨ竟鐜') + } else if (this.form.pipelineType === '鍛ㄨ竟鐜') { + this.subItems = LayerSurroundings.layers } }, handleDataType (val) { diff --git a/src/components/panel/topicSearch/SolidWasteSearch.vue b/src/components/panel/topicSearch/SolidWasteSearch.vue index 5814b50..da9c045 100644 --- a/src/components/panel/topicSearch/SolidWasteSearch.vue +++ b/src/components/panel/topicSearch/SolidWasteSearch.vue @@ -8,7 +8,7 @@ <el-select style="width: 100%" v-model="form.pipelineType" @change="handlePipelineType" :popper-class="'select-down'"> <el-option - v-for="item in solidWasteTypeOptions" + v-for="item in solidWasteTypeOptions.labelList" :key="item.value" :label="item.label" :value="item.value"> diff --git a/src/components/panel/topicSearch/WaterWasteSearch.vue b/src/components/panel/topicSearch/WaterWasteSearch.vue index 1a1f807..3fca159 100644 --- a/src/components/panel/topicSearch/WaterWasteSearch.vue +++ b/src/components/panel/topicSearch/WaterWasteSearch.vue @@ -98,18 +98,14 @@ <script> import mapApi from '@/api/mapApi' -import publicBounced from '@/components/BaseNav/PublicBounced/PublicBounced'// import WfsHelper from '@components/helpers/WfsHelper' -import ImagGreen from '../../../../public/assets/images/map/wastewater/fs_bright_green.png' +import WasteWaterIndex from '../../BaseNav/WasteWater/WasteWaterIndex' export default { name: 'WaterWasteSearch', props: ['title'], data () { return { - layer: window.map, - L: window.L, gdVisible: true, - instance: null, list: [], total: 0, inareaTypeOptions: [], @@ -172,88 +168,16 @@ console.log(val) const pos = [val.Latitude, val.Longitude] window.map.flyTo(pos, 15) - const positionX = val.Latitude - const positionY = val.Longitude - - // 瀹氫箟绫诲瀷 鐢ㄦ潵鍖哄垎鏁版嵁鐨勪笉鍚� 1.鎺ュ彛鎺ュ彛鏁版嵁鏉ヨ繘琛屾暟鎹殑鍒ゆ柇 2.鏍规嵁鏁版嵁绫诲瀷鐨勪笉鍚岋紝杩涜涓嶅悓绫诲瀷鐨勫浘鐗囨樉绀� - const testValue = val.testValue - var iconUrl = this.differentTypes(testValue) - - const marker = this.L.marker([positionX, positionY], { - icon: this.L.icon({ - iconUrl: iconUrl, - iconSize: [30, 30], - iconAnchor: [15, 15] - }) + window.$layer.open({ + content: { + content: WasteWaterIndex, // 缁勪欢 + parent: this, // 鐖剁粍浠� + data: { // 浼犻�掔殑鍙傛暟 + storagePlaceId: val + } + }, + title: '澶╂触鐭冲寲 ' + val.Name }) - this.layer.addLayer(marker) - const t1 = setTimeout(async () => { - const dataValue = { - StoragePlaceId: val.StoragePlaceId - } - // 寮规鏍囬 - const title = val - console.log(title) - // 鍩烘湰淇℃伅 tabs - const detailData = await mapApi.getWasteWater(dataValue) - const WaterOnlinedata = { - onLineMonEmissPointId: '23', - monItemId: '28,31', - beginTime: '2020-04-06 15:13:20', - endTime: '2020-04-07 15:13:20', - dataType: '1' - } - const WaterManualData = { - companyId: '3900100145', - labMonPointId: '219', - beginTime: '2020-04-06 15:13:20', - endTime: ' 2020-04-07 15:13:20' - } - const dateData = await mapApi.getQueryLabMonData(WaterManualData) - const hourData = await mapApi.getQueryOnlineMonData(WaterOnlinedata) - // 缁戝畾寮规瀹炰緥 - this.instance && this.instance.closePopup() - const PublicBounced = window.Vue.extend(publicBounced) - this.instance = new PublicBounced().$mount() - document.body.appendChild(this.instance.$el) - // document.body.removeChild(instance.$el) - // 閫氳繃鏂规硶 鍚戠粦瀹氬脊妗嗕紶閫掓暟鎹� - this.instance.setWaterData(title, detailData.Result.DataInfo, hourData.Result.DataInfo, dateData.Result.DataInfo, 'feishui') - console.log(title, detailData.Result.DataInfo, hourData.Result.DataInfo, dateData.Result.DataInfo) - // this.setPanTo(pos, 250) - }, 100) - console.log(t1) - }, - // 涓嶅悓绫诲瀷鍥剧墖鍔犺浇 - differentTypes (testValue) { - const testChange = ImagGreen - // switch (testValue) { - // case 1: - // testChange = NormalImg - // break - // case 2: - // testChange = OffImg - // break - // case 3: - // testChange = AbnormalImg - // break - // case 4: - // testChange = MissImg - // break - // case 5: - // testChange = NormalImg - // break - // case 6: - // testChange = AlarmImg - // break - // case 7: - // testChange = AbnormalImg - // break - // case 8: - // testChange = WarnImg - // break - // } - return testChange } } } diff --git a/src/conf/Constants.js b/src/conf/Constants.js index 4b29334..1617d8c 100644 --- a/src/conf/Constants.js +++ b/src/conf/Constants.js @@ -1,6 +1,7 @@ -export const WFS_URL = 'http://xearth.cn:6240/geoserver/sewer/ows?service=WFS' -export const PIPELINE_WFS = 'http://xearth.cn:8088/server/ogcserver/PipeLine2/wfs' -export const PIPELINE_WMS = 'http://xearth.cn:6240/geoserver/sewer/wms' + +// export const PIPELINE_WMS = 'http://xearth.cn:6240/geoserver/sewer/wms' +export const WMS_URL = 'http://10.238.235.179:6240/geoserver/sewer/wms' +export const WFS_URL = 'http://10.238.235.179:6240/geoserver/sewer/ows?service=WFS' export const GEOM_TYPE = { POINT: 'point', diff --git a/src/conf/layers/LayerAirQuality.js b/src/conf/layers/LayerAirQuality.js index cff5758..04e932f 100644 --- a/src/conf/layers/LayerAirQuality.js +++ b/src/conf/layers/LayerAirQuality.js @@ -1,13 +1,10 @@ /** * 鍖哄煙 */ -import { PIPELINE_WFS } from '../Constants' -const WFS_URL = PIPELINE_WFS export const LayerAirQuality = { code: 'sewersAirQuality', name: '绌烘皵璐ㄩ噺', checked: false, - type: 0, layers: [ { code: 'airQualityStation', diff --git a/src/conf/layers/LayerArea.js b/src/conf/layers/LayerArea.js index 7a33fbd..4f77b42 100644 --- a/src/conf/layers/LayerArea.js +++ b/src/conf/layers/LayerArea.js @@ -1,8 +1,6 @@ /** * 鍖哄煙 */ -import { SERVICE_TYPE, PIPELINE_WFS } from '../Constants' -const WFS_URL = PIPELINE_WFS export const LayerArea = { code: 'sewersArea', name: '鍖哄煙淇℃伅', diff --git a/src/conf/layers/LayerBasin.js b/src/conf/layers/LayerBasin.js index 0c56d92..807c670 100644 --- a/src/conf/layers/LayerBasin.js +++ b/src/conf/layers/LayerBasin.js @@ -1,8 +1,6 @@ /** * 娴佸煙 */ -import { PIPELINE_WFS } from '../Constants' -const WFS_URL = PIPELINE_WFS export const LayerBasin = { code: 'sewersBasin', name: '鍖哄煙鍥惧眰', @@ -14,33 +12,25 @@ code: 'basinCj', name: '闀挎睙娴佸煙', sname: '闀挎睙娴佸煙', // 琛ㄥ悕 - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - url: WFS_URL + '?TYPENAME=鍏徃' + checked: true }, { code: 'basinHh', name: '榛勬渤娴佸煙', sname: '榛勬渤娴佸煙', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=鐮佸ご' + checked: true }, { code: 'basinBh', name: '娓ゆ捣娴佸煙', sname: '娓ゆ捣娴佸煙', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true }, { code: 'basinQt', name: '鍏朵粬', sname: '鍏朵粬', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true } ] } diff --git a/src/conf/layers/LayerEnvRisk.js b/src/conf/layers/LayerEnvRisk.js index 712ac55..aeb0937 100644 --- a/src/conf/layers/LayerEnvRisk.js +++ b/src/conf/layers/LayerEnvRisk.js @@ -1,8 +1,6 @@ /** * 鐜椋庨櫓 */ -import { PIPELINE_WFS } from '../Constants' -const WFS_URL = PIPELINE_WFS export const LayerEnvRisk = { code: 'sewersEnvRisk', name: '鐜椋庨櫓', @@ -14,8 +12,6 @@ name: '椋庨櫓缁熻鍥�', sname: '椋庨櫓缁熻鍥�', // 琛ㄥ悕 checked: false, // 榛樿閫変腑鐘舵�� - type: 0, - url: WFS_URL + '?TYPENAME=鍏徃', color: '' }, { @@ -23,8 +19,6 @@ name: '鐗╄祫搴�', sname: '鐗╄祫搴�', checked: false, // 榛樿閫変腑鐘舵�� - type: 0, - wfs: WFS_URL + '?TYPENAME=鐮佸ご', color: '' }, { @@ -32,8 +26,6 @@ name: '閲嶅ぇ椋庨櫓', sname: '閲嶅ぇ椋庨櫓', checked: false, // 榛樿閫変腑鐘舵�� - type: 0, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�', minZoom: 10, color: 'red' }, diff --git a/src/conf/layers/LayerPlate.js b/src/conf/layers/LayerPlate.js index eb3b404..4b66a64 100644 --- a/src/conf/layers/LayerPlate.js +++ b/src/conf/layers/LayerPlate.js @@ -1,8 +1,6 @@ /** * 鏉垮潡 */ -import { PIPELINE_WFS } from '../Constants' -const WFS_URL = PIPELINE_WFS export const LayerPlate = { code: 'sewersPlate', name: '鏉垮潡鍥惧眰', @@ -14,57 +12,43 @@ code: 'plateYt', name: '娌圭敯', sname: '娌圭敯', // 琛ㄥ悕 - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - url: WFS_URL + '?TYPENAME=鍏徃' + checked: true }, { code: 'plateLh', name: '鐐煎寲', sname: '鐐煎寲', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=鐮佸ご' + checked: true }, { code: 'plateXs', name: '閿�鍞�', sname: '閿�鍞�', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true }, { code: 'plateHg', name: '鍖栧伐', sname: '鍖栧伐', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true }, { code: 'plateZy', name: '涓撲笟鍏徃', sname: '涓撲笟鍏徃绉戠爺鏈烘瀯', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true }, { code: 'plateKyjg', name: '绉戠爺鏈烘瀯', sname: '绉戠爺鏈烘瀯', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true }, { code: 'plateGcdw', name: '宸ョ▼鍗曚綅', sname: '宸ョ▼鍗曚綅', - checked: true, // 榛樿閫変腑鐘舵�� - type: 2, - wfs: WFS_URL + '?TYPENAME=瑁呯疆鍖�' + checked: true } ] } -- Gitblit v1.8.0