Merge remote-tracking branch 'origin/liujun-2024-01-09-消防功能新需求' into 2024年1月24日测试
# Conflicts: # config/index.js # static/config.js2024年2月1日V1.0.53
commit
b8df13587b
|
@ -0,0 +1,326 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="rightCont">
|
||||
<el-form label-width="50px">
|
||||
<el-col :span="4">
|
||||
<el-form-item label="消防器材类型:" label-width="110px">
|
||||
<el-select v-model="keySelect.FIRE_DEVICE_TYPE_ID" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in typeData"
|
||||
:key="item.NAME"
|
||||
:label="item.NAME"
|
||||
:value="item.BIANMA"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="消防区域" label-width="110px">
|
||||
<el-select v-model="keySelect.FIRE_REGION_ID" placeholder="请选择" class="filter-item">
|
||||
<el-option
|
||||
v-for="item in varRegionList"
|
||||
:key="item.FIRE_REGION_ID"
|
||||
:label="item.FIRE_REGION_NAME"
|
||||
:value="item.FIRE_REGION_ID"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="消防点位" label-width="110px">
|
||||
<el-input v-model="keySelect.FIRE_POINT_NAME" placeholder="请输入关键字"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="器材编号" label-width="110px">
|
||||
<el-input v-model="keySelect.FIRE_DEVICE_CODE" placeholder="请输入关键字"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
type="selection"
|
||||
width="55"
|
||||
reserve-selection
|
||||
align="center"/>
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRE_DEVICE_TYPE_NAME" label="器材类型"/>
|
||||
<el-table-column prop="FIRE_DEVICE_CODE" label="器材编号"/>
|
||||
<el-table-column prop="FIRE_REGION_NAME" label="消防区域名称"/>
|
||||
<el-table-column prop="FIRE_POINT_NAME" label="消防点位名称"/>
|
||||
<el-table-column prop="FIRE_REGION_CODE" label="消防区域编码"/>
|
||||
<el-table-column prop="FIRE_POINT_CODE" label="消防点位编码"/>
|
||||
<el-table-column prop="VALIDITY_START_TIME" label="有效期开始时间"/>
|
||||
<el-table-column prop="VALIDITY_END_TIME" label="有效期结束时间"/>
|
||||
<el-table-column prop="REMAKE" label="存放地点"/>
|
||||
<el-table-column prop="DEPARTMENTNAME" width ="170" label="负责部门"/>
|
||||
<el-table-column prop="USERNAME" label="点位负责人"/>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button @click = "goBack()">返 回</el-button>
|
||||
</div>
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.page"
|
||||
:limit.sync="listQuery.limit"
|
||||
@pagination="getList(FIRE_DEVICE_ID)"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import { upload } from '@/utils/upload'
|
||||
export default {
|
||||
components: { Pagination, SelectTree },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
addBtnType: true,
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
form: {
|
||||
FIRE_DEVICE_TYPE_ID: '',
|
||||
FIRE_REGION_ID: ''
|
||||
},
|
||||
keySelect: {
|
||||
FIRE_DEVICE_TYPE_ID: '',
|
||||
FIRE_REGION_ID: '',
|
||||
FIRE_POINT_NAME: '',
|
||||
FIRE_DEVICE_CODE: ''
|
||||
},
|
||||
treeData: [],
|
||||
typeData: [],
|
||||
varRegionList: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
FIRE_POINT_NAME: '',
|
||||
FIRE_POINT_CODE: '',
|
||||
// 树形菜单
|
||||
filterText: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'children',
|
||||
label: 'name'
|
||||
},
|
||||
daoruFrom: {
|
||||
FFILEName: '',
|
||||
FFILE: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
filterText(val) {
|
||||
console.log(val)
|
||||
this.$refs.tree.filter(val)
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.hasButton()
|
||||
this.getDict()
|
||||
this.getTreeData()
|
||||
this.getFireRegion()
|
||||
},
|
||||
methods: {
|
||||
getTreeData() {
|
||||
requestFN(
|
||||
'/department/listTree',
|
||||
{}
|
||||
).then((data) => {
|
||||
this.treeData = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
})
|
||||
},
|
||||
// 获取区域
|
||||
getFireRegion() {
|
||||
requestFN(
|
||||
'/fireregion/getAllRegionName',
|
||||
{}
|
||||
).then((data) => {
|
||||
this.varRegionList = data.varList
|
||||
}).catch((e) => {
|
||||
})
|
||||
},
|
||||
goImportStand(FIRE_DEVICE_ID) {
|
||||
this.$parent.FIRE_DEVICE_ID = FIRE_DEVICE_ID
|
||||
this.$parent.activeName = 'Info'
|
||||
},
|
||||
getRowKey(row) {
|
||||
return row.FIRE_DEVICE_ID
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList(pid) {
|
||||
this.listLoading = true
|
||||
this.varList = []
|
||||
this.FIRE_POINT_ID = pid
|
||||
requestFN(
|
||||
'/fireDevice/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
FIRE_REGION_ID: this.keySelect.FIRE_REGION_ID,
|
||||
FIRE_DEVICE_TYPE_ID: this.keySelect.FIRE_DEVICE_TYPE_ID,
|
||||
FIRE_POINT_NAME: this.keySelect.FIRE_POINT_NAME,
|
||||
FIRE_DEVICE_CODE: this.keySelect.FIRE_DEVICE_CODE,
|
||||
CORPINFO_ID: this.getInfo().CORPINFO_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goKeyReset() {
|
||||
this.keySelect.FIRE_DEVICE_TYPE_ID = ''
|
||||
this.keySelect.FIRE_REGION_ID = ''
|
||||
this.keySelect.FIRE_DEVICE_CODE = ''
|
||||
this.getList()
|
||||
},
|
||||
getDict() {
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '4a3d0d99b0ea4e268c11dd0b18866917'
|
||||
}
|
||||
).then((data) => {
|
||||
this.typeList = data.list
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '249151f04fd64132a949fdd430a7b9c5'
|
||||
}
|
||||
).then((data) => {
|
||||
this.typeData = data.list
|
||||
console.log(this.typeData)
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: 'f60cf0e8315b4993b6d6049dd29f2ba5'
|
||||
}
|
||||
).then((data) => {
|
||||
this.periodList = data.list
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '4a661fa8aedc4d158c9cddaa9d2ec47e'
|
||||
}
|
||||
).then((data) => {
|
||||
this.listingLevelList = this.listingLevelList.concat(data.list)
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
hasButton: function() {
|
||||
var keys = 'listmanager:add,listmanager:del,listmanager:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.listmanagerfhadminadd // 新增权限
|
||||
this.del = data.listmanagerfhadmindel // 删除权限
|
||||
this.edit = data.listmanagerfhadminedit // 修改权限
|
||||
this.toExcel = data.toExcel // 导出到excel权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.returnBtn {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.app-container {
|
||||
display: flex; /**/
|
||||
align-items: baseline;
|
||||
}
|
||||
|
||||
.rightCont {
|
||||
width: 100%
|
||||
}
|
||||
|
||||
</style>
|
||||
<style lang="sass" scoped>
|
||||
.table-qrcode
|
||||
text-align: center
|
||||
padding-top: 20px
|
||||
width: 100%
|
||||
.filter-container
|
||||
position: relative
|
||||
.filter-flot
|
||||
position: absolute
|
||||
right: 0
|
||||
top: 0
|
||||
.uploader
|
||||
width: 570px
|
||||
display: flex
|
||||
align-items: center
|
||||
.el-form-item__content
|
||||
line-height: 1
|
||||
|
||||
.ud-flex
|
||||
display: flex
|
||||
</style>
|
|
@ -0,0 +1,333 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="rightCont">
|
||||
<el-form label-width="50px">
|
||||
<el-row>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="点位名称" label-width="110px">
|
||||
<el-input v-model="FIRE_POINT_NAME" placeholder="请输入关键字"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="点位编码" label-width="110px">
|
||||
<el-input v-model="FIRE_POINT_CODE" placeholder="请输入关键字"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
:selectable="selectable"
|
||||
type="selection"
|
||||
reserve-selection
|
||||
width="55"
|
||||
align="center"/>
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRE_REGION_NAME" label="区域名称"/>
|
||||
<el-table-column prop="FIRE_POINT_NAME" label="点位名称"/>
|
||||
<el-table-column prop="FIRE_POINT_CODE" label="编码"/>
|
||||
<el-table-column prop="DEVICE_COUNT" label="点位下消防器材数"/>
|
||||
<el-table-column prop="DEPARTMENT_NAME" label="负责部门"/>
|
||||
<el-table-column prop="USERNAME" label="负责人"/>
|
||||
<el-table-column label="操作">
|
||||
<template slot-scope="{row}">
|
||||
<el-button
|
||||
v-show="true"
|
||||
class="tiffany-btn"
|
||||
icon="el-icon-picture"
|
||||
type="primary"
|
||||
size="mini"
|
||||
@click="handleShowQr(row)">点位二维码
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button icon="el-icon-plus" @click="goBack()">返 回</el-button>
|
||||
</div>
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.page"
|
||||
:limit.sync="listQuery.limit"
|
||||
@pagination="getList(FIRE_POINT_ID)"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<el-dialog :visible.sync="dialogFormShow" title="查看二维码" width="680px" class="top-dialog">
|
||||
<div id="printTest" style="border: 1px solid #fff;">
|
||||
<div class="level-title" style="margin-top:20px">
|
||||
<h1>消防点位信息</h1>
|
||||
</div>
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">消防区域</td>
|
||||
<td >{{ qrInfo.FIRE_REGION_NAME }}</td>
|
||||
<td class="tbg">消防点位</td>
|
||||
<td>{{ qrInfo.FIRE_POINT_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">负责部门</td>
|
||||
<td>{{ qrInfo.DEPARTMENT_NAME }}</td>
|
||||
<td class="tbg">负责人</td>
|
||||
<td>{{ qrInfo.USERNAME }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<div class="table-qrcode">
|
||||
<vue-qr :text="qrcodeStr" :margin="0" :size="300" color-dark="#000" color-light="#fff" />
|
||||
</div>
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormShow = false">关 闭</el-button>
|
||||
<el-button v-print="'#printTest'" type="primary">打 印</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
|
||||
import vueQr from 'vue-qr'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
|
||||
export default {
|
||||
|
||||
components: { Pagination, SelectTree, vueQr },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
addBtnType: true,
|
||||
listLoading: true,
|
||||
dialogFormShow: false,
|
||||
qrcodeStr: '',
|
||||
qrInfo: {},
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
FIRE_POINT_NAME: '',
|
||||
FIRE_POINT_CODE: '',
|
||||
// 树形菜单
|
||||
filterText: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
filterText(val) {
|
||||
console.log(val)
|
||||
this.$refs.tree.filter(val)
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
handleShowQr(ROW) {
|
||||
this.dialogFormShow = true
|
||||
this.qrInfo = ROW
|
||||
this.qrcodeStr = this.config.weburlWaiwang + 'static/qrcode/views/bsbw/point_list.html?id=' + ROW.FIRE_POINT_ID
|
||||
},
|
||||
handleEdit(FIRE_POINT_ID) {
|
||||
this.$parent.FIRE_POINT_ID = FIRE_POINT_ID
|
||||
this.$parent.activeName = 'Edit'
|
||||
},
|
||||
selectable(row, index) {
|
||||
return row.DEVICE_COUNT == 0
|
||||
},
|
||||
getRowKey(row) {
|
||||
return row.FIRE_POINT_ID
|
||||
},
|
||||
// 添加
|
||||
handleAdd() {
|
||||
this.$parent.activeName = 'Edit'
|
||||
this.$parent.FIRE_POINT_ID = ''
|
||||
this.$parent.FIRE_POINT_CODE = ''
|
||||
this.$parent.FIRE_POINT_NAME = ''
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList(pid) {
|
||||
this.listLoading = true
|
||||
this.varList = []
|
||||
this.FIRE_POINT_ID = pid
|
||||
requestFN(
|
||||
'/firePoint/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
FIRE_POINT_NAME: this.FIRE_POINT_NAME,
|
||||
FIRE_POINT_CODE: this.FIRE_POINT_CODE,
|
||||
CORPINFO_ID: this.getInfo().CORPINFO_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}, goKeyReset() {
|
||||
this.FIRE_POINT_NAME = ''
|
||||
this.FIRE_POINT_CODE = ''
|
||||
this.getList()
|
||||
},
|
||||
getDict() {
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '4a3d0d99b0ea4e268c11dd0b18866917'
|
||||
}
|
||||
).then((data) => {
|
||||
this.typeList = data.list
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: 'f60cf0e8315b4993b6d6049dd29f2ba5'
|
||||
}
|
||||
).then((data) => {
|
||||
this.periodList = data.list
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '4a661fa8aedc4d158c9cddaa9d2ec47e'
|
||||
}
|
||||
).then((data) => {
|
||||
this.listingLevelList = this.listingLevelList.concat(data.list)
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleDelete(row) {
|
||||
const DATA_IDS = []
|
||||
if (row.FIRE_POINT_ID) {
|
||||
DATA_IDS.push(row.FIRE_POINT_ID)
|
||||
} else {
|
||||
const selection = this.$refs.multipleTable.selection
|
||||
if (!selection.length > 0) {
|
||||
this.$message({
|
||||
type: 'warning',
|
||||
message: '请选择要删除的数据'
|
||||
})
|
||||
return
|
||||
}
|
||||
selection.forEach(item => {
|
||||
DATA_IDS.push(item.FIRE_POINT_ID)
|
||||
})
|
||||
}
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/firePoint/removeFirePointByIds',
|
||||
{
|
||||
DATA_IDS: DATA_IDS.join(',')
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList(this.FIRE_POINT_ID)
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'listmanager:add,listmanager:del,listmanager:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.listmanagerfhadminadd // 新增权限
|
||||
this.del = data.listmanagerfhadmindel // 删除权限
|
||||
this.edit = data.listmanagerfhadminedit // 修改权限
|
||||
this.toExcel = data.toExcel // 导出到excel权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped >
|
||||
.returnBtn {
|
||||
float: right;
|
||||
}
|
||||
.app-container {
|
||||
display: flex; /**/
|
||||
align-items: baseline;
|
||||
}
|
||||
.table-qrcode{
|
||||
text-align: center;
|
||||
padding-top: 20px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.rightCont {
|
||||
width: 100%
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,188 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="rightCont">
|
||||
<el-form label-width="50px">
|
||||
<el-row>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="区域名称/编码" label-width="110px">
|
||||
<el-input v-model="KEYWORDS" placeholder="请输入关键字"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4"/>
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%">
|
||||
<el-table-column :selectable="selectable" type="selection" reserve-selection width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRE_REGION_NAME" label="区域名称"/>
|
||||
<el-table-column prop="DEPARTMENT_NAME" label="负责部门"/>
|
||||
<el-table-column prop="FIRE_REGION_CODE" label="编码"/>
|
||||
<el-table-column prop="ITEMCOUNT" label="区域下点位数"/>
|
||||
<el-table-column prop="STATE" label="状态">
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.STATE === 1" class="color-red">禁用</span>
|
||||
<span v-if="row.STATE === 0" class="color-green">启用</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="REMAKE" label="备注"/>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button @click="goBack">返 回</el-button>
|
||||
</div>
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.page"
|
||||
:limit.sync="listQuery.limit"
|
||||
@pagination="getList(HIDDENREGION_ID)"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
|
||||
export default {
|
||||
|
||||
components: { Pagination, SelectTree },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
addBtnType: true,
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
// 树形菜单
|
||||
filterText: '',
|
||||
varList: []
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
filterText(val) {
|
||||
console.log(val)
|
||||
this.$refs.tree.filter(val)
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.hasButton()
|
||||
this.getTreeList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.FIRE_REGION_ID
|
||||
},
|
||||
selectable(row, index) {
|
||||
return row.ITEMCOUNT == 0
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList(pid) {
|
||||
this.listLoading = true
|
||||
this.varList = []
|
||||
this.HIDDENREGION_ID = pid
|
||||
requestFN(
|
||||
'/fireregion/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
CORPINFO_ID: this.getInfo().CORPINFO_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}, goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.getList()
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'listmanager:add,listmanager:del,listmanager:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.listmanagerfhadminadd // 新增权限
|
||||
this.del = data.listmanagerfhadmindel // 删除权限
|
||||
this.edit = data.listmanagerfhadminedit // 修改权限
|
||||
this.toExcel = data.toExcel // 导出到excel权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
getTreeList() {
|
||||
this.treeLoading = true
|
||||
requestFN(
|
||||
'/hiddenRegion/listAll',
|
||||
{}
|
||||
).then((data) => {
|
||||
this.treeLoading = false
|
||||
this.treeData = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
this.treeLoading = false
|
||||
})
|
||||
},
|
||||
goBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.returnBtn {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.app-container {
|
||||
display: flex; /**/
|
||||
align-items: baseline;
|
||||
}
|
||||
|
||||
.rightCont {
|
||||
width: 100%
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,131 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-form label-width="80px">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="企业名称">
|
||||
<el-input v-model="form.KEYWORDS" placeholder="请输入企业名称..."/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves type="primary" icon="el-icon-search" class="ml-10" @click="getList">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves type="success" icon="el-icon-refresh" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
ref="multipleTable"
|
||||
:data="list"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{'font-weight': 'bold','color': '#000'}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center"/>
|
||||
<el-table-column label="企业名称" align="center" prop="CORP_NAME"/>
|
||||
<el-table-column label="属地" align="center" prop="COMPANY_AREA"/>
|
||||
<el-table-column label="消防区域数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'FireRegion'})">
|
||||
{{ row.xiaoFangQuYuNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="消防点位数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'FirePoint'})">
|
||||
{{ row.xiaoFangDianWeiNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="消防器材数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'FireDevice'})">
|
||||
{{ row.xiaoFangQiCaiNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div/>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList()"/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
list: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
total: 0,
|
||||
authority: {
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false
|
||||
},
|
||||
form: {
|
||||
KEYWORDS: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true
|
||||
requestFN(
|
||||
'/fireReport/utilList?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page, this.form
|
||||
).then((data) => {
|
||||
this.list = data.list
|
||||
this.total = data.page.totalResult
|
||||
this.loading = false
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
getRowKey(row) {
|
||||
return row.CORPINFO_ID
|
||||
},
|
||||
resetting() {
|
||||
this.form.KEYWORDS = ''
|
||||
this.getList()
|
||||
},
|
||||
goControlRoomInfo(e) {
|
||||
this.setActiveName(e.TYPE)
|
||||
this.setInfo(e)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style>
|
||||
.tree_dialog .selectTree {
|
||||
width: 300px;
|
||||
}
|
||||
|
||||
.hide .el-upload--picture-card {
|
||||
display: none;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,46 @@
|
|||
<template>
|
||||
<component :is="parentObj.activeName"/>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list'
|
||||
import FireRegion from './components/fireRegion'
|
||||
import FirePoint from './components/firePoint.vue'
|
||||
import FireDevice from './components/fireDevice.vue'
|
||||
export default {
|
||||
components: {
|
||||
List, FireRegion, FirePoint, FireDevice
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
parentObj: {
|
||||
activeName: 'List',
|
||||
CORPINFO_ID: ''
|
||||
},
|
||||
info: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
setActiveName(activeName) {
|
||||
this.parentObj.activeName = activeName
|
||||
},
|
||||
getInfo() {
|
||||
return this.info
|
||||
},
|
||||
setInfo(e) {
|
||||
this.info = e
|
||||
}
|
||||
},
|
||||
provide() {
|
||||
return {
|
||||
parentObj: this.parentObj,
|
||||
setActiveName: this.setActiveName,
|
||||
getInfo: this.getInfo,
|
||||
setInfo: this.setInfo
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
|
@ -0,0 +1,169 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="rightCont">
|
||||
<el-form label-width="50px">
|
||||
<el-col :span="5">
|
||||
<el-form-item label="名称:" label-width="110px">
|
||||
<el-input v-model="form.FIRERESOURCES_NAME" style="width:206px" placeholder="请输入内容"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%">
|
||||
<el-table-column type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRERESOURCES_NAME" label="名称"/>
|
||||
<el-table-column prop="FIRERESOURCES_TYPENAME" label="消防资源类型"/>
|
||||
<el-table-column prop="LONGTITUDE" label="消防资源经纬度">
|
||||
<template slot-scope="{row}">
|
||||
{{ row.LONGTITUDE }} -- {{ row.LATITUDE }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="CREATIME" label="创建时间"/>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button @click="getBack">返回</el-button>
|
||||
</div>
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.page"
|
||||
:limit.sync="listQuery.limit"
|
||||
@pagination="getList()"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import TiandiMap from '../../../../components/TianMap/TiandiMap'
|
||||
|
||||
export default {
|
||||
components: { Pagination, SelectTree, TiandiMap },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
firekzsImgs: [],
|
||||
waitForDeleteImgs: [],
|
||||
dialogImageUrl: '',
|
||||
dialogVisible: false,
|
||||
dialogFormMap: false,
|
||||
map: null,
|
||||
corpList: [],
|
||||
marker: null,
|
||||
describeList: [
|
||||
{
|
||||
code: '',
|
||||
palce: '',
|
||||
name: '',
|
||||
type: '',
|
||||
corp: '',
|
||||
ramake: ''
|
||||
}
|
||||
],
|
||||
addBtnType: true,
|
||||
FIRE_RESOURCES_TYPE: '',
|
||||
listLoading: true,
|
||||
form: {
|
||||
FIRERESOURCES_NAME: '',
|
||||
FIRERESOURCES_TYPE: 'xfkzs01',
|
||||
CORPINFO_ID: ''
|
||||
},
|
||||
diaLoading: false,
|
||||
LONGTITUDE: '', // 经度
|
||||
LATITUDE: '', // 纬度
|
||||
treeData: [],
|
||||
typeData: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
// 树形菜单
|
||||
varList: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.form.CORPINFO_ID = this.getInfo().CORPINFO_ID
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.FIRE_DEVICE_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
this.varList = []
|
||||
requestFN(
|
||||
'/fireResources/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page, this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goKeyReset() {
|
||||
this.form.FIRERESOURCES_NAME = ''
|
||||
|
||||
this.getList()
|
||||
},
|
||||
getBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.returnBtn {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.app-container {
|
||||
display: flex; /**/
|
||||
align-items: baseline;
|
||||
}
|
||||
|
||||
.rightCont {
|
||||
width: 100%
|
||||
}
|
||||
|
||||
#map {
|
||||
width: 1000px;
|
||||
height: 500px;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,169 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="rightCont">
|
||||
<el-form label-width="50px">
|
||||
<el-col :span="5">
|
||||
<el-form-item label="名称:" label-width="110px">
|
||||
<el-input v-model="form.FIRERESOURCES_NAME" style="width:206px" placeholder="请输入内容"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%">
|
||||
<el-table-column type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRERESOURCES_NAME" label="名称"/>
|
||||
<el-table-column prop="FIRERESOURCES_TYPENAME" label="消防资源类型"/>
|
||||
<el-table-column prop="LONGTITUDE" label="消防资源经纬度">
|
||||
<template slot-scope="{row}">
|
||||
{{ row.LONGTITUDE }} -- {{ row.LATITUDE }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="CREATIME" label="创建时间"/>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button @click="getBack">返回</el-button>
|
||||
</div>
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.page"
|
||||
:limit.sync="listQuery.limit"
|
||||
@pagination="getList()"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import TiandiMap from '../../../../components/TianMap/TiandiMap'
|
||||
|
||||
export default {
|
||||
components: { Pagination, SelectTree, TiandiMap },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
firekzsImgs: [],
|
||||
waitForDeleteImgs: [],
|
||||
dialogImageUrl: '',
|
||||
dialogVisible: false,
|
||||
dialogFormMap: false,
|
||||
map: null,
|
||||
corpList: [],
|
||||
marker: null,
|
||||
describeList: [
|
||||
{
|
||||
code: '',
|
||||
palce: '',
|
||||
name: '',
|
||||
type: '',
|
||||
corp: '',
|
||||
ramake: ''
|
||||
}
|
||||
],
|
||||
addBtnType: true,
|
||||
FIRE_RESOURCES_TYPE: '',
|
||||
listLoading: true,
|
||||
form: {
|
||||
FIRERESOURCES_NAME: '',
|
||||
FIRERESOURCES_TYPE: 'xfbf01',
|
||||
CORPINFO_ID: ''
|
||||
},
|
||||
diaLoading: false,
|
||||
LONGTITUDE: '', // 经度
|
||||
LATITUDE: '', // 纬度
|
||||
treeData: [],
|
||||
typeData: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
// 树形菜单
|
||||
varList: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.form.CORPINFO_ID = this.getInfo().CORPINFO_ID
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.FIRE_DEVICE_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
this.varList = []
|
||||
requestFN(
|
||||
'/fireResources/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page, this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goKeyReset() {
|
||||
this.form.FIRERESOURCES_NAME = ''
|
||||
|
||||
this.getList()
|
||||
},
|
||||
getBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.returnBtn {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.app-container {
|
||||
display: flex; /**/
|
||||
align-items: baseline;
|
||||
}
|
||||
|
||||
.rightCont {
|
||||
width: 100%
|
||||
}
|
||||
|
||||
#map {
|
||||
width: 1000px;
|
||||
height: 500px;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,169 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="rightCont">
|
||||
<el-form label-width="50px">
|
||||
<el-col :span="5">
|
||||
<el-form-item label="名称:" label-width="110px">
|
||||
<el-input v-model="form.FIRERESOURCES_NAME" style="width:206px" placeholder="请输入内容"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%">
|
||||
<el-table-column type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRERESOURCES_NAME" label="名称"/>
|
||||
<el-table-column prop="FIRERESOURCES_TYPENAME" label="消防资源类型"/>
|
||||
<el-table-column prop="LONGTITUDE" label="消防资源经纬度">
|
||||
<template slot-scope="{row}">
|
||||
{{ row.LONGTITUDE }} -- {{ row.LATITUDE }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="CREATIME" label="创建时间"/>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button @click="getBack">返回</el-button>
|
||||
</div>
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.page"
|
||||
:limit.sync="listQuery.limit"
|
||||
@pagination="getList()"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import TiandiMap from '../../../../components/TianMap/TiandiMap'
|
||||
|
||||
export default {
|
||||
components: { Pagination, SelectTree, TiandiMap },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
firekzsImgs: [],
|
||||
waitForDeleteImgs: [],
|
||||
dialogImageUrl: '',
|
||||
dialogVisible: false,
|
||||
dialogFormMap: false,
|
||||
map: null,
|
||||
corpList: [],
|
||||
marker: null,
|
||||
describeList: [
|
||||
{
|
||||
code: '',
|
||||
palce: '',
|
||||
name: '',
|
||||
type: '',
|
||||
corp: '',
|
||||
ramake: ''
|
||||
}
|
||||
],
|
||||
addBtnType: true,
|
||||
FIRE_RESOURCES_TYPE: '',
|
||||
listLoading: true,
|
||||
form: {
|
||||
FIRERESOURCES_NAME: '',
|
||||
FIRERESOURCES_TYPE: 'xfsy01',
|
||||
CORPINFO_ID: ''
|
||||
},
|
||||
diaLoading: false,
|
||||
LONGTITUDE: '', // 经度
|
||||
LATITUDE: '', // 纬度
|
||||
treeData: [],
|
||||
typeData: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
// 树形菜单
|
||||
varList: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.form.CORPINFO_ID = this.getInfo().CORPINFO_ID
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.FIRE_DEVICE_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
this.varList = []
|
||||
requestFN(
|
||||
'/fireResources/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page, this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goKeyReset() {
|
||||
this.form.FIRERESOURCES_NAME = ''
|
||||
|
||||
this.getList()
|
||||
},
|
||||
getBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.returnBtn {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.app-container {
|
||||
display: flex; /**/
|
||||
align-items: baseline;
|
||||
}
|
||||
|
||||
.rightCont {
|
||||
width: 100%
|
||||
}
|
||||
|
||||
#map {
|
||||
width: 1000px;
|
||||
height: 500px;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,131 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-form label-width="80px">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="企业名称">
|
||||
<el-input v-model="form.KEYWORDS" placeholder="请输入企业名称..."/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves type="primary" icon="el-icon-search" class="ml-10" @click="getList">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves type="success" icon="el-icon-refresh" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
ref="multipleTable"
|
||||
:data="list"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{'font-weight': 'bold','color': '#000'}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center"/>
|
||||
<el-table-column label="企业名称" align="center" prop="CORP_NAME"/>
|
||||
<el-table-column label="属地" align="center" prop="COMPANY_AREA"/>
|
||||
<el-table-column label="消防控制室数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'FireControlRoom'})">
|
||||
{{ row.xiaoFangKongZhiShiNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="消防泵房数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'FirePumpRoom'})">
|
||||
{{ row.xiaoFangBengFangNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="消防水源数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'FireResources'})">
|
||||
{{ row.xiaoFangShuiYuanNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div/>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList()"/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
list: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
total: 0,
|
||||
authority: {
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false
|
||||
},
|
||||
form: {
|
||||
KEYWORDS: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true
|
||||
requestFN(
|
||||
'/fireReport/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page, this.form
|
||||
).then((data) => {
|
||||
this.list = data.list
|
||||
this.total = data.page.totalResult
|
||||
this.loading = false
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
getRowKey(row) {
|
||||
return row.CORPINFO_ID
|
||||
},
|
||||
resetting() {
|
||||
this.form.KEYWORDS = ''
|
||||
this.getList()
|
||||
},
|
||||
goControlRoomInfo(e) {
|
||||
this.setActiveName(e.TYPE)
|
||||
this.setInfo(e)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style>
|
||||
.tree_dialog .selectTree {
|
||||
width: 300px;
|
||||
}
|
||||
|
||||
.hide .el-upload--picture-card {
|
||||
display: none;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,46 @@
|
|||
<template>
|
||||
<component :is="parentObj.activeName"/>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list'
|
||||
import FirePumpRoom from './components/firePumpRoom'
|
||||
import FireResources from './components/fireResources.vue'
|
||||
import FireControlRoom from './components/fireControlRoom.vue'
|
||||
export default {
|
||||
components: {
|
||||
List, FirePumpRoom, FireResources, FireControlRoom
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
parentObj: {
|
||||
activeName: 'List',
|
||||
CORPINFO_ID: ''
|
||||
},
|
||||
info: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
setActiveName(activeName) {
|
||||
this.parentObj.activeName = activeName
|
||||
},
|
||||
getInfo() {
|
||||
return this.info
|
||||
},
|
||||
setInfo(e) {
|
||||
this.info = e
|
||||
}
|
||||
},
|
||||
provide() {
|
||||
return {
|
||||
parentObj: this.parentObj,
|
||||
setActiveName: this.setActiveName,
|
||||
getInfo: this.getInfo,
|
||||
setInfo: this.setInfo
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
|
@ -0,0 +1,485 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-form label-width="120px">
|
||||
<el-row>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="检查项关键字" label-width="120px">
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="消防器材类型">
|
||||
<el-select v-model="FIRE_DEVICE_TYPE" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in typeData"
|
||||
:key="item.NAME"
|
||||
:label="item.NAME"
|
||||
:value="item.BIANMA"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="20px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item style="text-align: right">
|
||||
<el-button v-waves class="filter-item" type="info" icon="el-icon-bottom-right" size="mini" plain @click="dialogFormDaoru = true">
|
||||
导入
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<el-table v-loading="listLoading" ref="multipleTable" :data="varList" :row-key="getRowKey" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center" />
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="DEVICE_NAME" label="消防器材名称" />
|
||||
<el-table-column prop="DEVICE_TYPE_NAME" label="消防器材类型" />
|
||||
<el-table-column prop="FIRE_CHECK_STANDARD_ITEM" label="检查项" />
|
||||
<el-table-column prop="EMPLOYER" label="单位名称" />
|
||||
<el-table-column prop="OPERATTIME" label="导入时间" />
|
||||
<el-table-column label="操作" align="center" width="450">
|
||||
<template slot-scope="{row}">
|
||||
<el-button v-show="edit" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row.FIRE_CHECK_STANDARD_ID)">编辑</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.FIRE_CHECK_STANDARD_ID)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
|
||||
<el-dialog :visible.sync="dialogFormEdit" :title="dialogType==='edit'?'修改':'新增'" width="600px">
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="120px" style="width: 500px;">
|
||||
<el-form-item label="请选择设备类型" prop="FIRE_DEVICE_TYPE">
|
||||
<el-select v-model="form.FIRE_DEVICE_TYPE" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in typeData"
|
||||
:key="item.NAME"
|
||||
:label="item.NAME"
|
||||
:value="item.BIANMA"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="消防器材名称" prop="DEVICE_NAME">
|
||||
<el-input id="DEVICE_NAME" ref="DEVICE_NAME" v-model="form.DEVICE_NAME" maxlength="255" placeholder="这里输入..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="单位名称" prop="EMPLOYER">
|
||||
<el-input id="EMPLOYER" ref="EMPLOYER" v-model="form.EMPLOYER" maxlength="255" placeholder="这里输入..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="检查项" prop="FIRE_CHECK_STANDARD_ITEM">
|
||||
<el-input id="FIRE_CHECK_STANDARD_ITEM" ref="FIRE_CHECK_STANDARD_ITEM" v-model="form.FIRE_CHECK_STANDARD_ITEM" type="textarea"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormEdit = false">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog :visible.sync="dialogFormDaoru" title="导入" width="800px">
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form ref="form" :model="daoruFrom" :rules="rules" label-width="120px" class="in-uploader">
|
||||
<el-form-item label="请选择设备类型" prop="importType">
|
||||
<el-select v-model="daoruFrom.FIRE_DEVICE_TYPE" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in typeData"
|
||||
:key="item.NAME"
|
||||
:label="item.NAME"
|
||||
:value="item.BIANMA"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="上传附件" prop="FIELDS">
|
||||
<div class="uploader">
|
||||
<el-input v-model="daoruFrom.FFILEName" :disabled="true" />
|
||||
<el-upload :before-upload="beforeFileUpload" class="avatar-uploader" action="#">
|
||||
<el-button type="primary" icon="el-icon-upload" style="margin-left:10px">上传附件</el-button>
|
||||
</el-upload>
|
||||
<el-button v-waves type="success" icon="el-icon-right" style="margin-left:10px;width:150px" @click="getExcelModel">
|
||||
导出模板
|
||||
</el-button>
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
</template>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormDaoru = false">取 消</el-button>
|
||||
<el-button type="primary" @click="goUpload">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<div v-html="styleText" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import vueQr from 'vue-qr'
|
||||
import { upload } from '@/utils/upload'
|
||||
import { Message } from 'element-ui'
|
||||
export default {
|
||||
components: { Pagination, SelectTree, vueQr },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
styleText: '<style type="text/css" media="print">\n' + ' @page { size: landscape; }\n' + '</style>',
|
||||
config: config,
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
total: 0,
|
||||
KEYWORDS: this.$route.query.KEYWORDS || '',
|
||||
DEPARTMENT_ID: '',
|
||||
varList: [],
|
||||
pd: {
|
||||
RISKUNITNAME: '',
|
||||
DEPT_NAME: '',
|
||||
HEADMAN: '',
|
||||
CORP_NAME: ''
|
||||
},
|
||||
qrcodeStr: '',
|
||||
form: {
|
||||
FIRE_CHECK_STANDARD_ID: '',
|
||||
EMPLOYER: '',
|
||||
FIRE_CHECK_STANDARD_ITEM: '',
|
||||
DEVICE_NAME: '',
|
||||
FIRE_DEVICE_TYPE: ''
|
||||
},
|
||||
rules: {
|
||||
FIRE_DEVICE_TYPE: [{ required: true, message: '设备类型不能为空', trigger: 'blur' }],
|
||||
DEVICE_NAME: [{ required: true, message: '设备名不能为空', trigger: 'blur' }],
|
||||
importType: [{ required: true, message: '请选择器材类型', trigger: 'blur' }],
|
||||
FIELDS: [{ required: true, message: '请选择文件', trigger: 'blur' }],
|
||||
FIRE_CHECK_STANDARD_ITEM: [{ required: true, message: '检查标准不能为空', trigger: 'blur' }],
|
||||
EMPLOYER: [{ required: true, message: '单位名称不能为空', trigger: 'blur' }]
|
||||
},
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
},
|
||||
treeData: [],
|
||||
typeData: [],
|
||||
multipleSelectionAll: [], // 所有选中的数据包含跨页数据
|
||||
multipleSelection: [], // 当前页选中的数据
|
||||
dialogFormEdit: false,
|
||||
dialogFormShow: false,
|
||||
dialogType: 'add',
|
||||
FIRE_DEVICE_TYPE: '',
|
||||
dialogFormDaoru: false,
|
||||
daoruFrom: {
|
||||
FFILE: '',
|
||||
FFILEName: '',
|
||||
FIRE_DEVICE_TYPE: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getDict()
|
||||
this.getTreeList()
|
||||
},
|
||||
methods: {
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
getRowKey(row) {
|
||||
return row.FIRE_CHECK_STANDARD_ID
|
||||
},
|
||||
getTreeList() {
|
||||
requestFN(
|
||||
'/department/listTree',
|
||||
{}
|
||||
).then((data) => {
|
||||
this.treeData = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
})
|
||||
},
|
||||
// 搜索
|
||||
getuery() {
|
||||
this.getList()
|
||||
},
|
||||
goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.FIRE_DEVICE_TYPE = ''
|
||||
this.getQuery()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/fireCheckStandard/getList?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
FIRE_DEVICE_TYPE: this.FIRE_DEVICE_TYPE,
|
||||
CORPINFO_ID: this.getInfo().CORPINFO_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
// 添加
|
||||
handleAdd() {
|
||||
this.dialogType = 'add'
|
||||
this.dialogFormEdit = true
|
||||
this.resetForm()
|
||||
this.$refs.deptTree.clearHandle()
|
||||
this.getDict()
|
||||
},
|
||||
// 修改
|
||||
handleEdit(ID) {
|
||||
this.getDict()
|
||||
this.dialogType = 'edit'
|
||||
console.log(ID)
|
||||
requestFN(
|
||||
'/fireCheckStandard/getInfo',
|
||||
{
|
||||
FIRE_CHECK_STANDARD_ID: ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.form = Object.assign({}, data.res) // copy obj
|
||||
const node = {}
|
||||
node.id = this.form.FIRE_DEVICE_TYPE
|
||||
this.dialogFormEdit = true
|
||||
this.$refs.deptTree.clearHandle()
|
||||
this.$nextTick(() => { // 此处使用这个可以等节点渲染后再获取节点
|
||||
this.$refs.deptTree.handleNodeClick(node)
|
||||
})
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
// 保存
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/fireCheckStandard/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.dialogFormEdit = false
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
beforeFileUpload(file) {
|
||||
this.daoruFrom.FFILE = file
|
||||
this.daoruFrom.FFILEName = file.name
|
||||
this.$forceUpdate()
|
||||
return false
|
||||
},
|
||||
goUpload() {
|
||||
if (this.daoruFrom.FFILE === '') {
|
||||
this.$message({
|
||||
message: '必须选择文件',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
if (this.daoruFrom.FIRE_DEVICE_TYPE === '') {
|
||||
this.$message({
|
||||
message: '必须选择设备类型',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const formData = new FormData()
|
||||
Object.keys(this.daoruFrom).map(key => {
|
||||
formData.append(key, this.daoruFrom[key])
|
||||
})
|
||||
upload(
|
||||
'/fireCheckStandard/importExcelTemplate',
|
||||
formData
|
||||
).then((data) => {
|
||||
if (data.msg) {
|
||||
Message({
|
||||
message: data.msg,
|
||||
type: data.type,
|
||||
duration: 5 * 1000
|
||||
})
|
||||
}
|
||||
this.dialogFormDaoru = false
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
getExcelModel() {
|
||||
this.$confirm('确定要下载excel模板吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = false
|
||||
window.location.href = config.httpurl + 'fireCheckStandard/excelModel'
|
||||
}).catch(() => {
|
||||
this.listLoading = false
|
||||
})
|
||||
this.listLoading = false
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/fireCheckStandard/delByIds',
|
||||
{
|
||||
DATA_IDS: id
|
||||
}
|
||||
).then((res) => {
|
||||
if (res.result === 'success') {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
}
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
|
||||
batchDel() {
|
||||
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.FIRE_CHECK_STANDARD_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/fireCheckStandard/delByIds',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
// 判断按钮权限,用于是否显示按钮
|
||||
hasButton() {
|
||||
var keys = 'riskunit:add,riskunit:del,riskunit:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.riskunitfhadminadd // 新增权限
|
||||
this.del = data.riskunitfhadmindel // 删除权限
|
||||
this.edit = data.riskunitfhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
// 获取数据字典数据
|
||||
getDict() {
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '249151f04fd64132a949fdd430a7b9c5'
|
||||
}
|
||||
).then((data) => {
|
||||
this.typeData = data.list
|
||||
console.log(this.typeData)
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
this.form = {
|
||||
FIRE_CHECK_STANDARD_ID: '',
|
||||
EMPLOYER: '',
|
||||
FIRE_CHECK_STANDARD_ITEM: '',
|
||||
DEVICE_NAME: '',
|
||||
FIRE_DEVICE_TYPE: ''
|
||||
}
|
||||
},
|
||||
goDetail(row) {
|
||||
this.$parent.activeName = 'Info'
|
||||
this.$parent.RISKUNIT_ID = row.RISKUNIT_ID
|
||||
this.$parent.RISKUNITNAME = row.RISKUNITNAME
|
||||
this.$parent.DEPT_NAME = row.DEPT_NAME
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style lang="sass" scoped>
|
||||
.table-qrcode
|
||||
text-align: center
|
||||
padding-top: 20px
|
||||
width: 100%
|
||||
.filter-container
|
||||
position: relative
|
||||
.filter-flot
|
||||
position: absolute
|
||||
right: 0
|
||||
top: 0
|
||||
.uploader
|
||||
width: 570px
|
||||
display: flex
|
||||
align-items: center
|
||||
.el-form-item__content
|
||||
line-height: 1
|
||||
</style>
|
|
@ -0,0 +1,315 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-form label-width="120px">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="检查表名称">
|
||||
<el-input v-model="KEYWORDS" placeholder="请输入关键字" class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="周期内检查状态">
|
||||
<el-select v-model="STATUS" placeholder="请选择" style="width: 100%;">
|
||||
<el-option v-for="item in statusList" :key="item.ID" :label="item.NAME" :value="item.ID" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="部门">
|
||||
<SelectTree ref="deptTree_Select" :clearable="false" :options="treeData" :props="defaultProps" v-model="DEPARTMENT_ID" placeholder="请选择部门" style="width: 100%;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="人员">
|
||||
<el-input v-model="USERNAME" placeholder="这里输入人员" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="排查周期">
|
||||
<el-select v-model="PERIOD" placeholder="请选择" style="width: 100%;">
|
||||
<el-option v-for="item in periodList" :key="item.BIANMA" :label="item.NAME" :value="item.BIANMA" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div>
|
||||
<el-table v-loading="listLoading" ref="multipleTable" :data="varList" :row-key="getRowKey" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
|
||||
<el-table-column :reserve-selection="true" :selectable="selectable" type="selection" width="55" align="center" />
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="FIRE_CHECK_STANDARD_NAME" label="检查表名称" />
|
||||
<el-table-column prop="DEPARTMENT_NAME" label="部门" />
|
||||
<el-table-column prop="USER_NAME" label="人员" width="90" align="center" show-overflow-tooltip />
|
||||
<el-table-column prop="PERIODNAME" label="排查周期" width="90" align="center" />
|
||||
<el-table-column prop="DATESTART" label="周期" width="260" align="center"/>
|
||||
<el-table-column prop="COUNT" label="检查次数" width="90" align="center" />
|
||||
<el-table-column prop="checkCount" label="周期内次数" width="120" align="center" show-overflow-tooltip>
|
||||
<template slot-scope="{row}">
|
||||
<template v-if="row.checkCount == 0">
|
||||
<span class="color-red">{{ row.checkCount }}/1</span>
|
||||
</template>
|
||||
<template v-if="row.checkCount != 0">
|
||||
<span>{{ row.checkCount }}/1</span>
|
||||
</template>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="STATE" label="清单状态" width="90" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<template v-if="row.STATE == 1">
|
||||
禁用
|
||||
</template>
|
||||
<template v-if="row.STATE == 0">
|
||||
启用
|
||||
</template>
|
||||
<template v-if="row.STATE == 2">
|
||||
已删除
|
||||
</template>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column v-if="false" label="操作" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<el-button type="primary" icon="el-icon-tickets" size="mini" @click="goDetail(row.FIRE_CHECK_ID,row.FIRE_RECORD_ID)">检查记录</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div >
|
||||
<el-button @click="getBack">返 回</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
export default {
|
||||
|
||||
components: { Pagination, SelectTree },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
ls: [],
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
},
|
||||
tableData: [{
|
||||
number: '1',
|
||||
listname: '菜市场上厕所从上次说',
|
||||
bm: '海洋肥料车间(一期) ',
|
||||
gw: '海洋肥料车间(一期)班长',
|
||||
ry: '',
|
||||
pczq: ' 每周',
|
||||
zq: '2021-06-07 00:00:00-2021-06-13 23:59:59',
|
||||
jccs: '1',
|
||||
yhs: '1',
|
||||
qdlx: '日常',
|
||||
qdzt: '启用'
|
||||
}],
|
||||
STARTTIME: '',
|
||||
ENDTIME: '',
|
||||
DEPARTMENT_ID: '',
|
||||
USERNAME: '',
|
||||
periodList: [],
|
||||
typeList: [],
|
||||
PERIOD: '',
|
||||
OVERTIME: '',
|
||||
TYPE: '',
|
||||
statusList: [
|
||||
{ ID: '', NAME: '请选择' },
|
||||
{ ID: '0', NAME: '未检查' },
|
||||
{ ID: '1', NAME: '已检查' }
|
||||
],
|
||||
STATUS: '',
|
||||
hasHiddenList: [
|
||||
{ ID: '', NAME: '请选择' },
|
||||
{ ID: '0', NAME: '无隐患' },
|
||||
{ ID: '1', NAME: '有隐患' }
|
||||
],
|
||||
HASHIDDEN: '',
|
||||
listingLevelList: [
|
||||
{ 'BIANMA': '', 'NAME': '请选择' },
|
||||
{ 'BIANMA': '1', 'NAME': '公司' }
|
||||
],
|
||||
overTimeList: [
|
||||
{ ID: '', NAME: '请选择' },
|
||||
{ ID: '1', NAME: '无超期' },
|
||||
{ ID: '0', NAME: '有超期' }
|
||||
],
|
||||
LISTINGLEVEL: '',
|
||||
treeData: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getTreeData()
|
||||
this.getDict()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.FIRE_CHECK_ID
|
||||
},
|
||||
selectable(row, index) {
|
||||
return row.STATE == 2
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
getTreeData() {
|
||||
requestFN(
|
||||
'/department/listTree',
|
||||
{}
|
||||
).then((data) => {
|
||||
this.treeData = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
})
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/fireRecord/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
STARTTIME: this.dates[0],
|
||||
ENDTIME: this.dates[1],
|
||||
DEPARTMENT_ID: this.DEPARTMENT_ID,
|
||||
USERNAME: this.USERNAME,
|
||||
PERIOD: this.PERIOD,
|
||||
TYPE: this.TYPE,
|
||||
STATUS: this.STATUS,
|
||||
OVERTIME: this.OVERTIME,
|
||||
HASHIDDEN: this.HASHIDDEN,
|
||||
LISTINGLEVEL: this.LISTINGLEVEL,
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
tm: new Date().getTime(),
|
||||
CORPINFO_ID: this.getInfo().CORPINFO_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.ls = data.ls
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
this.pd = data.pd
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}, goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.USERNAME = ''
|
||||
this.PERIOD = ''
|
||||
this.STATUS = ''
|
||||
this.LISTINGLEVEL = ''
|
||||
this.OVERTIME = ''
|
||||
this.TYPE = ''
|
||||
this.STARTTIME = ''
|
||||
this.ENDTIME = ''
|
||||
this.dates = []
|
||||
this.$refs.deptTree_Select.clearHandle()
|
||||
this.DEPARTMENT_ID = ''
|
||||
this.getList()
|
||||
this.getTreeData()
|
||||
this.getDict()
|
||||
}, getDict() {
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '4a3d0d99b0ea4e268c11dd0b18866917'
|
||||
}
|
||||
).then((data) => {
|
||||
this.typeList = data.list
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: 'f60cf0e8315b4993b6d6049dd29f2ba5'
|
||||
}
|
||||
).then((data) => {
|
||||
this.periodList = data.list
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
|
||||
requestFN(
|
||||
'dictionaries/getLevels',
|
||||
{
|
||||
DICTIONARIES_ID: '4a661fa8aedc4d158c9cddaa9d2ec47e'
|
||||
}
|
||||
).then((data) => {
|
||||
this.listingLevelList = this.listingLevelList.concat(data.list)
|
||||
})
|
||||
.catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
goDetail(id, FIRE_RECORD_ID) {
|
||||
this.setActiveName('RecordInfo')
|
||||
const info = this.getInfo()
|
||||
info.FIRE_CHECK_ID = id
|
||||
info.FIRE_RECORD_ID = FIRE_RECORD_ID
|
||||
this.setInfo(info)
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'checkrecord:add,checkrecord:del,checkrecord:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.checkrecordfhadminadd // 新增权限
|
||||
this.del = data.checkrecordfhadmindel // 删除权限
|
||||
this.edit = data.checkrecordfhadminedit // 修改权限
|
||||
this.toExcel = data.toExcel // 导出到excel权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
getBack() {
|
||||
this.setActiveName('List')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
|
@ -0,0 +1,117 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-form label-width="80px">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="企业名称">
|
||||
<el-input v-model="form.KEYWORDS" placeholder="请输入企业名称..."/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves type="primary" icon="el-icon-search" class="ml-10" @click="getList">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves type="success" icon="el-icon-refresh" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
ref="multipleTable"
|
||||
:data="list"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{'font-weight': 'bold','color': '#000'}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center"/>
|
||||
<el-table-column label="企业名称" align="center" prop="CORP_NAME"/>
|
||||
<el-table-column label="属地" align="center" prop="COMPANY_AREA"/>
|
||||
<el-table-column label="检查次数" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<div class="link-type" @click="goControlRoomInfo({CORPINFO_ID:row.CORPINFO_ID,TYPE:'fireRecord'})">
|
||||
{{ row.xiaoJianChaNum }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div/>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList()"/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
list: [],
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
total: 0,
|
||||
authority: {
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false
|
||||
},
|
||||
form: {
|
||||
KEYWORDS: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true
|
||||
requestFN(
|
||||
'/fireReport/recordList?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page, this.form
|
||||
).then((data) => {
|
||||
this.list = data.list
|
||||
this.total = data.page.totalResult
|
||||
this.loading = false
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
getRowKey(row) {
|
||||
return row.CORPINFO_ID
|
||||
},
|
||||
resetting() {
|
||||
this.form.KEYWORDS = ''
|
||||
this.getList()
|
||||
},
|
||||
goControlRoomInfo(e) {
|
||||
this.setActiveName(e.TYPE)
|
||||
this.setInfo(e)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style>
|
||||
.tree_dialog .selectTree {
|
||||
width: 300px;
|
||||
}
|
||||
|
||||
.hide .el-upload--picture-card {
|
||||
display: none;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,431 @@
|
|||
<template>
|
||||
<div>
|
||||
<div id="printTest" class="app-contprint print-midi">
|
||||
<div class="level-title">
|
||||
<h1>点位检查表基础信息</h1>
|
||||
</div>
|
||||
<div class="mb-20">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">点检表名称</td>
|
||||
<td colspan="3">{{ form.FIRE_CHECK_STANDARD_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">所属部门</td>
|
||||
<td>{{ form.DEPARTMENTNAME }}</td>
|
||||
<td class="tbg">所属岗位</td>
|
||||
<td>{{ form.POSTNAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">排查周期</td>
|
||||
<td>{{ form.FIRE_CHECK_TYPE_NAME }}</td>
|
||||
<td class="tbg">责任人</td>
|
||||
<td>{{ form.USERNAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">检查时间</td>
|
||||
<td>{{ recordBase.CHECK_TIME }}</td>
|
||||
<td class="tbg">检查周期</td>
|
||||
<td v-if="form.FIRE_CHECK_TYPE !== 'checkPeriod0001'"> {{ recordBase.PERIODSTART.split(" ")[0] }}~{{ recordBase.PERIODEND.split(" ")[0] }}</td>
|
||||
<td v-else> {{ recordBase.PERIODSTART.split(" ")[0] }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">检查情况</td>
|
||||
<td>
|
||||
<template v-if="recordBase.FINISHED===1">
|
||||
已检查
|
||||
</template>
|
||||
<template v-else>
|
||||
未检查
|
||||
</template>
|
||||
</td>
|
||||
<td class="tbg">检查人</td>
|
||||
<td>{{ recordBase.USER_NAME }}</td>
|
||||
</tr>
|
||||
<tr v-if="qianming != ''">
|
||||
<td class="tbg">签字</td>
|
||||
<td colspan="3">
|
||||
<img :src="qianming" style="width: 200px;height: 97px;">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="level-title">
|
||||
<h1>检查内容</h1>
|
||||
</div>
|
||||
<div class="mb-20">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<th width="55" style="text-align:center">序号</th>
|
||||
<th>消防区域</th>
|
||||
<th>消防点位</th>
|
||||
<th>消防设备编号</th>
|
||||
<th>检查情况</th>
|
||||
<th>点位检查照片</th>
|
||||
<!-- <th>点位合格照片</th>-->
|
||||
</tr>
|
||||
<template v-if="varList.length !== 0">
|
||||
<tr v-for="(data,index) in varList" :key="index">
|
||||
<td align="center">{{ index+1 }}</td>
|
||||
<td>{{ data.FIRE_REGION_NAME }}</td>
|
||||
<td>{{ data.FIRE_POINT_NAME }}</td>
|
||||
<td>{{ data.FIRE_DEVICE_CODE }}</td>
|
||||
<template v-if="data.ISNORMAL==0">
|
||||
<template>
|
||||
<td class="text-center" >
|
||||
<a style="text-decoration: underline" @click="handelShowCheck(data.fireDeviceTypeList)">合格</a>
|
||||
</td>
|
||||
</template>
|
||||
</template>
|
||||
<template v-else-if="data.ISNORMAL==1 || data.ISNORMAL==3">
|
||||
<td class="text-center" ><a style="text-decoration: underline" @click="goHidden(data.HIDDEN_ID)">不合格</a></td>
|
||||
</template>
|
||||
<template v-else-if="data.ISNORMAL==2">
|
||||
<td class="text-center" ><a style="text-decoration: underline">不涉及</a></td>
|
||||
</template>
|
||||
<template v-else-if="data.ISNORMAL==2">
|
||||
<td class="text-center" ><a style="text-decoration: underline">不涉及</a></td>
|
||||
</template>
|
||||
<template v-else>
|
||||
<td class="text-center" />
|
||||
</template>
|
||||
<template>
|
||||
<td v-if="data.INDEX_F == '1'" :rowspan="data.ROWSPAN" class="text-center">
|
||||
<a style="text-decoration: underline" @click="qualified(data.EQUIPMENT_POINT_ID,14)">点位检查照片</a>
|
||||
</td>
|
||||
</template>
|
||||
<!-- <template>-->
|
||||
<!-- <td v-if="data.INDEX_F == '1'" :rowspan="data.ROWSPAN" class="text-center">-->
|
||||
<!-- <a style="text-decoration: underline" @click="qualified(data.QUALIFIED_PHOTOS_ID,115)">点位合格照片</a>-->
|
||||
<!-- </td>-->
|
||||
<!-- </template>-->
|
||||
</tr>
|
||||
</template>
|
||||
<template v-else>
|
||||
<tr>
|
||||
<td colspan="7" style="text-align: center">暂无数据</td>
|
||||
</tr>
|
||||
</template>
|
||||
</table>
|
||||
</div>
|
||||
<div class="mb-20">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<th width="55" style="text-align:center">序号</th>
|
||||
<th width="100">设备编号</th>
|
||||
<th>隐患描述</th>
|
||||
<th v-if="otherHiddenList.length !== 0" width="200">操作</th>
|
||||
</tr>
|
||||
<template v-if="otherHiddenList.length !== 0">
|
||||
<tr v-for="(data,index) in otherHiddenList" :key="index">
|
||||
<td align="center">{{ index+1 }}</td>
|
||||
<td>{{ data.FIRE_DEVICE_CODE }}</td>
|
||||
<td>{{ data.HIDDENDESCR }}</td>
|
||||
<td class="noprint">
|
||||
<el-button icon="el-icon-view" size="mini" @click="goHidden(data.HIDDEN_ID)">查看</el-button>
|
||||
</td>
|
||||
</tr>
|
||||
</template>
|
||||
<template v-else>
|
||||
<tr>
|
||||
<td colspan="3" style="text-align: center">暂无数据</td>
|
||||
</tr>
|
||||
</template>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui-height" />
|
||||
<div class="ui-foot">
|
||||
<el-button v-print="'#printTest'" type="primary">打 印</el-button>
|
||||
<el-button plain type="info" @click="back">返 回</el-button>
|
||||
</div>
|
||||
|
||||
<!--检查项数组-->
|
||||
<el-dialog :visible.sync="checkShow" title="检查项列表" width="80%">
|
||||
<div>
|
||||
<el-table
|
||||
ref="multipleTableRisk"
|
||||
:data="csList"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%;">
|
||||
<el-table-column type="index" label="序号" width="55" align="center"/>
|
||||
<el-table-column prop="FIRE_CHECK_STANDARD_ITEM" label="检查项"/>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button plain type="info" @click="closAddOtherPoint">返 回</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<!--检查照片-->
|
||||
<el-dialog :visible.sync="dialogImgVisible" title="检查照片">
|
||||
<el-form ref="imgForm" :model="imgForm" label-width="140px" style="padding:0 20px">
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="检查照片:">
|
||||
<div class="disContent">
|
||||
<div v-for="(item, index) in qualifiedImgs" :key="index" class="img-div">
|
||||
<img :src="config.fileUrl + item.FILEPATH" alt="">
|
||||
<div class="disContent-hide">
|
||||
<el-tooltip class="item" effect="dark" content="预览" placement="top">
|
||||
<span class="el-icon-zoom-in yuLan">
|
||||
<viewer :images="qualifiedImgs">
|
||||
<img :src="config.fileUrl + item.FILEPATH" alt="" class="yuLanImg">
|
||||
</viewer>
|
||||
</span>
|
||||
</el-tooltip>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogImgVisible = false">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<information ref="information"/>
|
||||
<div v-html="styleText" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import information from '../../../hiddenUtil/information.vue'
|
||||
export default {
|
||||
components: { Pagination, SelectTree, information },
|
||||
inject: ['setActiveName', 'getInfo', 'setInfo'],
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
styleText: '<style type="text/css" media="print">\n' + ' @page { size: landscape; }\n' + '</style>',
|
||||
SHOW_OR_EDIT: '',
|
||||
treeData: [],
|
||||
FIRE_RECORD_ID: '',
|
||||
config: config,
|
||||
imgForm: {},
|
||||
checkShow: false,
|
||||
csList: [],
|
||||
qualifiedImgs: [],
|
||||
qualifiedFiles: [],
|
||||
dialogImgVisible: false,
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
},
|
||||
form: '',
|
||||
pd: {
|
||||
CHECK_TIME: '',
|
||||
DEPARTMENT_ID: '',
|
||||
USER_ID: ''
|
||||
},
|
||||
recordBase: '',
|
||||
qianming: '',
|
||||
otherHiddenList: [],
|
||||
varList: [],
|
||||
// myself
|
||||
FIRE_CHECK_ID: '',
|
||||
expireTimeOPtion: {
|
||||
disabledDate(time) {
|
||||
return time.getTime() > Date.now() // 如果没有后面的-8.64e7就是不可以选择今天的
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
created() {
|
||||
this.FIRE_CHECK_ID = this.getInfo().FIRE_CHECK_ID
|
||||
this.FIRE_RECORD_ID = this.getInfo().FIRE_RECORD_ID
|
||||
this.SHOW_OR_EDIT = this.$parent.SHOW_OR_EDIT
|
||||
this.recordBase = Object.assign({}, this.$parent.row)
|
||||
this.getData()
|
||||
this.getSignImgs(this.FIRE_RECORD_ID)
|
||||
},
|
||||
methods: {
|
||||
// 合格上传照片
|
||||
qualified(id, TYPE) {
|
||||
if (id) {
|
||||
this.qualifiedImgs = [] // 合格检查项照片
|
||||
this.getQualifiedImgs(id, TYPE)
|
||||
} else {
|
||||
this.$message.warning('暂无照片')
|
||||
}
|
||||
},
|
||||
handelShowCheck(varList) {
|
||||
this.checkShow = true
|
||||
this.csList = []
|
||||
this.csList = varList
|
||||
},
|
||||
closAddOtherPoint() {
|
||||
this.checkShow = false
|
||||
},
|
||||
getQualifiedImgs(EQUIPMENT_RECORD_ID, TYPE) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/imgfiles/listImgs',
|
||||
{
|
||||
FOREIGN_KEY: EQUIPMENT_RECORD_ID,
|
||||
TYPE: TYPE
|
||||
}
|
||||
).then((data) => {
|
||||
this.qualifiedImgs = data.imgs
|
||||
if (this.qualifiedImgs.length > 0) {
|
||||
// 有照片 展示
|
||||
this.dialogImgVisible = true
|
||||
} else {
|
||||
// 无照片 提示
|
||||
this.$message({
|
||||
message: '无检查照片',
|
||||
type: 'error'
|
||||
})
|
||||
}
|
||||
this.listLoading = false
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
getSignImgs(FIRE_RECORD_ID) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/imgfiles/listImgs',
|
||||
{
|
||||
FOREIGN_KEY: FIRE_RECORD_ID,
|
||||
TYPE: '13'
|
||||
}
|
||||
).then((data) => {
|
||||
this.qianming = this.config.fileUrl + data.imgs[0].FILEPATH
|
||||
this.listLoading = false
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goHidden(id) {
|
||||
this.$refs.information.init(id)
|
||||
},
|
||||
back() {
|
||||
this.$parent.activeName = 'RecordList'
|
||||
},
|
||||
// 获取详情
|
||||
getData() {
|
||||
this.listLoading = true
|
||||
// 获取基础信息
|
||||
requestFN(
|
||||
'/fireRecord/getInfo',
|
||||
{
|
||||
FIRE_CHECK_ID: this.FIRE_CHECK_ID,
|
||||
FIRE_RECORD_ID: this.FIRE_RECORD_ID,
|
||||
CORPINFO_ID: this.getInfo().CORPINFO_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.form = data.res// copy obj
|
||||
this.varList = data.varList
|
||||
if (data.otherHiddenList !== null) {
|
||||
this.otherHiddenList = data.otherHiddenList
|
||||
}
|
||||
|
||||
// 隐患待添加
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="sass" scoped>
|
||||
.avatar-uploader
|
||||
ul
|
||||
margin: 0
|
||||
li
|
||||
padding: 0
|
||||
.el-dialog__body
|
||||
padding: 0
|
||||
.map-flex
|
||||
display: flex
|
||||
width: 500px
|
||||
align-items: center
|
||||
|
||||
.ud-flex
|
||||
display: flex
|
||||
.form-group
|
||||
display: flex
|
||||
align-items: center
|
||||
.form-label
|
||||
padding: 0px 15px
|
||||
font-size: 14px
|
||||
width: 240px
|
||||
font-weight: 400
|
||||
text-align: right
|
||||
margin-bottom: 18px
|
||||
.star
|
||||
color: red
|
||||
padding-right: 4px
|
||||
.input-block
|
||||
display: flex
|
||||
|
||||
.disContent
|
||||
display: flex
|
||||
align-items: center
|
||||
flex-wrap: wrap
|
||||
.img-div
|
||||
position: relative
|
||||
margin: 0 10px 0px 0
|
||||
width: 108px
|
||||
height: 108px
|
||||
border-radius: 4px
|
||||
overflow: hidden
|
||||
&>img
|
||||
width: 100%
|
||||
height: 100%
|
||||
|
||||
.disContent-hide
|
||||
position: absolute
|
||||
width: 100%
|
||||
height: 100%
|
||||
border-radius: 4px
|
||||
background-color: rgba(48, 48, 48, 0.59)
|
||||
display: none
|
||||
top: 0
|
||||
left: 0
|
||||
line-height: 32px
|
||||
|
||||
.Delete
|
||||
position: absolute
|
||||
bottom: 14px
|
||||
right: 10px
|
||||
font-size: 16px
|
||||
color: white
|
||||
cursor: pointer
|
||||
.yuLan
|
||||
position: absolute
|
||||
bottom: 23px
|
||||
right: 50px
|
||||
font-size: 16px
|
||||
color: white
|
||||
cursor: pointer
|
||||
.yuLanImg
|
||||
position: absolute
|
||||
bottom: 0
|
||||
right: 0
|
||||
width: 100%
|
||||
height: 100%
|
||||
opacity: 0
|
||||
|
||||
.img-div:hover .disContent-hide
|
||||
display: block
|
||||
|
||||
.pitchCss
|
||||
border: 1px solid #202e78
|
||||
transition: all linear 0.1s
|
||||
width: 116px
|
||||
height: 116px
|
||||
</style>
|
|
@ -0,0 +1,233 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-form label-width="90px">
|
||||
<el-row>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="清单名称">
|
||||
<el-input v-model="KEYWORDS" placeholder="请输入关键字" class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="检查日期">
|
||||
<el-date-picker
|
||||
:default-time="['00:00:00', '23:59:59']"
|
||||
v-model="dates"
|
||||
type="daterange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
style="width: 100%;"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!-- <el-col :span="4">-->
|
||||
<!-- <el-form-item label="检查状态">-->
|
||||
<!-- <el-select v-model="STATUS" placeholder="请选择">-->
|
||||
<!-- <el-option v-for="item in statusList" :key="item.ID" :label="item.NAME" :value="item.ID" />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- </el-col>-->
|
||||
<el-col :span="4">
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
|
||||
<div>
|
||||
<el-table ref="multipleTable" :row-key="getRowKey" :data="varList" border tooltip-effect="dark" style="width: 100%">
|
||||
<el-table-column type="index" label="序号" width="55" align="center" />
|
||||
<el-table-column prop="FIRE_CHECK_STANDARD_NAME" label="清单名称"/>
|
||||
<el-table-column prop="USER_NAME" label="检查人" width="90" align="center" show-overflow-tooltip />
|
||||
<el-table-column prop="CHECK_TIME" label="检查时间" />
|
||||
<el-table-column label="检查周期">
|
||||
<template slot-scope="{row}">
|
||||
<template v-if="row.PERIODSTART && row.PERIODEND">
|
||||
{{ row.PERIODSTART }}-{{ row.PERIODEND }}
|
||||
</template>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="qdlx" label="检查状态" width="120" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<template v-if="row.FINISHED===1">
|
||||
已检查
|
||||
</template>
|
||||
<template v-else>
|
||||
未检查
|
||||
</template>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="" label="操作" width="240" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<template v-if="row.FINISHED === 1">
|
||||
<el-button type="primary" icon="el-icon-tickets" size="mini" @click="goCheck(row,row.FIRE_CHECK_ID,row.FIRE_RECORD_ID)" >检查记录</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="delById(row.FIRE_RECORD_ID)">删除</el-button>
|
||||
</template>
|
||||
<template v-else>
|
||||
<el-button type="success" icon="el-icon-edit" size="mini" @click="goRecording(row,row.PERIODSTART,row.PERIODEND)">补录</el-button>
|
||||
</template>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="ui-foot" style="width:100%">
|
||||
<el-button plain type="info" @click="back">返 回</el-button>
|
||||
</div>
|
||||
<div class="page-btn-group">
|
||||
<div/>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { requestFN } from '@/utils/request'
|
||||
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
export default {
|
||||
components: { Pagination },
|
||||
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 20
|
||||
},
|
||||
dates: [],
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
STARTTIME: '',
|
||||
ENDTIME: '',
|
||||
statusList: [
|
||||
{ 'ID': '1', 'NAME': '已检查' },
|
||||
{ 'ID': '0', 'NAME': '超期未检查' }
|
||||
],
|
||||
STATUS: '',
|
||||
ls: {}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.hasButton()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.CHECKRECORD_ID
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/fireRecord/getRecordListById?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
STARTTIME: this.dates[0],
|
||||
ENDTIME: this.dates[1],
|
||||
FIRE_CHECK_ID: this.$parent.FIRE_CHECK_ID,
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
STATUS: this.STATUS
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
// this.hasButton()
|
||||
this.ls = data.ls
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.STATUS = ''
|
||||
this.dates = []
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
goRecording(row, startTime, endTime) {
|
||||
this.$parent.row = row
|
||||
this.$parent.activeName = 'Recording'
|
||||
this.$parent.startTime = startTime
|
||||
this.$parent.endTime = endTime
|
||||
this.$parent.FIRE_CHECK_ID = row.FIRE_CHECK_ID
|
||||
this.$parent.FIRE_RECORD_ID = row.FIRE_RECORD_ID
|
||||
},
|
||||
// 删除记录
|
||||
delById(FIRE_RECORD_ID) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'fireRecord/delByIds',
|
||||
{
|
||||
FIRE_RECORD_ID: FIRE_RECORD_ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
})
|
||||
},
|
||||
// 检查记录
|
||||
goCheck(row, id, FIRE_RECORD_ID) {
|
||||
this.$parent.FIRE_CHECK_ID = id
|
||||
this.$parent.FIRE_RECORD_ID = FIRE_RECORD_ID
|
||||
this.$parent.SHOW_OR_EDIT = 'SHOW'
|
||||
this.$parent.row = row
|
||||
this.$parent.activeName = 'RecordInfo'
|
||||
},
|
||||
// 返回
|
||||
back() {
|
||||
this.$parent.activeName = 'List'
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'checkrecord:add,checkrecord:del,checkrecord:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.checkrecordfhadminadd // 新增权限
|
||||
this.del = data.checkrecordfhadmindel // 删除权限
|
||||
this.edit = data.checkrecordfhadminedit // 修改权限
|
||||
this.toExcel = data.toExcel // 导出到excel权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,46 @@
|
|||
<template>
|
||||
<component :is="parentObj.activeName"/>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list'
|
||||
import FireRecord from './components/fireRecord.vue'
|
||||
import FireList from './components/fireList.vue'
|
||||
import RecordInfo from './components/recordInfo.vue'
|
||||
export default {
|
||||
components: {
|
||||
List, FireRecord, FireList, RecordInfo
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
parentObj: {
|
||||
activeName: 'List',
|
||||
CORPINFO_ID: ''
|
||||
},
|
||||
info: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
setActiveName(activeName) {
|
||||
this.parentObj.activeName = activeName
|
||||
},
|
||||
getInfo() {
|
||||
return this.info
|
||||
},
|
||||
setInfo(e) {
|
||||
this.info = e
|
||||
}
|
||||
},
|
||||
provide() {
|
||||
return {
|
||||
parentObj: this.parentObj,
|
||||
setActiveName: this.setActiveName,
|
||||
getInfo: this.getInfo,
|
||||
setInfo: this.setInfo
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
|
@ -181,7 +181,7 @@
|
|||
>
|
||||
<div v-if="bottomOptionsIndex !== ''" class="item">
|
||||
<template v-for="(item1,index1) in item.list">
|
||||
<template v-if="containAuthorizationShow(item1)">
|
||||
<template v-if="containAuthorizationShow(item1,item)">
|
||||
<template v-if="eliminateAuthorizationShow(item1)">
|
||||
<div
|
||||
:key="index1"
|
||||
|
@ -498,16 +498,16 @@ export default {
|
|||
containAuthorization: [],
|
||||
eliminateAuthorization: []
|
||||
},
|
||||
// {
|
||||
// label: '消防水源',
|
||||
// dialog_width: '600px',
|
||||
// check: false,
|
||||
// type: 'xfsy01',
|
||||
// img: require('../../assets/map/gangkou_index/buttom/ico7.png'),
|
||||
// checkImg: require('../../assets/map/gangkou_index/buttom/ico7_on.png'),
|
||||
// containAuthorization: [],
|
||||
// eliminateAuthorization: []
|
||||
// },
|
||||
{
|
||||
label: '消防水源',
|
||||
dialog_width: '600px',
|
||||
check: false,
|
||||
type: 'xfsy01',
|
||||
img: require('../../assets/map/gangkou_index/buttom/ico7.png'),
|
||||
checkImg: require('../../assets/map/gangkou_index/buttom/ico7_on.png'),
|
||||
containAuthorization: [],
|
||||
eliminateAuthorization: []
|
||||
},
|
||||
{
|
||||
label: '消防点位',
|
||||
dialog_width: '600px',
|
||||
|
@ -2832,10 +2832,21 @@ export default {
|
|||
this.bottomOptionsIndex = ''
|
||||
this.collapse = false
|
||||
},
|
||||
containAuthorizationShow({ containAuthorization }) {
|
||||
containAuthorizationShow(e, item) {
|
||||
// create by liu jun (PS:此处根据[下面这个if]孙海官的需求,对消防管控的权限进行了特殊处理,未进入具体企业时,显示消防救援队,进入具体企业后,显示消防管控其他按钮)
|
||||
if (item && item.list && item.list.length > 0) {
|
||||
if (item.label === '消防管控') {
|
||||
if (e.label === '消防救援队') {
|
||||
return !(this.CORP_INFO_ID && this.CORP_INFO_ID !== '')
|
||||
}
|
||||
if (e.label !== '消防救援队') {
|
||||
return (this.CORP_INFO_ID && this.CORP_INFO_ID !== '')
|
||||
}
|
||||
}
|
||||
}
|
||||
const CORP_INFO_ID = this.CORP_INFO_ID
|
||||
if (containAuthorization.length === 0) return true
|
||||
if (containAuthorization.includes(CORP_INFO_ID)) {
|
||||
if (e.containAuthorization.length === 0) return true
|
||||
if (e.containAuthorization.includes(CORP_INFO_ID)) {
|
||||
return true
|
||||
} else {
|
||||
return false
|
||||
|
|
Loading…
Reference in New Issue