Merge remote-tracking branch 'origin/liujun0703-新项目开发' into liujun0703-新项目开发
commit
eb9d364645
|
@ -11,15 +11,15 @@
|
||||||
<el-row :gutter="15">
|
<el-row :gutter="15">
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="预案名称" prop="PLAN_NAME">
|
<el-form-item label="预案名称" prop="PLAN_NAME">
|
||||||
<el-input v-model="form.PLAN_NAME" placeholder="请输入资源名称..." />
|
<el-input v-model="form.PLANNAME" placeholder="请输入资源名称..." />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="预案类型" prop="PLAN_TYPE">
|
<el-form-item label="预案类型" prop="PLANTYPE">
|
||||||
<Treeselect
|
<Treeselect
|
||||||
:options="yhtypelistthree"
|
:options="yhtypelistthree"
|
||||||
:normalizer="normalizer"
|
:normalizer="normalizer"
|
||||||
v-model="form.PLAN_TYPE"
|
v-model="form.PLANTYPE"
|
||||||
placeholder="请选择预案类型"
|
placeholder="请选择预案类型"
|
||||||
no-options-text="暂无数据"
|
no-options-text="暂无数据"
|
||||||
no-children-text="暂无数据"
|
no-children-text="暂无数据"
|
||||||
|
@ -30,170 +30,68 @@
|
||||||
|
|
||||||
<el-row :gutter="15">
|
<el-row :gutter="15">
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="预案编号" prop="PLAN_NUMBER">
|
<el-form-item label="预案编码" prop="PLANCODE">
|
||||||
<el-input v-model="form.PLAN_NUMBER" placeholder="请输入资源名称..." />
|
<el-input v-model="form.PLANCODE" placeholder="请输入预案编码..." />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="预案级别" prop="PLAN_LEVEL">
|
<el-form-item label="预案等级" prop="PLANGRADE">
|
||||||
<el-input v-model="form.PLAN_LEVEL" placeholder="请输入预案类型..." />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="8">
|
|
||||||
|
|
||||||
<el-form-item label="文本信息" prop="TEXTMESSAGE">
|
|
||||||
<Treeselect
|
<Treeselect
|
||||||
:options="wenbenlistthree"
|
:options="yhPLANGRADEthree"
|
||||||
:normalizer="normalizer"
|
|
||||||
v-model="form.TEXTMESSAGE"
|
|
||||||
placeholder="请选择预文本信息"
|
|
||||||
no-options-text="暂无数据"
|
|
||||||
no-children-text="暂无数据"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
|
|
||||||
</el-col>
|
v-model="form.PLANGRADE"
|
||||||
<el-col :span="8">
|
placeholder="请选择预案类型"
|
||||||
<el-form-item label="行业类别" prop="INDUSTRY_CATEGORY">
|
|
||||||
<el-input v-model="form.INDUSTRY_CATEGORY" placeholder="请输入预案类型..." />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="编制单位" prop="COMPILING_UNIT">
|
|
||||||
<el-input v-model="form.COMPILING_UNIT" placeholder="请输入资源名称..." />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="有效时间" prop="VALIDITY_PERIOD">
|
|
||||||
<el-date-picker
|
|
||||||
v-model="form.VALIDITY_PERIOD"
|
|
||||||
type="date"
|
|
||||||
placeholder="选择日期"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="修订时间" prop="REVISION_TIME">
|
|
||||||
|
|
||||||
<el-date-picker
|
|
||||||
v-model="form.REVISION_TIME"
|
|
||||||
type="date"
|
|
||||||
placeholder="选择日期"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="发布时间" prop="PUBLICATION_TIME">
|
|
||||||
|
|
||||||
<el-date-picker
|
|
||||||
v-model="form.PUBLICATION_TIME"
|
|
||||||
type="date"
|
|
||||||
placeholder="选择日期"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="使用范围" prop="APPLICABLE_SCOPE">
|
|
||||||
<el-input v-model="form.APPLICABLE_SCOPE" placeholder="请输入资源名称..." />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="发布范围" prop="PUBLICATION_SCOPE">
|
|
||||||
<el-input v-model="form.PUBLICATION_SCOPE" placeholder="请输入预案类型..." />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="关联事件" prop="RELATED_EVENTS">
|
|
||||||
<Treeselect
|
|
||||||
:options="guanlianlistthree"
|
|
||||||
:normalizer="normalizer"
|
|
||||||
v-model="form.RELATED_EVENTS"
|
|
||||||
placeholder="请选择关联事件"
|
|
||||||
no-options-text="暂无数据"
|
no-options-text="暂无数据"
|
||||||
no-children-text="暂无数据"
|
no-children-text="暂无数据"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row :gutter="15">
|
||||||
|
<el-form-item label="事件类型" prop="PLANGRADE">
|
||||||
|
<el-checkbox-group v-model="checkList">
|
||||||
|
<el-checkbox label="1">危化品事故</el-checkbox>
|
||||||
|
<el-checkbox label="2">爆炸</el-checkbox>
|
||||||
|
<el-checkbox label="3">火灾</el-checkbox>
|
||||||
|
<el-checkbox label="4">水灾</el-checkbox>
|
||||||
|
<el-checkbox label="5">其他</el-checkbox>
|
||||||
|
</el-checkbox-group>
|
||||||
|
|
||||||
|
</el-form-item>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="15">
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="预案描述" prop="PLAN_DESCRIPTION">
|
<el-form-item :key="form.LON" label="经度" prop="LON">
|
||||||
<el-input v-model="form.PLAN_DESCRIPTION" type="textarea" placeholder="请输入预案类型..." />
|
<el-input v-model="form.LON" placeholder="请输入内容" disabled @focus="handleMap" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item :key="form.LAT" label="纬度" prop="LAT">
|
||||||
|
<div style="display: flex">
|
||||||
|
<el-input v-model="form.LAT" placeholder="请输入内容" disabled style="width: 100%" @focus="handleMap"/>
|
||||||
|
<el-button style="margin-left:10px" @click="handleMap">
|
||||||
|
<span class="svg-container">
|
||||||
|
<svg-icon icon-class="international" />
|
||||||
|
</span>
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="15">
|
||||||
|
|
||||||
|
<el-col :span="15">
|
||||||
|
<el-form-item label="预案概述" prop="PLANDES">
|
||||||
|
<el-input v-model="form.PLANDES" type="textarea" placeholder="请输入预案概述..." />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-row :gutter="15">
|
<el-row :gutter="15">
|
||||||
<el-col :span="8">
|
<el-col :span="15">
|
||||||
<el-form-item label="预案电子档">
|
<el-form-item label="备注信息" prop="BZ">
|
||||||
<el-upload
|
<el-input v-model="form.BZ" type="textarea" placeholder="备注信息..." />
|
||||||
ref="upload"
|
|
||||||
:on-change="handleDianzidangfileChange"
|
|
||||||
:on-remove="handleDianzidangfileRemove"
|
|
||||||
:auto-upload="false"
|
|
||||||
:limit="1"
|
|
||||||
action="#" >
|
|
||||||
<el-button size="small" type="primary">点击上传</el-button>
|
|
||||||
</el-upload>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="救援方案标绘图">
|
|
||||||
<el-upload
|
|
||||||
ref="upload"
|
|
||||||
:on-change="handlejiuyuanfanganfileChange"
|
|
||||||
:on-remove="handlejiuyuanfanganfileRemove"
|
|
||||||
:auto-upload="false"
|
|
||||||
:limit="1"
|
|
||||||
action="#" >
|
|
||||||
<el-button size="small" type="primary">点击上传</el-button>
|
|
||||||
</el-upload>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="平面图附件">
|
|
||||||
<el-upload
|
|
||||||
ref="upload"
|
|
||||||
:on-change="handlepingmiantufileChange"
|
|
||||||
:on-remove="handlepingmiantufileRemove"
|
|
||||||
:auto-upload="false"
|
|
||||||
:limit="1"
|
|
||||||
action="#" >
|
|
||||||
<el-button size="small" type="primary">点击上传</el-button>
|
|
||||||
</el-upload>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item label="其他附件">
|
|
||||||
<el-upload
|
|
||||||
ref="upload"
|
|
||||||
:on-change="handleotherfileChange"
|
|
||||||
:on-remove="handleotherfileRemove"
|
|
||||||
:auto-upload="false"
|
|
||||||
:limit="1"
|
|
||||||
action="#" >
|
|
||||||
<el-button size="small" type="primary">点击上传</el-button>
|
|
||||||
</el-upload>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row :gutter="15">
|
|
||||||
<el-col :span="16">
|
|
||||||
<el-form-item label="是否默认预案" prop="DEFAULT_PLAN">
|
|
||||||
<el-radio v-model="form.DEFAULT_PLAN" label="1">是</el-radio>
|
|
||||||
<el-radio v-model="form.DEFAULT_PLAN" label="0">否</el-radio>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
@ -202,57 +100,112 @@
|
||||||
|
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane v-if="PLAN_ID" label="应急专家" name="tow">
|
<el-tab-pane v-if="PLAN_ID" label="分级响应" name="tow">
|
||||||
<yingjizhuangjia :planid="PLAN_ID"/>
|
<yingjizhuangjia :planid="PLAN_ID"/>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane v-if="PLAN_ID" label="救援队伍" name="three">救援队伍</el-tab-pane>
|
<el-tab-pane v-if="PLAN_ID" label="组织结构" name="three">
|
||||||
<el-tab-pane v-if="PLAN_ID" label="组织架构" name="four">
|
<zuzhijiagou :planid="PLAN_ID"/>
|
||||||
<zuzhijiagou/>
|
</el-tab-pane>
|
||||||
|
<el-tab-pane v-if="PLAN_ID" label="预案资源" name="four">
|
||||||
|
<yvanziyuan :planid="PLAN_ID"/>
|
||||||
|
</el-tab-pane>
|
||||||
|
<el-tab-pane v-if="PLAN_ID" label="预案指令" name="five">
|
||||||
|
<yvanziling :planid="PLAN_ID" />
|
||||||
|
</el-tab-pane>
|
||||||
|
<el-tab-pane v-if="PLAN_ID" label="预案文本" name="six">
|
||||||
|
<yvanwenben :planid="PLAN_ID" :plan-name="planName" />
|
||||||
|
</el-tab-pane>
|
||||||
|
<el-tab-pane v-if="PLAN_ID" label="预案附件" name="seven">
|
||||||
|
<yvanfujian :planid="PLAN_ID" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="ui-height" />
|
<div class="ui-height" />
|
||||||
<div class="ui-foot">
|
<div class="ui-foot">
|
||||||
<el-button type="primary" @click="goback">返回</el-button>
|
<el-button v-if="activeName === 'first'" type="primary" @click="goback">返回</el-button>
|
||||||
<el-button v-if="activeName != 'four'" type="primary" @click="confirm(0)">保存</el-button>
|
<el-button v-if="activeName === 'first'" type="primary" @click="confirm(0)">保存</el-button>
|
||||||
<el-button v-if="activeName != 'four'" type="primary" @click="gotoxiayibu(1)" >保存并进入下一步</el-button>
|
<el-button v-if="activeName === 'first'" type="primary" @click="gotoxiayibu(1)" >保存并进入下一步</el-button>
|
||||||
|
|
||||||
|
<el-button v-if="activeName !== 'first'" type="primary" @click="shiyibu(0)">上一步</el-button>
|
||||||
|
<el-button v-if="activeName !== 'first'" type="primary" @click="xiayibu(1)" >下一步</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- 坐标选择 -->
|
||||||
|
<el-dialog :visible.sync="dialogFormMap" title="编辑坐标" width="800px" class="dy-dialog">
|
||||||
|
<baidu-map
|
||||||
|
v-ISLOADing="ISLOADingMap"
|
||||||
|
:zoom="zoom"
|
||||||
|
:scroll-wheel-zoom="true"
|
||||||
|
:style="{height: clientHeight+'px'}"
|
||||||
|
@click="getClickInfo"
|
||||||
|
@ready="handler">
|
||||||
|
<bm-view style="width: 100%; height:100%; flex: 1" />
|
||||||
|
<bm-control ref="control" :offset="{width: 10, height: 10}" anchor="BMAP_ANCHOR_TOP_LEFT">
|
||||||
|
<div class="map-flex">
|
||||||
|
|
||||||
|
<div class="map-lable">关键词:</div>
|
||||||
|
<div style="flex:1;">
|
||||||
|
<el-autocomplete v-model="TYPEKeyword" :fetch-suggestions="querySearch" :trigger-on-focus="false" placeholder="请输入详细设备类型" style="width:100%" @select="handleSelect" />
|
||||||
|
</div>
|
||||||
|
<!-- <el-input v-model="TYPEKeyword" style="width: 200px" placeholder="请输入内容" />-->
|
||||||
|
<!-- <el-button slot="append" icon="el-icon-search" @click="mapNameChange"/>-->
|
||||||
|
</div>
|
||||||
|
</bm-control>
|
||||||
|
<!-- <bm-local-search :keyword="TYPEKeyword" :auto-viewport="true"/>-->
|
||||||
|
</baidu-map>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<span>经度:</span>
|
||||||
|
<el-input v-model="LON" style="width: 200px" placeholder="请输入内容" disabled />
|
||||||
|
<span>纬度:</span>
|
||||||
|
<el-input v-model="LAT" style="width: 200px" placeholder="请输入内容" disabled />
|
||||||
|
<el-button @click="dialogFormMap = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="setPosition">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { requestFN } from '@/utils/request'
|
import { requestFN } from '@/utils/request'
|
||||||
import { upload } from '@/utils/upload'
|
|
||||||
import { Treeselect } from '@riophae/vue-treeselect'
|
import { Treeselect } from '@riophae/vue-treeselect'
|
||||||
|
|
||||||
import yingjizhuangjia from './yingjizhuangjia.vue'
|
import yingjizhuangjia from './yingjizhuangjia.vue'
|
||||||
import zuzhijiagou from './zuzhijiagou.vue'
|
import zuzhijiagou from './zuzhijiagou.vue'
|
||||||
|
import yvanziyuan from './yvanziyuan.vue'
|
||||||
|
import yvanziling from './yvanziling.vue'
|
||||||
|
import yvanwenben from './yvanwenben.vue'
|
||||||
|
import yvanfujian from './yvanfujian.vue'
|
||||||
export default {
|
export default {
|
||||||
components: { Treeselect, yingjizhuangjia, zuzhijiagou },
|
components: { Treeselect, yingjizhuangjia, zuzhijiagou, yvanziyuan, yvanziling, yvanwenben, yvanfujian },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
// 地图相关
|
||||||
// 附件上传电子档
|
CORPINFO_ID: this.$parent.CORPINFO_ID,
|
||||||
dianzidangfile: [],
|
clientHeight: 600,
|
||||||
// 救援方案标绘图
|
ISLOADingMap: true,
|
||||||
jiuyuanfanganfile: [],
|
listISLOADing: false,
|
||||||
// 平面图附件
|
buttonISLOADing: false,
|
||||||
pingmiantufile: [],
|
BMap: '',
|
||||||
// 其他附件
|
map: '',
|
||||||
otherfile: [],
|
showMap: false,
|
||||||
// 所有图片
|
TYPEKeyword: '',
|
||||||
allfiletype: [],
|
pointLngLat: '',
|
||||||
|
zoom: 10,
|
||||||
|
dialogFormMap: false,
|
||||||
|
LAT: '',
|
||||||
|
LON: '',
|
||||||
|
// 复选框
|
||||||
|
checkList: [],
|
||||||
|
|
||||||
form: {
|
form: {
|
||||||
|
LAT: '',
|
||||||
|
LON: ''
|
||||||
},
|
},
|
||||||
activeName: 'first',
|
activeName: 'first',
|
||||||
// 预案类型
|
// 预案类型
|
||||||
yhtypelistthree: [],
|
yhtypelistthree: [],
|
||||||
wenbenlistthree: [],
|
|
||||||
guanlianlistthree: [],
|
|
||||||
normalizer(node) {
|
normalizer(node) {
|
||||||
return {
|
return {
|
||||||
id: node.DICTIONARIES_ID,
|
id: node.DICTIONARIES_ID,
|
||||||
|
@ -260,8 +213,13 @@ export default {
|
||||||
children: node.nodes
|
children: node.nodes
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
listISLOADing: false,
|
// 预案等级
|
||||||
PLAN_ID: ''
|
yhPLANGRADEthree: [
|
||||||
|
{ id: 1, label: '一级预案' },
|
||||||
|
{ id: 2, label: '二级预案' }
|
||||||
|
],
|
||||||
|
PLAN_ID: '',
|
||||||
|
planName: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -271,10 +229,128 @@ export default {
|
||||||
this.getDetail(this.PLAN_ID)
|
this.getDetail(this.PLAN_ID)
|
||||||
}
|
}
|
||||||
this.getYaTypeDataList()
|
this.getYaTypeDataList()
|
||||||
this.getwenbenDataList()
|
|
||||||
this.getguanlianataList()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
//* **************地图相关*****************
|
||||||
|
// 地图相关
|
||||||
|
mapOpen() {
|
||||||
|
this.top = this.getScrollTop()
|
||||||
|
if (this.top) {
|
||||||
|
this.setScrollTop(0)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 关闭地图后调用
|
||||||
|
mapClose() {
|
||||||
|
this.setScrollTop(this.top)
|
||||||
|
this.top = 0
|
||||||
|
this.showMap = false
|
||||||
|
},
|
||||||
|
getScrollTop() {
|
||||||
|
let scrollTop = 0
|
||||||
|
if (document.documentElement && document.documentElement.scrollTop) {
|
||||||
|
scrollTop = document.documentElement.scrollTop
|
||||||
|
} else if (document.body) {
|
||||||
|
scrollTop = document.body.scrollTop
|
||||||
|
}
|
||||||
|
return scrollTop
|
||||||
|
},
|
||||||
|
setScrollTop(top) {
|
||||||
|
if (!isNaN(top)) {
|
||||||
|
if (document.documentElement && document.documentElement.scrollTop !== undefined) {
|
||||||
|
document.documentElement.scrollTop = top
|
||||||
|
} else if (document.body) {
|
||||||
|
document.body.scrollTop = top
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 地图初始化
|
||||||
|
handler({ BMap, map }) {
|
||||||
|
this.mapOpen()
|
||||||
|
this.BMap = BMap
|
||||||
|
this.map = map
|
||||||
|
this.ISLOADingMap = true
|
||||||
|
var geolocation = new BMap.Geolocation()
|
||||||
|
const myGeo = new BMap.Geocoder()
|
||||||
|
var $this = this
|
||||||
|
// 调用百度地图api 中的获取当前位置接口
|
||||||
|
geolocation.getCurrentPosition(function(r) {
|
||||||
|
myGeo.getLocation(new BMap.Point(r.point.lng, r.point.lat), function(result) {
|
||||||
|
if (result) {
|
||||||
|
$this.ISLOADingMap = false
|
||||||
|
$this.$set($this, 'pointLngLat', { lng: result.point.lng, lat: result.point.lat })
|
||||||
|
map.enableScrollWheelZoom(true) // 开启鼠标滚轮缩放,默认关闭
|
||||||
|
$this.setCenter({ BMap, map })
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 搜索地图
|
||||||
|
querySearch(queryString, cb) {
|
||||||
|
var options = {
|
||||||
|
onSearchComplete: function(results) {
|
||||||
|
if (local.getStatus() === 0) {
|
||||||
|
// 判断状态是否正确
|
||||||
|
var s = []
|
||||||
|
for (var i = 0; i < results.getCurrentNumPois(); i++) {
|
||||||
|
var x = results.getPoi(i)
|
||||||
|
var item = { value: x.TYPE + x.title, point: x.point }
|
||||||
|
s.push(item)
|
||||||
|
cb(s)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
cb()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var local = new this.BMap.LocalSearch(this.map, options)
|
||||||
|
local.search(queryString)
|
||||||
|
},
|
||||||
|
handleSelect(item) {
|
||||||
|
var { point } = item
|
||||||
|
this.map.clearOverlays() // 清除地图上所有覆盖物
|
||||||
|
this.map.centerAndZoom(point, this.zoom)
|
||||||
|
const marker = new this.BMap.Marker(point) // 创建标注
|
||||||
|
this.map.addOverlay(marker) // 将标注添加到地图中
|
||||||
|
marker.enableDragging() // 可拖拽
|
||||||
|
this.LON = point.lng
|
||||||
|
this.LAT = point.lat
|
||||||
|
},
|
||||||
|
// 设置打开中心位置
|
||||||
|
setCenter({ BMap, map }) {
|
||||||
|
var lng = ''
|
||||||
|
var lat = ''
|
||||||
|
if (this.form.LON == '' || this.form.LAT == '') {
|
||||||
|
lng = '119.525971'
|
||||||
|
lat = '39.894727'
|
||||||
|
} else {
|
||||||
|
lng = this.form.LON
|
||||||
|
lat = this.form.LAT
|
||||||
|
}
|
||||||
|
var point = new BMap.Point(lng, lat)
|
||||||
|
// var point = new BMap.Point(this.form.LON, this.form.LAT)
|
||||||
|
const zoom = map.getZoom()
|
||||||
|
setTimeout(() => {
|
||||||
|
map.centerAndZoom(point, zoom)
|
||||||
|
}, 0)
|
||||||
|
// var marker = new BMap.Marker(point) // 创建标注
|
||||||
|
// map.addOverlay(marker) // 将标注添加到地图中
|
||||||
|
},
|
||||||
|
handleMap() {
|
||||||
|
this.dialogFormMap = true
|
||||||
|
this.LAT = this.form.LAT
|
||||||
|
this.LON = this.form.LON
|
||||||
|
},
|
||||||
|
getClickInfo(e) {
|
||||||
|
this.LON = e.point.lng
|
||||||
|
this.LAT = e.point.lat
|
||||||
|
},
|
||||||
|
setPosition() {
|
||||||
|
this.dialogFormMap = false
|
||||||
|
this.form.LAT = this.LAT
|
||||||
|
this.form.LON = this.LON
|
||||||
|
},
|
||||||
|
//* ***********************************
|
||||||
|
|
||||||
getDetail(id) {
|
getDetail(id) {
|
||||||
const params = {
|
const params = {
|
||||||
Id: id
|
Id: id
|
||||||
|
@ -282,40 +358,33 @@ export default {
|
||||||
requestFN('/major/emergencyplan/detail', params).then((response) => {
|
requestFN('/major/emergencyplan/detail', params).then((response) => {
|
||||||
const data = response.data
|
const data = response.data
|
||||||
console.log(data)
|
console.log(data)
|
||||||
|
this.planName = data.PLANNAME
|
||||||
this.form = {
|
this.form = {
|
||||||
|
|
||||||
PLAN_TYPE: data.PLAN_TYPE,
|
FIRERESERVEPLAN_ID: data.FIRERESERVEPLAN_ID,
|
||||||
|
|
||||||
PLAN_NUMBER: data.PLAN_NUMBER,
|
PLANNAME: data.PLANNAME,
|
||||||
|
|
||||||
PLAN_LEVEL: data.PLAN_LEVEL,
|
PLANDES: data.PLANDES,
|
||||||
|
|
||||||
PLAN_NAME: data.PLAN_NAME,
|
PLANTYPE: data.PLANTYPE,
|
||||||
|
|
||||||
PLAN_CATEGORY: data.PLAN_CATEGORY,
|
KEYPLACES_ID: data.KEYPLACES_ID,
|
||||||
|
|
||||||
INDUSTRY_CATEGORY: data.INDUSTRY_CATEGORY,
|
BZ: data.BZ,
|
||||||
|
|
||||||
COMPILING_UNIT: data.COMPILING_UNIT,
|
LON: data.LON,
|
||||||
|
|
||||||
VALIDITY_PERIOD: data.VALIDITY_PERIOD,
|
LAT: data.LAT,
|
||||||
|
|
||||||
REVISION_TIME: data.REVISION_TIME,
|
EVENTTYPE: data.EVENTTYPE,
|
||||||
|
|
||||||
PUBLICATION_TIME: data.PUBLICATION_TIME,
|
PLANCODE: data.PLANCODE,
|
||||||
|
|
||||||
TEXTMESSAGE: data.TEXTMESSAGE,
|
PLANGRADE: data.PLANGRADE
|
||||||
|
|
||||||
APPLICABLE_SCOPE: data.APPLICABLE_SCOPE,
|
|
||||||
PUBLICATION_SCOPE: data.PUBLICATION_SCOPE,
|
|
||||||
PLAN_DESCRIPTION: data.PLAN_DESCRIPTION,
|
|
||||||
|
|
||||||
RELATED_EVENTS: data.RELATED_EVENTS,
|
|
||||||
DEFAULT_PLAN: data.DEFAULT_PLAN,
|
|
||||||
|
|
||||||
ID: data.ID
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
this.checkList = data.EVENTTYPE.split(',')
|
||||||
}).catch((e) => {
|
}).catch((e) => {
|
||||||
console.error('获取详情数据失败', e)
|
console.error('获取详情数据失败', e)
|
||||||
})
|
})
|
||||||
|
@ -332,98 +401,20 @@ export default {
|
||||||
console.error('获取树形数据失败', e)
|
console.error('获取树形数据失败', e)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 预案类型
|
|
||||||
getwenbenDataList() {
|
|
||||||
const params = {
|
|
||||||
PARENT_ID: 'cfae32d9abd84509a27a1be780860857'
|
|
||||||
}
|
|
||||||
requestFN('/dictionaries/listTree', params).then((data) => {
|
|
||||||
this.wenbenlistthree = JSON.parse(data.zTreeNodes)
|
|
||||||
}).catch((e) => {
|
|
||||||
console.error('获取树形数据失败', e)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 关联事件
|
|
||||||
getguanlianataList() {
|
|
||||||
const params = {
|
|
||||||
PARENT_ID: '736977eb73e743a38830b053b283c1d0'
|
|
||||||
}
|
|
||||||
requestFN('/dictionaries/listTree', params).then((data) => {
|
|
||||||
this.guanlianlistthree = JSON.parse(data.zTreeNodes)
|
|
||||||
}).catch((e) => {
|
|
||||||
console.error('获取树形数据失败', e)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// **********************文件上传*********************
|
|
||||||
handleDianzidangfileChange(file) {
|
|
||||||
this.dianzidangfile.push(file)
|
|
||||||
},
|
|
||||||
handleDianzidangfileRemove(file, fileList) {
|
|
||||||
this.dianzidangfile = fileList
|
|
||||||
},
|
|
||||||
handlejiuyuanfanganfileChange(file) {
|
|
||||||
this.jiuyuanfanganfile.push(file)
|
|
||||||
},
|
|
||||||
handlejiuyuanfanganfileRemove(file, fileList) {
|
|
||||||
this.jiuyuanfanganfile = fileList
|
|
||||||
},
|
|
||||||
handlepingmiantufileChange(file) {
|
|
||||||
this.pingmiantufile.push(file)
|
|
||||||
},
|
|
||||||
handlepingmiantufileRemove(file, fileList) {
|
|
||||||
this.pingmiantufile = fileList
|
|
||||||
},
|
|
||||||
handleotherfileChange(file) {
|
|
||||||
this.otherfile.push(file)
|
|
||||||
},
|
|
||||||
handleotherfileRemove(file, fileList) {
|
|
||||||
this.otherfile = fileList
|
|
||||||
},
|
|
||||||
upload(fun) {
|
|
||||||
const formData = new FormData()
|
|
||||||
|
|
||||||
for (let i = 0; i < this.dianzidangfile.length; i++) {
|
|
||||||
if (this.dianzidangfile[i].raw) {
|
|
||||||
this.allfiletype.push('1')
|
|
||||||
formData.append('FFILE', this.dianzidangfile[i].raw)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (let i = 0; i < this.jiuyuanfanganfile.length; i++) {
|
|
||||||
if (this.jiuyuanfanganfile[i].raw) {
|
|
||||||
this.allfiletype.push('2')
|
|
||||||
formData.append('FFILE', this.jiuyuanfanganfile[i].raw)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (let i = 0; i < this.pingmiantufile.length; i++) {
|
|
||||||
if (this.pingmiantufile[i].raw) {
|
|
||||||
this.allfiletype.push('3')
|
|
||||||
formData.append('FFILE', this.pingmiantufile[i].raw)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (let i = 0; i < this.otherfile.length; i++) {
|
|
||||||
if (this.otherfile[i].raw) {
|
|
||||||
this.allfiletype.push('4')
|
|
||||||
formData.append('FFILE', this.otherfile[i].raw)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
upload(
|
|
||||||
'/file/upload2',
|
|
||||||
formData
|
|
||||||
).then((data) => {
|
|
||||||
fun(data.fileurl)
|
|
||||||
}).catch((e) => {
|
|
||||||
})
|
|
||||||
},
|
|
||||||
saveData(type) {
|
saveData(type) {
|
||||||
this.listISLOADing = true
|
this.listISLOADing = true
|
||||||
if (this.PLAN_ID) {
|
if (this.PLAN_ID) {
|
||||||
this.form.Id = this.PLAN_ID
|
this.form.FIRERESERVEPLAN_ID = this.PLAN_ID
|
||||||
}
|
}
|
||||||
|
this.planName = this.form.PLANNAME
|
||||||
|
this.form.EVENTTYPE = this.checkList.join(',')
|
||||||
requestFN(
|
requestFN(
|
||||||
'/major/emergencyplan/save', this.form
|
'/major/emergencyplan/save', this.form
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
this.listISLOADing = false
|
this.listISLOADing = false
|
||||||
this.PLAN_ID = data.data.id
|
|
||||||
|
this.PLAN_ID = data.data
|
||||||
this.activeName = 'tow'
|
this.activeName = 'tow'
|
||||||
if (type === 0) {
|
if (type === 0) {
|
||||||
this.$parent.activeName = 'list'
|
this.$parent.activeName = 'list'
|
||||||
|
@ -434,15 +425,7 @@ export default {
|
||||||
this.listISLOADing = false
|
this.listISLOADing = false
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 判断是否有文件上传
|
|
||||||
judgefileupload() {
|
|
||||||
const num = this.dianzidangfile.length + this.jiuyuanfanganfile.length + this.pingmiantufile.length + this.otherfile.length
|
|
||||||
if (num > 0) {
|
|
||||||
return true
|
|
||||||
} else {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
gotoxiayibu(type) {
|
gotoxiayibu(type) {
|
||||||
if (this.activeName === 'tow') {
|
if (this.activeName === 'tow') {
|
||||||
this.activeName = 'three'
|
this.activeName = 'three'
|
||||||
|
@ -456,30 +439,7 @@ export default {
|
||||||
confirm(type) {
|
confirm(type) {
|
||||||
this.$refs.form.validate(valid => {
|
this.$refs.form.validate(valid => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
if (this.judgefileupload()) {
|
|
||||||
this.upload((v) => {
|
|
||||||
// 整理上传文件
|
|
||||||
const url = v.split(',')
|
|
||||||
for (let i = 0; i < this.allfiletype.length; i++) {
|
|
||||||
if (this.allfiletype[i] === '1') {
|
|
||||||
this.form.PLAN_ELECTRONIC_FILE = url[i]
|
|
||||||
}
|
|
||||||
if (this.allfiletype[i] === '2') {
|
|
||||||
this.form.RESCUE_PLAN_DRAWING = url[i]
|
|
||||||
}
|
|
||||||
if (this.allfiletype[i] === '3') {
|
|
||||||
this.form.FLOOR_PLAN_ATTACHMENT = url[i]
|
|
||||||
}
|
|
||||||
if (this.allfiletype[i] === '4') {
|
|
||||||
this.form.OTHER_ATTACHMENTS = url[i]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.$refs.upload.clearFiles()
|
|
||||||
this.saveData(type)
|
this.saveData(type)
|
||||||
})
|
|
||||||
} else {
|
|
||||||
this.saveData(type)
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
@ -487,12 +447,43 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
handleClick(tab, event) {
|
handleClick(tab, event) {
|
||||||
|
|
||||||
/* if (tab.index == 1) {
|
/* if (tab.index == 1) {
|
||||||
|
|
||||||
} else if (tab.index == 2) {
|
} else if (tab.index == 2) {
|
||||||
|
|
||||||
}*/
|
}*/
|
||||||
},
|
},
|
||||||
|
shiyibu() {
|
||||||
|
if (this.activeName === 'tow') {
|
||||||
|
this.activeName = 'first'
|
||||||
|
} else if (this.activeName === 'three') {
|
||||||
|
this.activeName = 'tow'
|
||||||
|
} else if (this.activeName === 'four') {
|
||||||
|
this.activeName = 'three'
|
||||||
|
} else if (this.activeName === 'five') {
|
||||||
|
this.activeName = 'four'
|
||||||
|
} else if (this.activeName === 'six') {
|
||||||
|
this.activeName = 'five'
|
||||||
|
} else if (this.activeName === 'seven') {
|
||||||
|
this.activeName = 'six'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
xiayibu() {
|
||||||
|
if (this.activeName === 'first') {
|
||||||
|
this.activeName = 'tow'
|
||||||
|
} else if (this.activeName === 'tow') {
|
||||||
|
this.activeName = 'three'
|
||||||
|
} else if (this.activeName === 'three') {
|
||||||
|
this.activeName = 'four'
|
||||||
|
} else if (this.activeName === 'four') {
|
||||||
|
this.activeName = 'five'
|
||||||
|
} else if (this.activeName === 'five') {
|
||||||
|
this.activeName = 'six'
|
||||||
|
} else if (this.activeName === 'six') {
|
||||||
|
this.activeName = 'seven'
|
||||||
|
}
|
||||||
|
},
|
||||||
goback() {
|
goback() {
|
||||||
this.$parent.activeName = 'list'
|
this.$parent.activeName = 'list'
|
||||||
this.$parent.huidiao()
|
this.$parent.huidiao()
|
||||||
|
|
|
@ -1,192 +0,0 @@
|
||||||
|
|
||||||
<template>
|
|
||||||
<div>
|
|
||||||
<div class="filter-container">
|
|
||||||
<el-button class="filter-item" type="primary" @click="yjzjadd">
|
|
||||||
添加
|
|
||||||
</el-button>
|
|
||||||
</div>
|
|
||||||
<el-table ref="multipleTable" :data="yjzjvarList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
|
||||||
|
|
||||||
<el-table-column prop="EXPERT_NAME" label="名称" width="180" />
|
|
||||||
<el-table-column prop="EXPERT_CATEGORY" label="专家类型" />
|
|
||||||
<el-table-column prop="OFFICE_PHONE" label="办公电话" />
|
|
||||||
<el-table-column prop="MOBILE_PHONE" label="移动电话" />
|
|
||||||
<el-table-column label="操作" align="center" width="300">
|
|
||||||
<template slot-scope="{row}">
|
|
||||||
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deletezhuangjiaPeople(row)">移除该救援队伍</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<el-dialog :visible.sync="dialogzhuangjiaShow" title="选择人员" width="850px" @close="closeDialog('ruleForm')">
|
|
||||||
<el-container>
|
|
||||||
<el-main>
|
|
||||||
<div class="filter-btn-group">
|
|
||||||
<el-form label-width="100px">
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="10">
|
|
||||||
<el-form-item label="姓名">
|
|
||||||
<el-input v-model="zhuangjianame" placeholder="搜索姓名"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="10">
|
|
||||||
<el-form-item label-width="10px">
|
|
||||||
<el-button class="filter-item" type="primary" icon="el-icon-search" @click="getzhuanjiaList">
|
|
||||||
搜索
|
|
||||||
</el-button>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
|
|
||||||
</el-row>
|
|
||||||
</el-form>
|
|
||||||
</div>
|
|
||||||
<el-table ref="multipleTable" :data="zhuanjiaList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" style="height:350px" tooltip-effect="dark" border fit highlight-current-row>
|
|
||||||
<!-- <el-table-column type="selection" width="55" align="center" />-->
|
|
||||||
<el-table-column prop="EXPERT_NAME" label="姓名" />
|
|
||||||
<el-table-column prop="MOBILE_TELEPHONE" label="移动电话" />
|
|
||||||
<el-table-column prop="OFFICE_TELEPHONE" label="办公电话" />
|
|
||||||
<el-table-column label="操作" align="center" width="300">
|
|
||||||
<template slot-scope="{row}">
|
|
||||||
<el-button type="primary" icon="el-icon-plus" size="mini" @click="savezhuangjiaPeople(row)">添加到救援队伍</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<div class="page-btn-group">
|
|
||||||
<div />
|
|
||||||
<Pagination :total="zhuangjiatotal" :page.sync="listQueryzj.page" :limit.sync="listQueryzj.limit" @pagination="getzhuanjiaList" />
|
|
||||||
</div>
|
|
||||||
</el-main>
|
|
||||||
</el-container>
|
|
||||||
</el-dialog>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</template>
|
|
||||||
<script>
|
|
||||||
import { requestFN } from '@/utils/request'
|
|
||||||
import Pagination from '@/components/Pagination'
|
|
||||||
export default {
|
|
||||||
name: 'Yingjizhuangjia',
|
|
||||||
components: { Pagination },
|
|
||||||
props: {
|
|
||||||
planid: {
|
|
||||||
type: String,
|
|
||||||
default() {
|
|
||||||
return ''
|
|
||||||
} }
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
zhuangjiatotal: 0,
|
|
||||||
zhuangjianame: '',
|
|
||||||
dialogzhuangjiaShow: false,
|
|
||||||
yjzjvarList: [],
|
|
||||||
yjzhuangjiatotal: [],
|
|
||||||
zhuanjiaList: [],
|
|
||||||
listQueryzj: {
|
|
||||||
page: 1,
|
|
||||||
limit: 20
|
|
||||||
},
|
|
||||||
zhuangjiafrom: {
|
|
||||||
|
|
||||||
},
|
|
||||||
listISLOADing: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
created() {
|
|
||||||
console.log(this.planid)
|
|
||||||
this.getPlanexpertList()
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
closeDialog() {
|
|
||||||
this.dialogzhuangjiaShow = false
|
|
||||||
},
|
|
||||||
deletezhuangjiaPeople(row) {
|
|
||||||
this.listISLOADing = true
|
|
||||||
requestFN(
|
|
||||||
'/major/association/delete', { id: row.ID }
|
|
||||||
).then((data) => {
|
|
||||||
this.$message({
|
|
||||||
message: '移除成功',
|
|
||||||
type: 'success'
|
|
||||||
})
|
|
||||||
|
|
||||||
this.listISLOADing = false
|
|
||||||
this.getPlanexpertList()
|
|
||||||
}).catch((e) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
})
|
|
||||||
},
|
|
||||||
savezhuangjiaPeople(row) {
|
|
||||||
this.zhuangjiafrom.PLAN_ID = this.planid
|
|
||||||
this.zhuangjiafrom.TYPE = '1'
|
|
||||||
this.zhuangjiafrom.REL_ID = row.EXPERT_ID
|
|
||||||
this.zhuangjiafrom.EXPERT_NAME = row.EXPERT_NAME
|
|
||||||
this.zhuangjiafrom.EXPERT_CATEGORY = row.EXPERT_TYPE
|
|
||||||
this.zhuangjiafrom.OFFICE_PHONE = row.OFFICE_TELEPHONE
|
|
||||||
this.zhuangjiafrom.MOBILE_PHONE = row.MOBILE_TELEPHONE
|
|
||||||
|
|
||||||
this.listISLOADing = true
|
|
||||||
requestFN(
|
|
||||||
'/major/association/save', this.zhuangjiafrom
|
|
||||||
).then((data) => {
|
|
||||||
this.$message({
|
|
||||||
message: '添加成功',
|
|
||||||
type: 'success'
|
|
||||||
})
|
|
||||||
|
|
||||||
this.listISLOADing = false
|
|
||||||
this.getPlanexpertList()
|
|
||||||
this.getzhuanjiaList()
|
|
||||||
}).catch((e) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
})
|
|
||||||
},
|
|
||||||
yjzjadd() {
|
|
||||||
this.dialogzhuangjiaShow = true
|
|
||||||
this.getzhuanjiaList()
|
|
||||||
},
|
|
||||||
getzhuanjiaList() {
|
|
||||||
this.listISLOADing = true
|
|
||||||
requestFN(
|
|
||||||
'/yjexpert/getRelevanceNotPlanList?showCount=' + this.listQueryzj.limit + '¤tPage=' + this.listQueryzj.page,
|
|
||||||
{
|
|
||||||
name: this.KEYWORDS,
|
|
||||||
id: this.planid,
|
|
||||||
type: '1'
|
|
||||||
}
|
|
||||||
).then((data) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
this.zhuanjiaList = data.varList
|
|
||||||
this.zhuangjiatotal = data.page.totalResult
|
|
||||||
})
|
|
||||||
.catch((e) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 获取预案关联专家
|
|
||||||
getPlanexpertList() {
|
|
||||||
this.listISLOADing = true
|
|
||||||
requestFN(
|
|
||||||
'/major/association/list?showCount=50' + '¤tPage=1',
|
|
||||||
{
|
|
||||||
name: this.KEYWORDS,
|
|
||||||
PLAN_ID: this.planid,
|
|
||||||
TYPE: '1'
|
|
||||||
}
|
|
||||||
).then((data) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
this.yjzjvarList = data.varList
|
|
||||||
this.yjzhuangjiatotal = data.page.totalResult
|
|
||||||
})
|
|
||||||
.catch((e) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss">
|
|
||||||
</style>
|
|
||||||
|
|
|
@ -9,15 +9,15 @@
|
||||||
<el-table ref="multipleTable" :data="varList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
<el-table ref="multipleTable" :data="varList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||||
<el-table-column type="selection" width="55" align="center" />
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||||
<el-table-column prop="PLAN_NAME" label="预案名称" width="180" />
|
<el-table-column prop="PLANNAME" label="预案名称" width="180" />
|
||||||
<el-table-column prop="PLAN_LEVEL" label="预案类别" show-overflow-tooltip="true" />
|
<el-table-column prop="PLANCODE" label="预案编码" show-overflow-tooltip="true" />
|
||||||
<el-table-column prop="PLAN_DESCRIPTION" label="预案概述" show-overflow-tooltip="true" />
|
<el-table-column prop="PLANDES" label="预案概述" show-overflow-tooltip="true" />
|
||||||
|
|
||||||
<el-table-column label="操作" align="center" width="300">
|
<el-table-column label="操作" align="center" width="300">
|
||||||
<template slot-scope="{row}">
|
<template slot-scope="{row}">
|
||||||
<!-- <el-button type="primary" icon="el-icon-document" size="mini" @click="goList('detail', row.ID, '1')">查看</el-button>-->
|
<!-- <el-button type="primary" icon="el-icon-document" size="mini" @click="goList('detail', row.FIRERESERVEPLAN_ID, '1')">查看</el-button>-->
|
||||||
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row.ID)">编辑</el-button>
|
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row.FIRERESERVEPLAN_ID)">编辑</el-button>
|
||||||
<el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.ID,row.PLAN_NAME)">删除</el-button>
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.FIRERESERVEPLAN_ID,row.PLANNAME)">删除</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
@ -37,30 +37,12 @@
|
||||||
<script>
|
<script>
|
||||||
import Pagination from '@/components/Pagination'
|
import Pagination from '@/components/Pagination'
|
||||||
import { requestFN } from '@/utils/request'
|
import { requestFN } from '@/utils/request'
|
||||||
import { Treeselect } from '@riophae/vue-treeselect'
|
|
||||||
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
|
|
||||||
import { upload } from '@/utils/upload'
|
|
||||||
export default {
|
export default {
|
||||||
components: { Treeselect, Pagination },
|
components: { Pagination },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
||||||
// 地图相关
|
|
||||||
CORPINFO_ID: this.$parent.CORPINFO_ID,
|
|
||||||
clientHeight: 600,
|
|
||||||
ISLOADingMap: true,
|
|
||||||
listISLOADing: false,
|
|
||||||
buttonISLOADing: false,
|
|
||||||
BMap: '',
|
|
||||||
map: '',
|
|
||||||
showMap: false,
|
|
||||||
TYPEKeyword: '',
|
|
||||||
pointLngLat: '',
|
|
||||||
zoom: 10,
|
|
||||||
dialogFormMap: false,
|
|
||||||
LATITUDE: '',
|
|
||||||
LONGITUDE: '',
|
|
||||||
|
|
||||||
listQuery: {
|
listQuery: {
|
||||||
page: 1,
|
page: 1,
|
||||||
limit: 10
|
limit: 10
|
||||||
|
@ -70,233 +52,15 @@ export default {
|
||||||
KEYWORDS: '',
|
KEYWORDS: '',
|
||||||
dialogFormEdit: false,
|
dialogFormEdit: false,
|
||||||
dialogFormShow: false,
|
dialogFormShow: false,
|
||||||
dialogType: 'add',
|
dialogType: 'add'
|
||||||
form: {
|
|
||||||
// 名称
|
|
||||||
EQUIP_NAME: '',
|
|
||||||
// 设备类型
|
|
||||||
TYPE: '',
|
|
||||||
|
|
||||||
// 经度
|
|
||||||
LONGITUDE: '',
|
|
||||||
// 纬度
|
|
||||||
LATITUDE: '',
|
|
||||||
|
|
||||||
// 负责保管人
|
|
||||||
CONTACT_PERSON: '',
|
|
||||||
|
|
||||||
// 负责保管人固定电话
|
|
||||||
CONTACT_TELE_PHONE: '',
|
|
||||||
|
|
||||||
// 负责保管人移动电话
|
|
||||||
CONTACT_MOBILE_PHONE: '',
|
|
||||||
|
|
||||||
// 详情地址
|
|
||||||
ADDRESS: '',
|
|
||||||
// 企业名称
|
|
||||||
COMPANY: '',
|
|
||||||
// 所属区域
|
|
||||||
REGION: '',
|
|
||||||
// 所属单位
|
|
||||||
AFFILIATEDUNIT: ''
|
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
yjrescueEquipData: [],
|
|
||||||
treeData: [],
|
|
||||||
DepartmentData: [],
|
|
||||||
normalizer(node) {
|
|
||||||
return {
|
|
||||||
id: node.DICTIONARIES_ID,
|
|
||||||
label: node.name,
|
|
||||||
children: node.nodes
|
|
||||||
}
|
|
||||||
},
|
|
||||||
FFILE: []
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.getyjrescueEquipDataList()
|
|
||||||
this.getDepartmentList()
|
|
||||||
this.getTreeList()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
// **********************文件上传*********************
|
|
||||||
handleEditChange(file) {
|
|
||||||
file.MATERIALS_ID = Math.random()
|
|
||||||
const is5M = file.size / 1024 / 1024 < 5
|
|
||||||
if (is5M) this.FFILE.push(file)
|
|
||||||
},
|
|
||||||
handleRemove(file, fileList) {
|
|
||||||
this.FFILE = fileList
|
|
||||||
},
|
|
||||||
upload(fun) {
|
|
||||||
const formData = new FormData()
|
|
||||||
|
|
||||||
for (let i = 0; i < this.FFILE.length; i++) {
|
|
||||||
if (this.FFILE[i].raw) {
|
|
||||||
formData.append('FFILE', this.FFILE[i].raw)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
upload(
|
|
||||||
'/file/upload',
|
|
||||||
formData
|
|
||||||
).then((data) => {
|
|
||||||
fun(data.fileurl)
|
|
||||||
}).catch((e) => {
|
|
||||||
})
|
|
||||||
},
|
|
||||||
//* ****************************************
|
|
||||||
getDepartmentList() {
|
|
||||||
requestFN('/department/listAll').then((data) => {
|
|
||||||
this.DepartmentData = data.list.map(item => ({
|
|
||||||
id: item.department_ID,
|
|
||||||
label: item.name
|
|
||||||
}))
|
|
||||||
}).catch((e) => {
|
|
||||||
console.error('获取主管单位数据失败', e)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
getTreeList() {
|
|
||||||
const params = {
|
|
||||||
PARENT_ID: '5a5d2809ed644aa6ba97a5240ff35484'
|
|
||||||
}
|
|
||||||
requestFN('/dictionaries/listTree', params).then((data) => {
|
|
||||||
this.treeData = JSON.parse(data.zTreeNodes)
|
|
||||||
}).catch((e) => {
|
|
||||||
console.error('获取树形数据失败', e)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
getyjrescueEquipDataList() {
|
|
||||||
const params = {
|
|
||||||
PARENT_ID: '73e875a1123443b69956cf6761f943de'
|
|
||||||
}
|
|
||||||
requestFN('/dictionaries/listTree', params).then((data) => {
|
|
||||||
this.yjrescueEquipData = JSON.parse(data.zTreeNodes)
|
|
||||||
}).catch((e) => {
|
|
||||||
console.error('获取树形数据失败', e)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
//* **************地图相关*****************
|
|
||||||
// 地图相关
|
|
||||||
mapOpen() {
|
|
||||||
this.top = this.getScrollTop()
|
|
||||||
if (this.top) {
|
|
||||||
this.setScrollTop(0)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 关闭地图后调用
|
|
||||||
mapClose() {
|
|
||||||
this.setScrollTop(this.top)
|
|
||||||
this.top = 0
|
|
||||||
this.showMap = false
|
|
||||||
},
|
|
||||||
getScrollTop() {
|
|
||||||
let scrollTop = 0
|
|
||||||
if (document.documentElement && document.documentElement.scrollTop) {
|
|
||||||
scrollTop = document.documentElement.scrollTop
|
|
||||||
} else if (document.body) {
|
|
||||||
scrollTop = document.body.scrollTop
|
|
||||||
}
|
|
||||||
return scrollTop
|
|
||||||
},
|
|
||||||
setScrollTop(top) {
|
|
||||||
if (!isNaN(top)) {
|
|
||||||
if (document.documentElement && document.documentElement.scrollTop !== undefined) {
|
|
||||||
document.documentElement.scrollTop = top
|
|
||||||
} else if (document.body) {
|
|
||||||
document.body.scrollTop = top
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 地图初始化
|
|
||||||
handler({ BMap, map }) {
|
|
||||||
this.mapOpen()
|
|
||||||
this.BMap = BMap
|
|
||||||
this.map = map
|
|
||||||
this.ISLOADingMap = true
|
|
||||||
var geolocation = new BMap.Geolocation()
|
|
||||||
const myGeo = new BMap.Geocoder()
|
|
||||||
var $this = this
|
|
||||||
// 调用百度地图api 中的获取当前位置接口
|
|
||||||
geolocation.getCurrentPosition(function(r) {
|
|
||||||
myGeo.getLocation(new BMap.Point(r.point.lng, r.point.lat), function(result) {
|
|
||||||
if (result) {
|
|
||||||
$this.ISLOADingMap = false
|
|
||||||
$this.$set($this, 'pointLngLat', { lng: result.point.lng, lat: result.point.lat })
|
|
||||||
map.enableScrollWheelZoom(true) // 开启鼠标滚轮缩放,默认关闭
|
|
||||||
$this.setCenter({ BMap, map })
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 搜索地图
|
|
||||||
querySearch(queryString, cb) {
|
|
||||||
var options = {
|
|
||||||
onSearchComplete: function(results) {
|
|
||||||
if (local.getStatus() === 0) {
|
|
||||||
// 判断状态是否正确
|
|
||||||
var s = []
|
|
||||||
for (var i = 0; i < results.getCurrentNumPois(); i++) {
|
|
||||||
var x = results.getPoi(i)
|
|
||||||
var item = { value: x.TYPE + x.title, point: x.point }
|
|
||||||
s.push(item)
|
|
||||||
cb(s)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
cb()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
var local = new this.BMap.LocalSearch(this.map, options)
|
|
||||||
local.search(queryString)
|
|
||||||
},
|
|
||||||
handleSelect(item) {
|
|
||||||
var { point } = item
|
|
||||||
this.map.clearOverlays() // 清除地图上所有覆盖物
|
|
||||||
this.map.centerAndZoom(point, this.zoom)
|
|
||||||
const marker = new this.BMap.Marker(point) // 创建标注
|
|
||||||
this.map.addOverlay(marker) // 将标注添加到地图中
|
|
||||||
marker.enableDragging() // 可拖拽
|
|
||||||
this.LONGITUDE = point.lng
|
|
||||||
this.LATITUDE = point.lat
|
|
||||||
},
|
|
||||||
// 设置打开中心位置
|
|
||||||
setCenter({ BMap, map }) {
|
|
||||||
var lng = ''
|
|
||||||
var lat = ''
|
|
||||||
if (this.form.LONGITUDE == '' || this.form.LATITUDE == '') {
|
|
||||||
lng = '119.525971'
|
|
||||||
lat = '39.894727'
|
|
||||||
} else {
|
|
||||||
lng = this.form.LONGITUDE
|
|
||||||
lat = this.form.LATITUDE
|
|
||||||
}
|
|
||||||
var point = new BMap.Point(lng, lat)
|
|
||||||
// var point = new BMap.Point(this.form.LONGITUDE, this.form.LATITUDE)
|
|
||||||
const zoom = map.getZoom()
|
|
||||||
setTimeout(() => {
|
|
||||||
map.centerAndZoom(point, zoom)
|
|
||||||
}, 0)
|
|
||||||
// var marker = new BMap.Marker(point) // 创建标注
|
|
||||||
// map.addOverlay(marker) // 将标注添加到地图中
|
|
||||||
},
|
|
||||||
handleMap() {
|
|
||||||
this.dialogFormMap = true
|
|
||||||
this.LATITUDE = this.form.LATITUDE
|
|
||||||
this.LONGITUDE = this.form.LONGITUDE
|
|
||||||
},
|
|
||||||
getClickInfo(e) {
|
|
||||||
this.LONGITUDE = e.point.lng
|
|
||||||
this.LATITUDE = e.point.lat
|
|
||||||
},
|
|
||||||
setPosition() {
|
|
||||||
this.dialogFormMap = false
|
|
||||||
this.form.LATITUDE = this.LATITUDE
|
|
||||||
this.form.LONGITUDE = this.LONGITUDE
|
|
||||||
},
|
|
||||||
//* ***********************************
|
//* ***********************************
|
||||||
goList(page, CASE_ID, ticketType) {
|
goList(page, CASE_ID, ticketType) {
|
||||||
this.$parent.activeName = page
|
this.$parent.activeName = page
|
||||||
|
|
|
@ -2,61 +2,54 @@
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<div class="filter-container">
|
<div class="filter-container">
|
||||||
<el-button class="filter-item" type="primary" @click="yjzjadd">
|
<el-button class="filter-item" type="primary" icon="el-icon-plus" @click="yjzjadd">
|
||||||
添加
|
添加
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
<el-table ref="multipleTable" :data="yjzjvarList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
<el-table ref="multipleTable" :data="yjzjvarList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||||
|
|
||||||
<el-table-column prop="EXPERT_NAME" label="名称" width="180" />
|
<el-table-column prop="HIERARCHICALNAME" label="分级名称" width="180" />
|
||||||
<el-table-column prop="EXPERT_CATEGORY" label="专家类型" />
|
<el-table-column prop="HIERARCHICALDES" label="分级描述" />
|
||||||
<el-table-column prop="OFFICE_PHONE" label="办公电话" />
|
<el-table-column prop="BZ" label="备注信息" />
|
||||||
<el-table-column prop="MOBILE_PHONE" label="移动电话" />
|
<!-- <el-table-column prop="MOBILE_PHONE" label="移动电话" />-->
|
||||||
<el-table-column label="操作" align="center" width="300">
|
<el-table-column label="操作" align="center" width="300">
|
||||||
<template slot-scope="{row}">
|
<template slot-scope="{row}">
|
||||||
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deletezhuangjiaPeople(row)">移除该预案专家</el-button>
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deletezhuangjiaPeople(row)">删除</el-button>
|
||||||
</template>
|
<el-button type="primary" icon="el-icon-setting" size="mini" @click="updatezhuangjiaPeople(row)">编辑</el-button>
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<el-dialog :visible.sync="dialogzhuangjiaShow" title="选择人员" width="850px" @close="closeDialog('ruleForm')">
|
|
||||||
<el-container>
|
|
||||||
<el-main>
|
|
||||||
<div class="filter-btn-group">
|
|
||||||
<el-form label-width="100px">
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="10">
|
|
||||||
<el-form-item label="姓名">
|
|
||||||
<el-input v-model="zhuangjianame" placeholder="搜索姓名"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="10">
|
|
||||||
<el-form-item label-width="10px">
|
|
||||||
<el-button class="filter-item" type="primary" icon="el-icon-search" @click="getzhuanjiaList">
|
|
||||||
搜索
|
|
||||||
</el-button>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
|
|
||||||
</el-row>
|
|
||||||
</el-form>
|
|
||||||
</div>
|
|
||||||
<el-table ref="multipleTable" :data="zhuanjiaList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" style="height:350px" tooltip-effect="dark" border fit highlight-current-row>
|
|
||||||
<!-- <el-table-column type="selection" width="55" align="center" />-->
|
|
||||||
<el-table-column prop="EXPERT_NAME" label="姓名" />
|
|
||||||
<el-table-column prop="MOBILE_TELEPHONE" label="移动电话" />
|
|
||||||
<el-table-column prop="OFFICE_TELEPHONE" label="办公电话" />
|
|
||||||
<el-table-column label="操作" align="center" width="300">
|
|
||||||
<template slot-scope="{row}">
|
|
||||||
<el-button type="primary" icon="el-icon-plus" size="mini" @click="savezhuangjiaPeople(row)">添加到预案专家</el-button>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<div class="page-btn-group">
|
<div class="page-btn-group">
|
||||||
<div/>
|
<div/>
|
||||||
<Pagination :total="zhuangjiatotal" :page.sync="listQueryzj.page" :limit.sync="listQueryzj.limit" @pagination="getzhuanjiaList" />
|
<pagination :total="total" :page.sync="listQueryzj.page" :limit.sync="listQueryzj.limit" @pagination="getPlanexpertList" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<el-dialog :visible.sync="dialogzhuangjiaShow" title="分级响应" width="600px" @close="closeDialog('ruleForm')">
|
||||||
|
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||||
|
|
||||||
|
<el-form-item label="分级名称" prop="HIERARCHICALNAME">
|
||||||
|
<el-input v-model="zhuangjiafrom.HIERARCHICALNAME" placeholder="这里分级名称..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="分级描述" prop="HIERARCHICALDES">
|
||||||
|
<el-input
|
||||||
|
v-model="zhuangjiafrom.HIERARCHICALDES"
|
||||||
|
:rows="6"
|
||||||
|
type="textarea"
|
||||||
|
placeholder="请分级描述"/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="备注信息" prop="BZ">
|
||||||
|
<el-input
|
||||||
|
v-model="zhuangjiafrom.BZ"
|
||||||
|
:rows="6"
|
||||||
|
type="textarea"
|
||||||
|
placeholder="请备注信息"/>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogzhuangjiaShow = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-main>
|
|
||||||
</el-container>
|
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -103,7 +96,7 @@ export default {
|
||||||
deletezhuangjiaPeople(row) {
|
deletezhuangjiaPeople(row) {
|
||||||
this.listISLOADing = true
|
this.listISLOADing = true
|
||||||
requestFN(
|
requestFN(
|
||||||
'/major/association/delete', { id: row.ID }
|
'/plan/fractional/delete', { id: row.HIERARCHICALRESPONSE_ID }
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
this.$message({
|
this.$message({
|
||||||
message: '移除成功',
|
message: '移除成功',
|
||||||
|
@ -116,61 +109,45 @@ export default {
|
||||||
this.listISLOADing = false
|
this.listISLOADing = false
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
savezhuangjiaPeople(row) {
|
confirm() {
|
||||||
this.zhuangjiafrom.PLAN_ID = this.planid
|
this.zhuangjiafrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
this.zhuangjiafrom.TYPE = '1'
|
|
||||||
this.zhuangjiafrom.REL_ID = row.EXPERT_ID
|
|
||||||
this.zhuangjiafrom.EXPERT_NAME = row.EXPERT_NAME
|
|
||||||
this.zhuangjiafrom.EXPERT_CATEGORY = row.EXPERT_TYPE
|
|
||||||
this.zhuangjiafrom.OFFICE_PHONE = row.OFFICE_TELEPHONE
|
|
||||||
this.zhuangjiafrom.MOBILE_PHONE = row.MOBILE_TELEPHONE
|
|
||||||
|
|
||||||
this.listISLOADing = true
|
this.listISLOADing = true
|
||||||
requestFN(
|
requestFN(
|
||||||
'/major/association/save', this.zhuangjiafrom
|
'/plan/fractional/save', this.zhuangjiafrom
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
this.$message({
|
this.$message({
|
||||||
message: '添加成功',
|
message: '添加成功',
|
||||||
type: 'success'
|
type: 'success'
|
||||||
})
|
})
|
||||||
|
this.dialogzhuangjiaShow = false
|
||||||
this.listISLOADing = false
|
this.listISLOADing = false
|
||||||
this.getPlanexpertList()
|
this.getPlanexpertList()
|
||||||
this.getzhuanjiaList()
|
|
||||||
}).catch((e) => {
|
}).catch((e) => {
|
||||||
this.listISLOADing = false
|
this.listISLOADing = false
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
yjzjadd() {
|
yjzjadd() {
|
||||||
this.dialogzhuangjiaShow = true
|
this.dialogzhuangjiaShow = true
|
||||||
this.getzhuanjiaList()
|
this.zhuangjiafrom = {}
|
||||||
},
|
},
|
||||||
getzhuanjiaList() {
|
updatezhuangjiaPeople(row) {
|
||||||
this.listISLOADing = true
|
this.dialogzhuangjiaShow = true
|
||||||
requestFN(
|
this.zhuangjiafrom = {
|
||||||
'/yjexpert/getRelevanceNotPlanList?showCount=' + this.listQueryzj.limit + '¤tPage=' + this.listQueryzj.page,
|
HIERARCHICALRESPONSE_ID: row.HIERARCHICALRESPONSE_ID,
|
||||||
{
|
HIERARCHICALNAME: row.HIERARCHICALNAME,
|
||||||
name: this.KEYWORDS,
|
HIERARCHICALDES: row.HIERARCHICALDES,
|
||||||
id: this.planid,
|
BZ: row.BZ
|
||||||
type: '1'
|
|
||||||
}
|
}
|
||||||
).then((data) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
this.zhuanjiaList = data.varList
|
|
||||||
this.zhuangjiatotal = data.page.totalResult
|
|
||||||
})
|
|
||||||
.catch((e) => {
|
|
||||||
this.listISLOADing = false
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
// 获取预案关联专家
|
// 获取应急预案分级响应
|
||||||
getPlanexpertList() {
|
getPlanexpertList() {
|
||||||
this.listISLOADing = true
|
this.listISLOADing = true
|
||||||
requestFN(
|
requestFN(
|
||||||
'/major/association/list?showCount=50' + '¤tPage=1',
|
'/plan/fractional/list?showCount=50' + '¤tPage=1',
|
||||||
{
|
{
|
||||||
name: this.KEYWORDS,
|
name: this.KEYWORDS,
|
||||||
PLAN_ID: this.planid,
|
FIRERESERVEPLAN_ID: this.planid,
|
||||||
TYPE: '1'
|
TYPE: '1'
|
||||||
}
|
}
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
|
|
|
@ -0,0 +1,261 @@
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<div class="filter-container">
|
||||||
|
<el-button class="filter-item" type="primary" icon="el-icon-plus" @click="yjzjadd">
|
||||||
|
添加
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
<el-table ref="multipleTable" :data="yjzjvarList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||||
|
|
||||||
|
<el-table-column prop="FILENAME" label="文件名称" width="180" />
|
||||||
|
<el-table-column prop="BZ" label="备注" />
|
||||||
|
<el-table-column prop="createTimeStr" label="维护日期" />
|
||||||
|
<el-table-column prop="FILEURL" width="180" align="center" label="附件" >
|
||||||
|
<template v-if="row.FILEURL" slot-scope="{row}">
|
||||||
|
<el-button type="primary" icon="el-icon-down" size="mini" @click="download(row)">下载</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="操作" align="center" width="300">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deletePlanningfile(row)">删除</el-button>
|
||||||
|
<el-button type="primary" icon="el-icon-setting" size="mini" @click="updatePlanningfile(row)">编辑</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<div class="page-btn-group">
|
||||||
|
<div/>
|
||||||
|
<pagination :total="yjzhuangjiatotal" :page.sync="listQueryzj.page" :limit.sync="listQueryzj.limit" @pagination="getDataList" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<el-dialog :visible.sync="dialogzhuangjiaShow" title="预案附件" width="600px" @close="closeDialog('ruleForm')">
|
||||||
|
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||||
|
<el-form-item label="文件名称" prop="FILENAME">
|
||||||
|
<el-input
|
||||||
|
v-model="fujianfrom.FILENAME"
|
||||||
|
|
||||||
|
placeholder="文件名称"/>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="附件类型" prop="fujianfrom.FILETYPE">
|
||||||
|
<Treeselect
|
||||||
|
:options="FILETYPEThree"
|
||||||
|
v-model="fujianfrom.FILETYPE"
|
||||||
|
placeholder="请选择预案类型"
|
||||||
|
no-options-text="暂无数据"
|
||||||
|
no-children-text="暂无数据"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="备注" prop="BZ">
|
||||||
|
<el-input
|
||||||
|
v-model="fujianfrom.BZ"
|
||||||
|
:rows="3"
|
||||||
|
type="textarea"
|
||||||
|
placeholder="备注"/>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="附件地址">
|
||||||
|
<el-upload
|
||||||
|
ref="upload"
|
||||||
|
:on-change="handleEditChange"
|
||||||
|
:on-remove="handleRemove"
|
||||||
|
:auto-upload="false"
|
||||||
|
:limit="1"
|
||||||
|
action="#" >
|
||||||
|
<el-button size="small" type="primary">点击上传</el-button>
|
||||||
|
</el-upload>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogzhuangjiaShow = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { requestFN } from '@/utils/request'
|
||||||
|
import Pagination from '@/components/Pagination'
|
||||||
|
import { upload } from '@/utils/upload'
|
||||||
|
export default {
|
||||||
|
name: 'Yingjizhuangjia',
|
||||||
|
components: { Pagination },
|
||||||
|
props: {
|
||||||
|
planid: {
|
||||||
|
type: String,
|
||||||
|
default() {
|
||||||
|
return ''
|
||||||
|
} }
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
|
||||||
|
zhuangjiatotal: 0,
|
||||||
|
zhuangjianame: '',
|
||||||
|
dialogzhuangjiaShow: false,
|
||||||
|
yjzjvarList: [],
|
||||||
|
yjzhuangjiatotal: 0,
|
||||||
|
zhuanjiaList: [],
|
||||||
|
listQueryzj: {
|
||||||
|
page: 1,
|
||||||
|
limit: 20
|
||||||
|
},
|
||||||
|
fujianfrom: {
|
||||||
|
|
||||||
|
},
|
||||||
|
FFILE: [],
|
||||||
|
FILETYPEThree: [
|
||||||
|
{ id: 1, label: '预案视频' },
|
||||||
|
{ id: 2, label: '通讯录' },
|
||||||
|
{ id: 3, label: '组织机构' },
|
||||||
|
{ id: 4, label: '建筑平面图' },
|
||||||
|
{ id: 5, label: '其他' },
|
||||||
|
{ id: 6, label: '预案电子档案' },
|
||||||
|
{ id: 7, label: '指挥平面图' },
|
||||||
|
{ id: 8, label: '应急资源' }
|
||||||
|
],
|
||||||
|
downloadUrl: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
console.log(this.planid)
|
||||||
|
this.getDataList()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
//* ************************下载**********************
|
||||||
|
download(obj) {
|
||||||
|
this.$confirm('确定要下载此文件吗?', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(() => {
|
||||||
|
this.downloadUrl = config.fileUrl + obj.FILEURL
|
||||||
|
const _this = this
|
||||||
|
setTimeout(function() {
|
||||||
|
window.open(_this.downloadUrl)
|
||||||
|
}, 200)
|
||||||
|
}).catch(() => {
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// **********************文件上传*********************
|
||||||
|
handleEditChange(file) {
|
||||||
|
file.MATERIALS_ID = Math.random()
|
||||||
|
const is5M = file.size / 1024 / 1024 < 5
|
||||||
|
if (is5M) this.FFILE.push(file)
|
||||||
|
},
|
||||||
|
handleRemove(file, fileList) {
|
||||||
|
this.FFILE = fileList
|
||||||
|
},
|
||||||
|
upload(fun) {
|
||||||
|
const formData = new FormData()
|
||||||
|
|
||||||
|
for (let i = 0; i < this.FFILE.length; i++) {
|
||||||
|
if (this.FFILE[i].raw) {
|
||||||
|
formData.append('FFILE', this.FFILE[i].raw)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
upload(
|
||||||
|
'/file/upload',
|
||||||
|
formData
|
||||||
|
).then((data) => {
|
||||||
|
fun(data.fileurl)
|
||||||
|
}).catch((e) => {
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//* ***********************************
|
||||||
|
|
||||||
|
closeDialog() {
|
||||||
|
this.dialogzhuangjiaShow = false
|
||||||
|
},
|
||||||
|
deletePlanningfile(row) {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planplanningfile/delete', { id: row.PLANNINGFILE_ID }
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '移除成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
confirm() {
|
||||||
|
if (this.FFILE.length > 0) {
|
||||||
|
this.upload((v) => {
|
||||||
|
this.fujianfrom.FILEURL = v
|
||||||
|
this.$refs.upload.clearFiles()
|
||||||
|
this.dataSave()
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.dataSave()
|
||||||
|
}
|
||||||
|
},
|
||||||
|
dataSave() {
|
||||||
|
this.fujianfrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
|
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planplanningfile/save', this.fujianfrom
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '添加成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.dialogzhuangjiaShow = false
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
yjzjadd() {
|
||||||
|
this.dialogzhuangjiaShow = true
|
||||||
|
this.fujianfrom = {
|
||||||
|
LAT: '',
|
||||||
|
LON: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
updatePlanningfile(row) {
|
||||||
|
this.dialogzhuangjiaShow = true
|
||||||
|
this.fujianfrom = {
|
||||||
|
PLANNINGFILE_ID: row.PLANNINGFILE_ID,
|
||||||
|
FILETYPE: row.FILETYPE,
|
||||||
|
FILENAME: row.FILENAME,
|
||||||
|
BZ: row.BZ
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 获取预案附件
|
||||||
|
getDataList() {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planplanningfile/list?showCount=50' + '¤tPage=1',
|
||||||
|
{
|
||||||
|
name: this.KEYWORDS,
|
||||||
|
FIRERESERVEPLAN_ID: this.planid,
|
||||||
|
TYPE: '1'
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.yjzjvarList = data.varList
|
||||||
|
this.yjzhuangjiatotal = data.page.totalResult
|
||||||
|
})
|
||||||
|
.catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
</style>
|
||||||
|
|
|
@ -0,0 +1,115 @@
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<el-form ref="form" :model="form" label-width="180px">
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="4" >
|
||||||
|
<el-form-item />
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item label="预案名称:" >
|
||||||
|
{{ planName }}
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="4" >
|
||||||
|
<el-form-item />
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item label="预案文本" prop="PLANNINGTEXT">
|
||||||
|
<el-input v-model="zhuangjiafrom.PLANNINGTEXT" :rows="6" type="textarea" placeholder="预案文本..." />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer" style="margin-left: 750px;">
|
||||||
|
|
||||||
|
<el-button type="primary" @click="confirm">保存</el-button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { requestFN } from '@/utils/request'
|
||||||
|
export default {
|
||||||
|
name: 'Yvanwenb',
|
||||||
|
components: { },
|
||||||
|
props: {
|
||||||
|
planid: {
|
||||||
|
type: String,
|
||||||
|
default() {
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
planName: {
|
||||||
|
type: String,
|
||||||
|
default() {
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
zhuangjiafrom: { 'PLANNINGTEXT': '' },
|
||||||
|
listISLOADing: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getDataList()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
|
||||||
|
//* ***********************************
|
||||||
|
|
||||||
|
confirm() {
|
||||||
|
this.zhuangjiafrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
|
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningtext/save', this.zhuangjiafrom
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '添加成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// 获取预案资源
|
||||||
|
getDataList() {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningtext/getDetail',
|
||||||
|
{
|
||||||
|
|
||||||
|
planId: this.planid
|
||||||
|
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
|
||||||
|
if (data.data.FIRERESERVEPLAN_ID) {
|
||||||
|
this.zhuangjiafrom.PLANNINGTEXT = data.data.PLANNINGTEXT
|
||||||
|
this.zhuangjiafrom.PLANNINGTEXT_ID = data.data.PLANNINGTEXT_ID
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
</style>
|
||||||
|
|
|
@ -0,0 +1,389 @@
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="13" class="bianxian">
|
||||||
|
<el-form ref="form" :model="yvanzhilingfrom" label-width="110px" >
|
||||||
|
|
||||||
|
<el-row :gutter="15">
|
||||||
|
<el-form-item label="响应级别" prop="PLANGRADE">
|
||||||
|
<el-checkbox-group v-model="checkList">
|
||||||
|
<el-checkbox v-for="jibei in xiangyingjibeiList" :label="jibei.HIERARCHICALRESPONSE_ID" :key="jibei.HIERARCHICALRESPONSE_ID">{{ jibei.HIERARCHICALNAME }}</el-checkbox>
|
||||||
|
</el-checkbox-group>
|
||||||
|
|
||||||
|
</el-form-item>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-form-item label="指令内容" prop="DIRECTIVECONTENT">
|
||||||
|
<el-input
|
||||||
|
v-model="yvanzhilingfrom.DIRECTIVECONTENT"
|
||||||
|
:rows="2"
|
||||||
|
type="textarea"
|
||||||
|
placeholder="指令内容"/>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item label="执行机构" prop="EXECUTIVEBODY">
|
||||||
|
<Treeselect
|
||||||
|
:options="treeData"
|
||||||
|
v-model="yvanzhilingfrom.EXECUTIVEBODY"
|
||||||
|
placeholder="请选择机构"
|
||||||
|
no-options-text="暂无数据"
|
||||||
|
no-children-text="暂无数据"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="14"/>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="19"> <el-form-item label="相关资源" /></el-col>
|
||||||
|
|
||||||
|
<el-col :span="2">
|
||||||
|
<div class="filter-container">
|
||||||
|
<el-button class="filter-item" type="primary" icon="el-icon-plus" @click="yjzhilingadd">
|
||||||
|
添加
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-table ref="multipleTable" :data="yjzhilinglinshiList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||||
|
|
||||||
|
<el-table-column prop="RESOURCETYPE" label="类型" width="180" />
|
||||||
|
<el-table-column prop="RESOURCENAME" label="资源名称" />
|
||||||
|
<el-table-column prop="LINKMPHONE" label="联系电话" />
|
||||||
|
<el-table-column prop="URGENTLINKPHONE" label="紧急联系电话" />
|
||||||
|
<el-table-column label="操作" align="center" width="300">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deleteyjzhilinglinshi(row)">删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<div style="height: 20px"/>
|
||||||
|
<el-row type="flex" class="row-bg" justify="center">
|
||||||
|
<el-col :span="9"><div class="grid-content bg-purple"/></el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-button type="primary" @click="confirmDatasave()">保存</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-button @click="doreset()">重置</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="10" >
|
||||||
|
<div class="filter-container">
|
||||||
|
<el-button class="filter-item" type="danger" icon="el-icon-delete" @click="makeAll">
|
||||||
|
批量删除
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
<el-table ref="multipleTable" :data="yjzjvarList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||||
|
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||||
|
<el-table-column prop="HIERARCHICALRESPONSE_NAME" label="响应级别" />
|
||||||
|
<el-table-column prop="DIRECTIVECONTENT" label="指令内容" />
|
||||||
|
<el-table-column label="操作" align="center" width="300">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deletezhiling(row)">删除</el-button>
|
||||||
|
<el-button type="primary" icon="el-icon-setting" size="mini" @click="updatezhiling(row)">编辑</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<div class="page-btn-group">
|
||||||
|
<div/>
|
||||||
|
<pagination :total="yjzhuangjiatotal" :page.sync="listQueryzj.page" :limit.sync="listQueryzj.limit" @pagination="getDataList" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-dialog :visible.sync="dialogyjzlzyShow" title="相关资源" width="600px" >
|
||||||
|
<el-form ref="form" :model="zlxianghuanziyuanform" label-width="110px" style="width: 500px;">
|
||||||
|
|
||||||
|
<el-form-item label="资源名称" prop="RESOURCENAME">
|
||||||
|
<el-input v-model="zlxianghuanziyuanform.RESOURCENAME" placeholder="资源名称..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="类型" prop="RESOURCETYPE">
|
||||||
|
<el-input v-model="zlxianghuanziyuanform.RESOURCETYPE" placeholder="类型..." />
|
||||||
|
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="联系电话" prop="LINKMPHONE">
|
||||||
|
<el-input v-model="zlxianghuanziyuanform.LINKMPHONE" placeholder="联系电话..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="紧急联系电话" prop="URGENTLINKPHONE">
|
||||||
|
<el-input v-model="zlxianghuanziyuanform.URGENTLINKPHONE" placeholder="紧急联系电话..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogyjzlzyShow = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="confirmsave">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { requestFN } from '@/utils/request'
|
||||||
|
import Pagination from '@/components/Pagination'
|
||||||
|
export default {
|
||||||
|
name: 'Yingjizhuangjia',
|
||||||
|
components: { Pagination },
|
||||||
|
props: {
|
||||||
|
planid: {
|
||||||
|
type: String,
|
||||||
|
default() {
|
||||||
|
return ''
|
||||||
|
} }
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
checkList: [],
|
||||||
|
|
||||||
|
zhuangjiatotal: 0,
|
||||||
|
zhuangjianame: '',
|
||||||
|
dialogzhuangjiaShow: false,
|
||||||
|
yjzjvarList: [],
|
||||||
|
yjzhuangjiatotal: 0,
|
||||||
|
zhuanjiaList: [],
|
||||||
|
listQueryzj: {
|
||||||
|
page: 1,
|
||||||
|
limit: 20
|
||||||
|
},
|
||||||
|
yvanzhilingfrom: {
|
||||||
|
},
|
||||||
|
// 响应级别
|
||||||
|
xiangyingjibeiList: [],
|
||||||
|
// 机构树形列表
|
||||||
|
treeData: [],
|
||||||
|
// 应急指令临时集和
|
||||||
|
yjzhilinglinshiList: [],
|
||||||
|
// 应急指令内容添加
|
||||||
|
dialogyjzlzyShow: false,
|
||||||
|
// 指令相关资源
|
||||||
|
zlxianghuanziyuanform: {}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
console.log(this.planid)
|
||||||
|
this.getDataList()
|
||||||
|
this.getForFractModule()
|
||||||
|
this.getTreeList()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
//* *****************查询指令列表**************
|
||||||
|
updatezhiling(row) {
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningdirectives/getDetail',
|
||||||
|
{
|
||||||
|
id: row.PLANNINGDIRECTIVES_ID
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
this.loading = false
|
||||||
|
this.checkList = data.data.HIERARCHICALRESPONSE_ID.split(',')
|
||||||
|
// 回显数据
|
||||||
|
this.yvanzhilingfrom = {
|
||||||
|
DIRECTIVECONTENT: data.data.DIRECTIVECONTENT,
|
||||||
|
EXECUTIVEBODY: data.data.EXECUTIVEBODY,
|
||||||
|
PLANNINGDIRECTIVES_ID: data.data.PLANNINGDIRECTIVES_ID
|
||||||
|
}
|
||||||
|
this.yjzhilinglinshiList = data.data.getResources
|
||||||
|
}).catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 删除指令
|
||||||
|
makeAll() {
|
||||||
|
const _selectData = this.$refs.multipleTable.selection
|
||||||
|
|
||||||
|
if (_selectData == null || _selectData.length == 0) {
|
||||||
|
this.$message({
|
||||||
|
message: '请选中要删除的项...',
|
||||||
|
type: 'error'
|
||||||
|
})
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
const ids = _selectData.map((item, index) => {
|
||||||
|
return item.PLANNINGDIRECTIVES_ID
|
||||||
|
}).join(',')
|
||||||
|
|
||||||
|
this.$confirm('确定要删除选中的数据吗?', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(() => {
|
||||||
|
this.loading = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningdirectives/deleteAll',
|
||||||
|
{
|
||||||
|
ids: ids
|
||||||
|
}
|
||||||
|
).then(() => {
|
||||||
|
this.loading = false
|
||||||
|
this.$refs.multipleTable.clearSelection()
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
}).catch(() => {
|
||||||
|
})
|
||||||
|
},
|
||||||
|
deletezhiling(row) {
|
||||||
|
this.loading = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningdirectives/delete', { id: row.PLANNINGDIRECTIVES_ID }
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '移除成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.loading = false
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 获取预案资源
|
||||||
|
getDataList() {
|
||||||
|
this.loading = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningdirectives/list?showCount=50' + '¤tPage=1',
|
||||||
|
{
|
||||||
|
name: this.KEYWORDS,
|
||||||
|
FIRERESERVEPLAN_ID: this.planid
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
this.loading = false
|
||||||
|
this.yjzjvarList = data.varList
|
||||||
|
this.yjzhuangjiatotal = data.page.totalResult
|
||||||
|
})
|
||||||
|
.catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//* ***************保存指令**************
|
||||||
|
doreset() {
|
||||||
|
this.yvanzhilingfrom = {}
|
||||||
|
this.checkList = []
|
||||||
|
this.yjzhilinglinshiList = []
|
||||||
|
},
|
||||||
|
confirmDatasave() {
|
||||||
|
this.yvanzhilingfrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
|
this.yvanzhilingfrom.HIERARCHICALRESPONSE_ID = this.checkList.join(',')
|
||||||
|
|
||||||
|
this.yvanzhilingfrom.listResources2 = this.yjzhilinglinshiList
|
||||||
|
this.loading = true
|
||||||
|
|
||||||
|
if (this.yvanzhilingfrom.HIERARCHICALRESPONSE_ID === '') {
|
||||||
|
this.$message({
|
||||||
|
message: '表单内容不能为空',
|
||||||
|
type: 'warning'
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.yvanzhilingfrom.EXECUTIVEBODY) {
|
||||||
|
console.log('通过')
|
||||||
|
} else {
|
||||||
|
this.$message({
|
||||||
|
message: '表单内容不能为空',
|
||||||
|
type: 'warning'
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.yvanzhilingfrom.DIRECTIVECONTENT) {
|
||||||
|
console.log('通过')
|
||||||
|
} else {
|
||||||
|
this.$message({
|
||||||
|
message: '表单内容不能为空',
|
||||||
|
type: 'warning'
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningdirectives/save', this.yvanzhilingfrom
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '添加成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.loading = false
|
||||||
|
this.doreset()
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//* ************添加应急指令相关资源************
|
||||||
|
deleteyjzhilinglinshi(row) {
|
||||||
|
for (let i = 0; i < this.yjzhilinglinshiList.length; i++) {
|
||||||
|
if (this.yjzhilinglinshiList[i].id === row.id) {
|
||||||
|
this.yjzhilinglinshiList.splice(i)
|
||||||
|
i++
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
yjzhilingadd() {
|
||||||
|
this.zlxianghuanziyuanform = {}
|
||||||
|
this.dialogyjzlzyShow = true
|
||||||
|
},
|
||||||
|
confirmsave() {
|
||||||
|
const form = {
|
||||||
|
RESOURCENAME: this.zlxianghuanziyuanform.RESOURCENAME,
|
||||||
|
RESOURCETYPE: this.zlxianghuanziyuanform.RESOURCETYPE,
|
||||||
|
LINKMPHONE: this.zlxianghuanziyuanform.LINKMPHONE,
|
||||||
|
URGENTLINKPHONE: this.zlxianghuanziyuanform.URGENTLINKPHONE,
|
||||||
|
id: this.yjzhilinglinshiList.length + 1
|
||||||
|
}
|
||||||
|
this.yjzhilinglinshiList.push(form)
|
||||||
|
this.dialogyjzlzyShow = false
|
||||||
|
},
|
||||||
|
//* *********获取应急机构树形列表********
|
||||||
|
getTreeList() {
|
||||||
|
this.loading = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningDepartment/getTreeForSelect',
|
||||||
|
{
|
||||||
|
FIRERESERVEPLAN_ID: this.planid,
|
||||||
|
proid: '0'
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
this.loading = false
|
||||||
|
this.treeData = data.data
|
||||||
|
}).catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//* *******获取响应级别************
|
||||||
|
getForFractModule() {
|
||||||
|
this.loading = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/fractional/getForFractModule', { planId: this.planid }
|
||||||
|
).then((data) => {
|
||||||
|
this.xiangyingjibeiList = data.data
|
||||||
|
}).catch((e) => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
//* ***********************************
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.bianxian{
|
||||||
|
border: 1px #d4d4d4 solid;
|
||||||
|
border-radius: 6px;
|
||||||
|
padding: 20px;
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
|
@ -0,0 +1,385 @@
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<div class="filter-container">
|
||||||
|
<el-button class="filter-item" type="primary" icon="el-icon-plus" @click="yjzjadd">
|
||||||
|
添加
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
<el-table ref="multipleTable" :data="yjzjvarList" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||||
|
|
||||||
|
<el-table-column prop="RESOURCETYPES" label="资源类型" width="180" />
|
||||||
|
<el-table-column prop="RESOURCENAME" label="资源名称" />
|
||||||
|
<el-table-column prop="RESOURCEADDRESS" label="资源地址" />
|
||||||
|
<el-table-column prop="RESOURCESNUMBER" label="资源数量" />
|
||||||
|
<el-table-column prop="LINKMAN" label="联系人" />
|
||||||
|
<el-table-column prop="LINKPHONE" label="电话" />
|
||||||
|
<el-table-column label="操作" align="center" width="300">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deletezhuangjiaPeople(row)">删除</el-button>
|
||||||
|
<el-button type="primary" icon="el-icon-setting" size="mini" @click="updatezhuangjiaPeople(row)">编辑</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<div class="page-btn-group">
|
||||||
|
<div/>
|
||||||
|
<pagination :total="total" :page.sync="listQueryzj.page" :limit.sync="listQueryzj.limit" @pagination="getDataList" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<el-dialog :visible.sync="dialogzhuangjiaShow" title="预案资源" width="600px" @close="closeDialog('ruleForm')">
|
||||||
|
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||||
|
|
||||||
|
<el-form-item label="资源类型" prop="RESOURCETYPES">
|
||||||
|
<el-input v-model="zhuangjiafrom.RESOURCETYPES" placeholder="资源类型..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="资源名称" prop="RESOURCENAME">
|
||||||
|
<el-input v-model="zhuangjiafrom.RESOURCENAME" placeholder="资源名称..." />
|
||||||
|
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="资源地址" prop="RESOURCEADDRESS">
|
||||||
|
<el-input v-model="zhuangjiafrom.RESOURCEADDRESS" placeholder="资源地址..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="资源数量" prop="RESOURCESNUMBER">
|
||||||
|
<el-input v-model="zhuangjiafrom.RESOURCESNUMBER" placeholder="资源数量..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="联系人" prop="LINKMAN">
|
||||||
|
<el-input v-model="zhuangjiafrom.LINKMAN" placeholder="联系人..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="联系电话" prop="LINKPHONE">
|
||||||
|
<el-input v-model="zhuangjiafrom.LINKPHONE" placeholder="联系电话..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="资源描述" prop="RESOURCEDES">
|
||||||
|
<el-input v-model="zhuangjiafrom.RESOURCEDES" placeholder="资源描述..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="备注" prop="BZ">
|
||||||
|
<el-input v-model="zhuangjiafrom.BZ" placeholder="备注..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-row :gutter="32">
|
||||||
|
<el-col :span="16">
|
||||||
|
<el-form-item :key="zhuangjiafrom.LON" label="经度" prop="LON">
|
||||||
|
<el-input v-model="zhuangjiafrom.LON" placeholder="请输入内容" disabled @focus="handleMap" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="16">
|
||||||
|
<el-form-item :key="zhuangjiafrom.LAT" label="纬度" prop="LAT">
|
||||||
|
<div style="display: flex">
|
||||||
|
<el-input v-model="zhuangjiafrom.LAT" placeholder="请输入内容" disabled style="width: 100%" @focus="handleMap"/>
|
||||||
|
<el-button style="margin-left:10px" @click="handleMap">
|
||||||
|
<span class="svg-container">
|
||||||
|
<svg-icon icon-class="international" />
|
||||||
|
</span>
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogzhuangjiaShow = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<!-- 坐标选择 -->
|
||||||
|
<el-dialog :visible.sync="dialogFormMap" title="编辑坐标" width="800px" class="dy-dialog">
|
||||||
|
<baidu-map
|
||||||
|
v-ISLOADing="ISLOADingMap"
|
||||||
|
:zoom="zoom"
|
||||||
|
:scroll-wheel-zoom="true"
|
||||||
|
:style="{height: clientHeight+'px'}"
|
||||||
|
@click="getClickInfo"
|
||||||
|
@ready="handler">
|
||||||
|
<bm-view style="width: 100%; height:100%; flex: 1" />
|
||||||
|
<bm-control ref="control" :offset="{width: 10, height: 10}" anchor="BMAP_ANCHOR_TOP_LEFT">
|
||||||
|
<div class="map-flex">
|
||||||
|
|
||||||
|
<div class="map-lable">关键词:</div>
|
||||||
|
<div style="flex:1;">
|
||||||
|
<el-autocomplete v-model="TYPEKeyword" :fetch-suggestions="querySearch" :trigger-on-focus="false" placeholder="请输入详细设备类型" style="width:100%" @select="handleSelect" />
|
||||||
|
</div>
|
||||||
|
<!-- <el-input v-model="TYPEKeyword" style="width: 200px" placeholder="请输入内容" />-->
|
||||||
|
<!-- <el-button slot="append" icon="el-icon-search" @click="mapNameChange"/>-->
|
||||||
|
</div>
|
||||||
|
</bm-control>
|
||||||
|
<!-- <bm-local-search :keyword="TYPEKeyword" :auto-viewport="true"/>-->
|
||||||
|
</baidu-map>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<span>经度:</span>
|
||||||
|
<el-input v-model="LON" style="width: 200px" placeholder="请输入内容" disabled />
|
||||||
|
<span>纬度:</span>
|
||||||
|
<el-input v-model="LAT" style="width: 200px" placeholder="请输入内容" disabled />
|
||||||
|
<el-button @click="dialogFormMap = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="setPosition">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { requestFN } from '@/utils/request'
|
||||||
|
import Pagination from '@/components/Pagination'
|
||||||
|
export default {
|
||||||
|
name: 'Yingjizhuangjia',
|
||||||
|
components: { Pagination },
|
||||||
|
props: {
|
||||||
|
planid: {
|
||||||
|
type: String,
|
||||||
|
default() {
|
||||||
|
return ''
|
||||||
|
} }
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 地图相关
|
||||||
|
CORPINFO_ID: this.$parent.CORPINFO_ID,
|
||||||
|
clientHeight: 600,
|
||||||
|
ISLOADingMap: true,
|
||||||
|
listISLOADing: false,
|
||||||
|
buttonISLOADing: false,
|
||||||
|
BMap: '',
|
||||||
|
map: '',
|
||||||
|
showMap: false,
|
||||||
|
TYPEKeyword: '',
|
||||||
|
pointLngLat: '',
|
||||||
|
zoom: 10,
|
||||||
|
dialogFormMap: false,
|
||||||
|
LAT: '',
|
||||||
|
LON: '',
|
||||||
|
|
||||||
|
zhuangjiatotal: 0,
|
||||||
|
zhuangjianame: '',
|
||||||
|
dialogzhuangjiaShow: false,
|
||||||
|
yjzjvarList: [],
|
||||||
|
yjzhuangjiatotal: [],
|
||||||
|
zhuanjiaList: [],
|
||||||
|
listQueryzj: {
|
||||||
|
page: 1,
|
||||||
|
limit: 20
|
||||||
|
},
|
||||||
|
zhuangjiafrom: {
|
||||||
|
LAT: '',
|
||||||
|
LON: ''
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
console.log(this.planid)
|
||||||
|
this.getDataList()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
//* **************地图相关*****************
|
||||||
|
// 地图相关
|
||||||
|
mapOpen() {
|
||||||
|
this.top = this.getScrollTop()
|
||||||
|
if (this.top) {
|
||||||
|
this.setScrollTop(0)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 关闭地图后调用
|
||||||
|
mapClose() {
|
||||||
|
this.setScrollTop(this.top)
|
||||||
|
this.top = 0
|
||||||
|
this.showMap = false
|
||||||
|
},
|
||||||
|
getScrollTop() {
|
||||||
|
let scrollTop = 0
|
||||||
|
if (document.documentElement && document.documentElement.scrollTop) {
|
||||||
|
scrollTop = document.documentElement.scrollTop
|
||||||
|
} else if (document.body) {
|
||||||
|
scrollTop = document.body.scrollTop
|
||||||
|
}
|
||||||
|
return scrollTop
|
||||||
|
},
|
||||||
|
setScrollTop(top) {
|
||||||
|
if (!isNaN(top)) {
|
||||||
|
if (document.documentElement && document.documentElement.scrollTop !== undefined) {
|
||||||
|
document.documentElement.scrollTop = top
|
||||||
|
} else if (document.body) {
|
||||||
|
document.body.scrollTop = top
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 地图初始化
|
||||||
|
handler({ BMap, map }) {
|
||||||
|
this.mapOpen()
|
||||||
|
this.BMap = BMap
|
||||||
|
this.map = map
|
||||||
|
this.ISLOADingMap = true
|
||||||
|
var geolocation = new BMap.Geolocation()
|
||||||
|
const myGeo = new BMap.Geocoder()
|
||||||
|
var $this = this
|
||||||
|
// 调用百度地图api 中的获取当前位置接口
|
||||||
|
geolocation.getCurrentPosition(function(r) {
|
||||||
|
myGeo.getLocation(new BMap.Point(r.point.lng, r.point.lat), function(result) {
|
||||||
|
if (result) {
|
||||||
|
$this.ISLOADingMap = false
|
||||||
|
$this.$set($this, 'pointLngLat', { lng: result.point.lng, lat: result.point.lat })
|
||||||
|
map.enableScrollWheelZoom(true) // 开启鼠标滚轮缩放,默认关闭
|
||||||
|
$this.setCenter({ BMap, map })
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 搜索地图
|
||||||
|
querySearch(queryString, cb) {
|
||||||
|
var options = {
|
||||||
|
onSearchComplete: function(results) {
|
||||||
|
if (local.getStatus() === 0) {
|
||||||
|
// 判断状态是否正确
|
||||||
|
var s = []
|
||||||
|
for (var i = 0; i < results.getCurrentNumPois(); i++) {
|
||||||
|
var x = results.getPoi(i)
|
||||||
|
var item = { value: x.TYPE + x.title, point: x.point }
|
||||||
|
s.push(item)
|
||||||
|
cb(s)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
cb()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var local = new this.BMap.LocalSearch(this.map, options)
|
||||||
|
local.search(queryString)
|
||||||
|
},
|
||||||
|
handleSelect(item) {
|
||||||
|
var { point } = item
|
||||||
|
this.map.clearOverlays() // 清除地图上所有覆盖物
|
||||||
|
this.map.centerAndZoom(point, this.zoom)
|
||||||
|
const marker = new this.BMap.Marker(point) // 创建标注
|
||||||
|
this.map.addOverlay(marker) // 将标注添加到地图中
|
||||||
|
marker.enableDragging() // 可拖拽
|
||||||
|
this.LON = point.lng
|
||||||
|
this.LAT = point.lat
|
||||||
|
},
|
||||||
|
// 设置打开中心位置
|
||||||
|
setCenter({ BMap, map }) {
|
||||||
|
var lng = ''
|
||||||
|
var lat = ''
|
||||||
|
if (this.zhuangjiafrom.LON == '' || this.zhuangjiafrom.LAT == '') {
|
||||||
|
lng = '119.525971'
|
||||||
|
lat = '39.894727'
|
||||||
|
} else {
|
||||||
|
lng = this.zhuangjiafrom.LON
|
||||||
|
lat = this.zhuangjiafrom.LAT
|
||||||
|
}
|
||||||
|
var point = new BMap.Point(lng, lat)
|
||||||
|
// var point = new BMap.Point(this.zhuangjiafrom.LON, this.zhuangjiafrom.LAT)
|
||||||
|
const zoom = map.getZoom()
|
||||||
|
setTimeout(() => {
|
||||||
|
map.centerAndZoom(point, zoom)
|
||||||
|
}, 0)
|
||||||
|
// var marker = new BMap.Marker(point) // 创建标注
|
||||||
|
// map.addOverlay(marker) // 将标注添加到地图中
|
||||||
|
},
|
||||||
|
handleMap() {
|
||||||
|
this.dialogFormMap = true
|
||||||
|
this.LAT = this.zhuangjiafrom.LAT
|
||||||
|
this.LON = this.zhuangjiafrom.LON
|
||||||
|
},
|
||||||
|
getClickInfo(e) {
|
||||||
|
this.LON = e.point.lng
|
||||||
|
this.LAT = e.point.lat
|
||||||
|
},
|
||||||
|
setPosition() {
|
||||||
|
this.dialogFormMap = false
|
||||||
|
this.zhuangjiafrom.LAT = this.LAT
|
||||||
|
this.zhuangjiafrom.LON = this.LON
|
||||||
|
},
|
||||||
|
//* ***********************************
|
||||||
|
|
||||||
|
closeDialog() {
|
||||||
|
this.dialogzhuangjiaShow = false
|
||||||
|
},
|
||||||
|
deletezhuangjiaPeople(row) {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningresources/delete', { id: row.PLANNINGRESOURCES_ID }
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '移除成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
confirm() {
|
||||||
|
this.zhuangjiafrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
|
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningresources/save', this.zhuangjiafrom
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '添加成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.dialogzhuangjiaShow = false
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDataList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
yjzjadd() {
|
||||||
|
this.dialogzhuangjiaShow = true
|
||||||
|
this.zhuangjiafrom = {
|
||||||
|
LAT: '',
|
||||||
|
LON: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
updatezhuangjiaPeople(row) {
|
||||||
|
this.dialogzhuangjiaShow = true
|
||||||
|
this.zhuangjiafrom = {
|
||||||
|
PLANNINGRESOURCES_ID: row.PLANNINGRESOURCES_ID,
|
||||||
|
RESOURCETYPES: row.RESOURCETYPES,
|
||||||
|
RESOURCENAME: row.RESOURCENAME,
|
||||||
|
RESOURCEADDRESS: row.RESOURCEADDRESS,
|
||||||
|
|
||||||
|
RESOURCESNUMBER: row.RESOURCESNUMBER,
|
||||||
|
LINKMAN: row.LINKMAN,
|
||||||
|
LINKPHONE: row.LINKPHONE,
|
||||||
|
RESOURCEDES: row.RESOURCEDES,
|
||||||
|
|
||||||
|
BZ: row.BZ,
|
||||||
|
LAT: row.LAT,
|
||||||
|
LON: row.LON
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 获取预案资源
|
||||||
|
getDataList() {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningresources/list?showCount=50' + '¤tPage=1',
|
||||||
|
{
|
||||||
|
name: this.KEYWORDS,
|
||||||
|
FIRERESERVEPLAN_ID: this.planid,
|
||||||
|
TYPE: '1'
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.yjzjvarList = data.varList
|
||||||
|
this.yjzhuangjiatotal = data.page.totalResult
|
||||||
|
})
|
||||||
|
.catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
</style>
|
||||||
|
|
|
@ -1,6 +1,20 @@
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
|
<div class="filter-container">
|
||||||
|
<el-button class="filter-item" type="primary" icon="el-icon-plus" @click="jigouAdd">
|
||||||
|
新增机构
|
||||||
|
</el-button>
|
||||||
|
<el-button class="filter-item" type="danger" icon="el-icon-delete" @click="jigoudelete">
|
||||||
|
删除机构
|
||||||
|
</el-button>
|
||||||
|
<el-button class="filter-item" type="primary" icon="el-icon-plus" @click="renyuanadd">
|
||||||
|
新增人员
|
||||||
|
</el-button>
|
||||||
|
<!-- <el-button class="filter-item" type="danger" icon="el-icon-delete" @click="renyuandelete">
|
||||||
|
批量删除
|
||||||
|
</el-button>-->
|
||||||
|
</div>
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-aside width="300px" style="background-color:#fff">
|
<el-aside width="300px" style="background-color:#fff">
|
||||||
|
|
||||||
|
@ -29,11 +43,18 @@
|
||||||
highlight-current-row
|
highlight-current-row
|
||||||
>
|
>
|
||||||
|
|
||||||
<el-table-column label="名称" prop="NAME" />
|
<el-table-column label="姓名" prop="NAME" />
|
||||||
<el-table-column prop="HEADMAN_NAME" label="负责人"/>
|
<el-table-column prop="DUTIES" label="职务"/>
|
||||||
<el-table-column prop="leName" label="部门级别"/>
|
<el-table-column prop="POSITION" label="组内岗位"/>
|
||||||
<el-table-column prop="DEP_ORDER" label="排序" width="100" />
|
<el-table-column prop="LINKPHONE" label="联系电话"/>
|
||||||
|
<el-table-column prop="URGENTLINKPHONE" label="紧急联系电话"/>
|
||||||
|
<el-table-column prop="PLANNINGDEPARTMENT_NAME" label="组织机构"/>
|
||||||
|
<el-table-column label="操作" align="center" width="300">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-button type="danger" icon="el-icon-delete" size="mini" @click="deleterenyuanPeople(row.PLANNINGPERSONNEL_ID)">删除</el-button>
|
||||||
|
<el-button type="primary" icon="el-icon-setting" size="mini" @click="updaterenyuanPeople(row)">编辑</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<div class="page-btn-group">
|
<div class="page-btn-group">
|
||||||
<div/>
|
<div/>
|
||||||
|
@ -41,6 +62,73 @@
|
||||||
</div>
|
</div>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
|
|
||||||
|
<el-dialog :visible.sync="dialogjigouShow" title="机构" width="600px" >
|
||||||
|
<el-tag class="mark_up" size="medium">上级菜单:{{ jigoumainid == '0' ?'(无) 此项为顶级分组':jigouname }}</el-tag>
|
||||||
|
<el-form ref="form" :rules="rules" :model="jigoufrom" label-width="110px" style="width: 500px;">
|
||||||
|
|
||||||
|
<el-form-item label="名称" prop="NAME">
|
||||||
|
<el-input v-model="jigoufrom.NAME" placeholder="这里名称..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="英文" prop="NAME_EN">
|
||||||
|
<el-input v-model="jigoufrom.NAME_EN" placeholder="这里英文..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="编码" prop="BIANMA">
|
||||||
|
<el-input v-model="jigoufrom.BIANMA" placeholder="这里编码..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="负责人" prop="HEADMAN">
|
||||||
|
<el-input v-model="jigoufrom.HEADMAN" placeholder="这里负责人..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="电话" prop="TEL">
|
||||||
|
<el-input v-model="jigoufrom.TEL" placeholder="这里电话..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="部门职能" prop="FUNCTIONS">
|
||||||
|
<el-input v-model="jigoufrom.FUNCTIONS" placeholder="这里部门职能..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="地址" prop="ADDRESS">
|
||||||
|
<el-input v-model="jigoufrom.ADDRESS" placeholder="这里地址..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="备注" prop="BZ">
|
||||||
|
<el-input v-model="jigoufrom.BZ" placeholder="这里备注..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogjigouShow = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="jigouconfirm">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-dialog :visible.sync="dialogrenyuanShow" title="人员" width="600px" >
|
||||||
|
<el-tag class="mark_up" size="medium">所属机构:{{ jigoumainid == '0' ?'(无) 此项为顶级分组':jigouname }}</el-tag>
|
||||||
|
<el-form ref="form" :rules="rules" :model="renyuanfrom" label-width="110px" style="width: 500px;">
|
||||||
|
|
||||||
|
<el-form-item label="姓名" prop="NAME">
|
||||||
|
<el-input v-model="renyuanfrom.NAME" placeholder="这里名称..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="职务" prop="DUTIES">
|
||||||
|
<el-input v-model="renyuanfrom.DUTIES" placeholder="这里英文..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="组内岗位" prop="POSITION">
|
||||||
|
<el-input v-model="renyuanfrom.POSITION" placeholder="这里编码..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="联系电话" prop="LINKPHONE">
|
||||||
|
<el-input v-model="renyuanfrom.LINKPHONE" placeholder="这里负责人..." />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="紧急联系电话" prop="URGENTLINKPHONE">
|
||||||
|
<el-input v-model="renyuanfrom.URGENTLINKPHONE" placeholder="这里电话..." />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogrenyuanShow = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="renyuanconfirm">确 定</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
@ -52,10 +140,16 @@ export default {
|
||||||
name: 'Yingjizhuangjia',
|
name: 'Yingjizhuangjia',
|
||||||
components: { Pagination, Treeselect },
|
components: { Pagination, Treeselect },
|
||||||
props: {
|
props: {
|
||||||
|
planid: {
|
||||||
|
type: String,
|
||||||
|
default() {
|
||||||
|
return ''
|
||||||
|
} }
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
rules: [],
|
||||||
|
listISLOADing: false,
|
||||||
listQuery: {
|
listQuery: {
|
||||||
page: 1,
|
page: 1,
|
||||||
limit: 20
|
limit: 20
|
||||||
|
@ -68,30 +162,136 @@ export default {
|
||||||
label: 'name'
|
label: 'name'
|
||||||
},
|
},
|
||||||
total: 0,
|
total: 0,
|
||||||
treeData: []
|
treeData: [],
|
||||||
|
//* ***机构维护*******
|
||||||
|
jigoumainid: '0',
|
||||||
|
jigouname: '',
|
||||||
|
dialogjigouShow: false,
|
||||||
|
jigoufrom: {},
|
||||||
|
//* ******人员*********
|
||||||
|
renyuanfrom: {},
|
||||||
|
dialogrenyuanShow: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getTreeList()
|
this.getTreeList()
|
||||||
this.getDEPARTMENTList(0)
|
this.getDEPARTMENTList('')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
renyuanadd() {
|
||||||
|
this.dialogrenyuanShow = true
|
||||||
|
this.renyuanfrom = {}
|
||||||
|
},
|
||||||
|
updaterenyuanPeople(row) {
|
||||||
|
this.dialogrenyuanShow = true
|
||||||
|
this.jigouname = row.PLANNINGDEPARTMENT_NAME
|
||||||
|
this.renyuanfrom = {
|
||||||
|
PLANNINGPERSONNEL_ID: row.PLANNINGPERSONNEL_ID,
|
||||||
|
NAME: row.NAME,
|
||||||
|
|
||||||
|
DUTIES: row.DUTIES,
|
||||||
|
POSITION: row.POSITION,
|
||||||
|
LINKPHONE: row.LINKPHONE,
|
||||||
|
URGENTLINKPHONE: row.URGENTLINKPHONE
|
||||||
|
|
||||||
|
}
|
||||||
|
},
|
||||||
|
deleterenyuanPeople(id) {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningDepartment/deletePersonnel', { id: id }
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '移除成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDEPARTMENTList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
renyuanconfirm() {
|
||||||
|
this.listISLOADing = true
|
||||||
|
this.renyuanfrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
|
this.renyuanfrom.PLANNINGDEPARTMENT_ID = this.jigoumainid
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningDepartment/savePersonnel', this.renyuanfrom
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '添加成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.dialogrenyuanShow = false
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getDEPARTMENTList(this.jigoumainid)
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
//* **************************
|
||||||
|
jigouAdd() {
|
||||||
|
this.jigoufrom = {}
|
||||||
|
this.dialogjigouShow = true
|
||||||
|
},
|
||||||
|
jigoudelete() {
|
||||||
|
this.listISLOADing = true
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningDepartment/delete', { id: this.jigoumainid }
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '移除成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getTreeList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
jigouconfirm() {
|
||||||
|
this.listISLOADing = true
|
||||||
|
this.jigoufrom.FIRERESERVEPLAN_ID = this.planid
|
||||||
|
this.jigoufrom.PARENT_ID = this.jigoumainid
|
||||||
|
requestFN(
|
||||||
|
'/plan/planningDepartment/save', this.jigoufrom
|
||||||
|
).then((data) => {
|
||||||
|
this.$message({
|
||||||
|
message: '添加成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
this.dialogjigouShow = false
|
||||||
|
this.listISLOADing = false
|
||||||
|
this.getTreeList()
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listISLOADing = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
filterNode(value, data) {
|
filterNode(value, data) {
|
||||||
if (!value) return true
|
if (!value) return true
|
||||||
return data.name.indexOf(value) !== -1
|
return data.name.indexOf(value) !== -1
|
||||||
},
|
},
|
||||||
handleNodeClick(node, data, value) {
|
handleNodeClick(node, data, value) {
|
||||||
this.form.PARENT_ID = node.id
|
this.jigoumainid = node.id
|
||||||
this.getDEPARTMENTList(node.id)
|
|
||||||
|
this.jigouname = node.name
|
||||||
|
this.getDEPARTMENTList(this.jigoumainid)
|
||||||
},
|
},
|
||||||
getTreeList() {
|
getTreeList() {
|
||||||
this.treeLoading = true
|
this.treeLoading = true
|
||||||
requestFN(
|
requestFN(
|
||||||
'/department/listTree',
|
'/plan/planningDepartment/getTree',
|
||||||
{}
|
{
|
||||||
|
FIRERESERVEPLAN_ID: this.planid,
|
||||||
|
proid: '0'
|
||||||
|
}
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
this.treeLoading = false
|
this.treeLoading = false
|
||||||
this.treeData = JSON.parse(data.zTreeNodes)
|
this.treeData = data.data
|
||||||
}).catch((e) => {
|
}).catch((e) => {
|
||||||
this.treeLoading = false
|
this.treeLoading = false
|
||||||
})
|
})
|
||||||
|
@ -101,15 +301,14 @@ export default {
|
||||||
this.listLoading = true
|
this.listLoading = true
|
||||||
this.varList = []
|
this.varList = []
|
||||||
requestFN(
|
requestFN(
|
||||||
'/department/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
'/plan/planningDepartment/personnelList?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||||
{
|
{
|
||||||
DEPARTMENT_ID: DEPARTMENT_ID
|
PLANNINGDEPARTMENT_ID: DEPARTMENT_ID,
|
||||||
|
FIRERESERVEPLAN_ID: this.planid
|
||||||
}
|
}
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
this.listLoading = false
|
this.listLoading = false
|
||||||
this.varList = data.varList
|
this.varList = data.varList
|
||||||
this.form.PARENT_ID = data.PARENT_ID
|
|
||||||
this.form.LEVEL = data.LEVEL
|
|
||||||
this.total = data.page.totalResult
|
this.total = data.page.totalResult
|
||||||
this.hasButton()
|
this.hasButton()
|
||||||
}).catch((e) => {
|
}).catch((e) => {
|
||||||
|
|
|
@ -18,7 +18,6 @@ export default {
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
huidiao() {
|
huidiao() {
|
||||||
console.log('sdfsdsfd')
|
|
||||||
this.$refs.list.getList()
|
this.$refs.list.getList()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue