| | |
| | | :data="tableDataAffFac" |
| | | border |
| | | @row-click="affFacName" |
| | | height="100" |
| | | max-height="100" |
| | | height="120" |
| | | max-height="140" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | show-overflow-tooltip |
| | | prop="properties.pipecode" |
| | | label="附属设施编号"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | show-overflow-tooltip |
| | | prop="properties.measattribute" |
| | | label="附属设施名称"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | show-overflow-tooltip |
| | | width="150" |
| | | prop="properties.code" |
| | | label="附属设施名称"> |
| | | label="编号"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | show-overflow-tooltip |
| | | prop="properties.datasource" |
| | | label="附属设施类型"> |
| | | width="150" |
| | | prop="properties.name" |
| | | label="附属设施名称"> |
| | | </el-table-column> |
| | | <el-table-column width="40" fixed="right" label="操作"> |
| | | <el-table-column |
| | | width="150" |
| | | show-overflow-tooltip |
| | | prop="properties.type" |
| | | label="类型"> |
| | | </el-table-column> |
| | | <el-table-column width="90" fixed="right" label="操作"> |
| | | <template slot-scope="scope"> |
| | | <el-button @click="localAdr(scope.row)" type="text" size="small">定位</el-button> |
| | | </template> |
| | |
| | | // 附属设施查询列表数据 |
| | | tableDataAffFac: [], |
| | | // 定义类型判断 if 是搜索到的数据可以进行管线选择 else 点击定位选择的管线不可以进行选择 |
| | | SectionAndAffFacTableJudge: false, |
| | | locateJudgmentSearch: false |
| | | SectionAndAffFacTableJudge: false |
| | | } |
| | | }, |
| | | mounted () { |
| | |
| | | this.wfsHelper = new WfsHelper() |
| | | // 附属设施查询 |
| | | this.tableDataAffFac = [] |
| | | const AffFacSearch = val.properties.mediumtype |
| | | const AffFacSearch = val.properties.pipecode |
| | | console.log(AffFacSearch) |
| | | this.wfsHelper.clearFilter() |
| | | this.wfsHelper.setTypeName(['sewer:view_pipeline']) |
| | | this.wfsHelper.addLike('type', AffFacSearch) |
| | | this.wfsHelper.addLike('pipecode', AffFacSearch) |
| | | // this.wfsHelper.addEquals('type', '\'' + AffFacSearch + '\'') |
| | | const resAffFac = await AjaxUtils.GetDataAsynByUrl(this.wfsHelper.getUrl(), {}) |
| | | console.log(resAffFac) |
| | |
| | | }, |
| | | // 定位功能 |
| | | localAdr (val) { |
| | | console.log(val) |
| | | // console.log(val) |
| | | fitBounds(val) |
| | | highlight(val) |
| | | }, |
| | |
| | | EXCEPTIONS: 'application/vnd.ogc.se_inimage' |
| | | }) |
| | | AjaxUtils.get4JsonDataByUrl(WMS_URL, wmsParams, (res) => { |
| | | // console.log(res) |
| | | console.log(res) |
| | | for (let i = 0; i < res.data.features.length; i++) { |
| | | // console.log(res.data.features[i]) |
| | | this.tableList.push(res.data.features[i]) |
| | |
| | | // 附属设施 |
| | | this.affFacData(e) |
| | | // }) |
| | | window.map.off('click') |
| | | }) |
| | | // 数据 重新获取 进行置空 |
| | | this.tableList = [] |
| | |
| | | const size = window.map.getSize() |
| | | var point = window.map.latLngToContainerPoint(e.latlng, window.map.getZoom()) |
| | | const wmsParams = Object.assign({ |
| | | LAYERS: 'pipeline_fs', |
| | | QUERY_LAYERS: 'pipeline_fs', |
| | | LAYERS: 'sewer:view_pipeline', |
| | | QUERY_LAYERS: 'sewer:view_pipeline', |
| | | // LAYERS: 'pipeline_fs', |
| | | // QUERY_LAYERS: 'pipeline_fs', |
| | | WIDTH: size.x, |
| | | HEIGHT: size.y, |
| | | X: Math.round(point.x), |
| | |
| | | EXCEPTIONS: 'application/vnd.ogc.se_inimage' |
| | | }) |
| | | AjaxUtils.get4JsonDataByUrl(WMS_URL, wmsParams, (res) => { |
| | | console.log(res) |
| | | // console.log(res) |
| | | for (let i = 0; i < res.data.features.length; i++) { |
| | | this.tableDataAffFac.push(res.data.features[i]) |
| | | } |
| | | console.log(this.tableDataAffFac) |
| | | }) |
| | | }, |
| | | // 管线搜索 |
| | |
| | | this.wfsHelper.clearFilter() |
| | | this.wfsHelper.setTypeName(['sewer:pipeline']) |
| | | if (this.form.pipeName) { |
| | | this.wfsHelper.addLike('pipename', this.form.pipeName) |
| | | this.wfsHelper.addLike('subchaname', this.form.pipeName) |
| | | } |
| | | // this.wfsHelper.addEquals('pipename', '\'' + this.form.pipeName + '\'') |
| | | const res = await AjaxUtils.GetDataAsynByUrl(this.wfsHelper.getUrl(), {}) |
| | |
| | | this.tableList = res.features |
| | | } |
| | | this.wfsHelper = new WfsHelper() |
| | | // this.form.pipeName = '' |
| | | this.form.pipeName = '' |
| | | this.form.sectionName = '' |
| | | this.form.affiliatedFacilities = '' |
| | | }, |
| | | // 点击确认 |
| | | confirm () { |
| | | // console.log('点击确定选择完成') |
| | | eventBus.$emit('section-search', true) |
| | | eventBus.$emit('location-setChange', true) |
| | | this.form.pipeName = '' |
| | | this.form.sectionName = '' |
| | | this.form.affiliatedFacilities = '' |