派生自 wuyushui/SewerAndRainNetwork

徐旺旺
2021-05-13 58610182c816673867a30966b08b44cd9a26710c
添加应急图层
3个文件已添加
3个文件已修改
135 ■■■■■ 已修改文件
src/conf/LayerEmergency.js 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/conf/MapConfig.js 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/conf/layers/LayerArea.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/conf/layers/LayerEmergencySource.js 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/conf/layers/LayerPk.js 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/conf/layers/LayerSurroundings.js 61 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/conf/LayerEmergency.js
New file
@@ -0,0 +1,14 @@
/**
 * 专题
 */
import { LayerEmergencySource } from './layers/LayerEmergencySource'
import { LayerSurroundings } from './layers/LayerSurroundings'
export const LayerEmergency = {
  code: 'sewersEmergency',
  name: '应急图层',
  checked: false,
  isShow: true,
  type: 0,
  layers: [LayerEmergencySource, LayerSurroundings]
}
src/conf/MapConfig.js
@@ -2,6 +2,7 @@
import TDT from './TDT'
import { LayerTopic } from './LayerTopic'
import { LayerBasin } from './layers/LayerBasin'
import { LayerEmergency } from './LayerEmergency'
const curWwwPath = window.document.location.href
const pathname = window.document.location.pathname
@@ -41,7 +42,7 @@
  IntranetBaseMaps: TDT.intranet,
  InternetBaseMaps: TDT.internet,
  Layers: {
    LayerSewersLine: [LayerBasin, LayerTopic]
    LayerSewersLine: [LayerBasin, LayerTopic, LayerEmergency]
  } // 污雨水图层配置
}
src/conf/layers/LayerArea.js
@@ -1,7 +1,7 @@
/**
 * 区域
 */
import { PIPELINE_WFS } from '../Constants'
import { SERVICE_TYPE, PIPELINE_WFS } from '../Constants'
const WFS_URL = PIPELINE_WFS
export const LayerArea = {
  code: 'sewersArea',
@@ -30,8 +30,8 @@
      name: '装置区',
      sname: '装置区',
      checked: false, // 默认选中状态
      type: 0,
      wfs: WFS_URL + '?TYPENAME=装置区'
      type: SERVICE_TYPE.WMS,
      typeName: 'sewer:unitareaboundary'
    }
  ]
}
src/conf/layers/LayerEmergencySource.js
New file
@@ -0,0 +1,41 @@
import { SERVICE_TYPE } from '../Constants'
/**
 * 应急资源
 */
export const LayerEmergencySource = {
  code: 'sewersEmergencySource',
  name: '应急资源',
  checked: false,
  layers: [
    {
      code: 'sewersYjWz',
      name: '应急物资',
      sname: '应急物资',
      checked: false,
      type: SERVICE_TYPE.WMS,
      icon: 'sewers/雨水排口.png',
      typeName: 'sewer:emergencyesources',
      minZoom: 10 // 在指定级别显示
    },
    {
      code: 'sewersYjcl',
      name: '应急车辆',
      sname: '应急车辆',
      icon: 'sewers/雨水排口.png',
      checked: false, // 默认选中状态
      type: SERVICE_TYPE.WMS,
      minZoom: 10
    },
    {
      code: 'sewersYjdw',
      name: '应急队伍',
      sname: '应急队伍',
      icon: 'sewers/雨水排口.png',
      checked: false, // 默认选中状态
      type: SERVICE_TYPE.WMS,
      typeName: 'sewer:maintenanceteam',
      minZoom: 10
    }
  ]
}
src/conf/layers/LayerPk.js
@@ -1,3 +1,5 @@
import { SERVICE_TYPE } from '../Constants'
/**
 * 排口
 */
@@ -13,9 +15,9 @@
      name: '内排口',
      sname: '内排口',
      checked: true,
      type: 0,
      type: SERVICE_TYPE.WMS,
      icon: 'sewers/雨水排口.png',
      wfs: 'http://xearth.cn:6240/geoserver/sewer/wfs?service=WFS&version=1.0.0&request=GetFeature&typeName=sewer:dischargeport&maxFeatures=50&outputFormat=application/json&cql_filter=pfktype=\'内排\'',
      typeName: 'sewer:dischargeport',
      minZoom: 10 // 在指定级别显示
    },
    {
@@ -24,8 +26,8 @@
      sname: '外排口',
      icon: 'sewers/雨水排口.png',
      checked: true, // 默认选中状态
      type: 0,
      wfs: 'http://xearth.cn:6240/geoserver/sewer/wfs?service=WFS&version=1.0.0&request=GetFeature&typeName=sewer:dischargeport&maxFeatures=50&outputFormat=application/json&cql_filter=pfktype=\'外排\'',
      type: SERVICE_TYPE.WMS,
      typeName: 'sewer:dischargeport',
      minZoom: 10
    }
  ]
src/conf/layers/LayerSurroundings.js
New file
@@ -0,0 +1,61 @@
import { SERVICE_TYPE } from '../Constants'
/**
 * 周边环境
 */
export const LayerSurroundings = {
  code: 'sewersSurroundings',
  name: '应急资源',
  checked: false,
  layers: [
    {
      code: 'sewersYy',
      name: '医院',
      sname: '医院',
      checked: false,
      type: SERVICE_TYPE.WMS,
      icon: 'sewers/雨水排口.png',
      typeName: 'sewer:hospital',
      minZoom: 10 // 在指定级别显示
    },
    {
      code: 'sewersXx',
      name: '学校',
      sname: '学校',
      icon: 'sewers/雨水排口.png',
      checked: false, // 默认选中状态
      type: SERVICE_TYPE.WMS,
      minZoom: 10
    },
    {
      code: 'sewersSt',
      name: '水体',
      sname: '水体',
      icon: 'sewers/雨水排口.png',
      checked: false, // 默认选中状态
      type: SERVICE_TYPE.WMS,
      typeName: 'sewer:pointhydrology',
      minZoom: 10
    },
    {
      code: 'sewersZrbhq',
      name: '自然保护区',
      sname: '自然保护区',
      icon: 'sewers/雨水排口.png',
      checked: false, // 默认选中状态
      type: SERVICE_TYPE.WMS,
      wfs: 'sewer:pointpreservationzone',
      minZoom: 10
    },
    {
      code: 'sewersMgmb',
      name: '敏感目标',
      sname: '敏感目标',
      icon: 'sewers/雨水排口.png',
      checked: false, // 默认选中状态
      type: SERVICE_TYPE.WMS,
      wfs: 'sewer:sensitivetarget',
      minZoom: 10
    }
  ]
}