|
@@ -4,30 +4,50 @@
|
|
|
<div class='gdqd-dialog'>
|
|
|
<div class='top'></div>
|
|
|
<div class='gdqd-dialog-top'>
|
|
|
- <el-input
|
|
|
- placeholder='请输入设备简称、设备编号、品牌、型号、安装位置、生产厂商、服务商搜索'
|
|
|
- style='width:490px;margin-right:12px'
|
|
|
- size='small'
|
|
|
- prefix-icon='el-icon-search'
|
|
|
- v-model='input'
|
|
|
- ></el-input>
|
|
|
- <Select width='120' style='margin-right:12px' tipPlace='top' caption='楼层:' size='small' :selectdata='floorSelect'></Select>
|
|
|
- <Select width='224' style='margin-right:12px' tipPlace='top' caption='管理归属' size='small' :selectdata='dataSelect2'></Select>
|
|
|
- <Select width='224' tipPlace='top' caption='设备状态' size='small' :selectdata='dataSelect2'></Select>
|
|
|
+ <el-input placeholder='请输入设备简称、设备编号搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='input'></el-input>
|
|
|
+ <el-input placeholder='请输入品牌、型号搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='input'></el-input>
|
|
|
+ <el-input placeholder='请输入生产厂商搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='input'></el-input>
|
|
|
+ <el-input placeholder='请输入安装位置搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='input'></el-input>
|
|
|
+ <el-input placeholder='请输入服务商搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='input'></el-input>
|
|
|
+ <Select style='width:146px;margin-right:12px' v-model='floor' tipPlace='top' caption='楼层:' size='small' :selectdata='floorSelect'></Select>
|
|
|
+ <Select v-model='sbglgs' style='width:146px;margin-right:12px' tipPlace='top' caption='管理归属' size='small' :selectdata='sbglgsOption'></Select>
|
|
|
+ <Select style='width:146px;' v-model='status' tipPlace='top' caption='设备状态' size='small' :selectdata='statusOption'></Select>
|
|
|
</div>
|
|
|
<el-table :data='tableData' :border='true' style='width: 100%;amrgin-bottom:30px'>
|
|
|
- <el-table-column type='index' label='序号' width='50'></el-table-column>
|
|
|
- <el-table-column prop='sbjc' label='设备简称' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='sbbh' label='设备编号' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='sl' label='数量'></el-table-column>
|
|
|
- <el-table-column prop='glgs' label='管理归属' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='sbbh' label='设备状态'></el-table-column>
|
|
|
- <el-table-column prop='brand' label='品牌' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='sbxh' label='型号' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='floor' label='楼层'></el-table-column>
|
|
|
- <el-table-column prop='azwz' label='安装位置' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='manufacturer' label='生产厂商' show-overflow-tooltip resizable></el-table-column>
|
|
|
- <el-table-column prop='fws' label='服务商' show-overflow-tooltip resizable></el-table-column>
|
|
|
+ <el-table-column type='index' label='序号' width='80'></el-table-column>
|
|
|
+ <el-table-column prop='sbjc' label='设备简称' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.sbjc || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='assetnum' label='设备编号' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.assetnum || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='sl' label='数量'>
|
|
|
+ <template slot-scope='{row}'>{{row.sl || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='sbglgs' label='管理归属' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.sbglgs || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='sb_status' label='设备状态'>
|
|
|
+ <template slot-scope='{row}'>{{row.sb_status || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='brand' label='品牌' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.brand || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='sbxh' label='型号' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.sbxh || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='floor' label='楼层'>
|
|
|
+ <template slot-scope='{row}'>{{row.floor || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='wzjc' label='安装位置' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.wzjc || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='manufacturer' label='生产厂商' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.manufacturer || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop='fws' label='服务商' show-overflow-tooltip resizable>
|
|
|
+ <template slot-scope='{row}'>{{row.fws || '--'}}</template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
<div class='foot'>
|
|
|
<el-pagination
|
|
@@ -62,19 +82,22 @@ export default {
|
|
|
size: 10,
|
|
|
total: 1,
|
|
|
keyword: '',
|
|
|
- floorSelect: []
|
|
|
+ floor: '',
|
|
|
+ status: '',
|
|
|
+ sbglgs: '',
|
|
|
+ sbglgsOption: [],
|
|
|
+ statusOption: []
|
|
|
}
|
|
|
},
|
|
|
components: {
|
|
|
Select
|
|
|
},
|
|
|
computed: {
|
|
|
- ...mapGetters(['floorsArr'])
|
|
|
+ ...mapGetters(['floorSelect'])
|
|
|
},
|
|
|
props: ['row', 'major'],
|
|
|
mounted() {
|
|
|
this.queryTableList()
|
|
|
- this.init()
|
|
|
this.tabFind()
|
|
|
},
|
|
|
methods: {
|
|
@@ -82,19 +105,49 @@ export default {
|
|
|
tabFind() {
|
|
|
let postParams = [
|
|
|
{
|
|
|
+ columnName: { sbglgs: 'sbglgs', sb_status: 'sb_status' },
|
|
|
params: {
|
|
|
type_code: this.row.type_code
|
|
|
},
|
|
|
tableName: 'glsms_asset' //视图名称
|
|
|
}
|
|
|
]
|
|
|
-
|
|
|
+ let major
|
|
|
+ if (this.major.slice(0, 2) == 'GD') {
|
|
|
+ major = '供电'
|
|
|
+ } else if (this.major.slice(0, 2) == 'XF') {
|
|
|
+ major = '消防'
|
|
|
+ } else if (this.major.slice(0, 2) == 'GPS') {
|
|
|
+ major = '给排水'
|
|
|
+ } else if (this.major.slice(0, 2) == 'DT') {
|
|
|
+ major = '电梯'
|
|
|
+ } else if (this.major.slice(0, 2) == 'RQ') {
|
|
|
+ major = '燃气'
|
|
|
+ } else {
|
|
|
+ major = this.major
|
|
|
+ }
|
|
|
let data = {
|
|
|
- major: this.major,
|
|
|
+ major: major,
|
|
|
plazaId: this.$store.state.plazaId
|
|
|
}
|
|
|
- queryTab({ data, postParams }).then(res => {
|
|
|
+ querySelect({ data, postParams }).then(res => {
|
|
|
console.log(res)
|
|
|
+ let sb_status = res.data.data.glsms_asset.sb_status
|
|
|
+ let sbglgs = res.data.data.glsms_asset.sbglgs
|
|
|
+ this.sbglgsOption = []
|
|
|
+ this.statusOption = []
|
|
|
+ sb_status.forEach(el => {
|
|
|
+ this.statusOption.push({
|
|
|
+ name: el.value,
|
|
|
+ id: el.key
|
|
|
+ })
|
|
|
+ })
|
|
|
+ sbglgs.forEach(el => {
|
|
|
+ this.sbglgsOption.push({
|
|
|
+ name: el.value,
|
|
|
+ id: el.key
|
|
|
+ })
|
|
|
+ })
|
|
|
})
|
|
|
},
|
|
|
|
|
@@ -123,6 +176,9 @@ export default {
|
|
|
page: this.page,
|
|
|
size: this.size,
|
|
|
keyword: this.keyword
|
|
|
+ // sbglgs:this.sbglgs,
|
|
|
+ // floor:this.floor,
|
|
|
+ // status:this.status
|
|
|
}
|
|
|
let postParams = {
|
|
|
type_code: this.row.type_code,
|
|
@@ -136,18 +192,6 @@ export default {
|
|
|
this.tableData = res.data.data
|
|
|
this.total = res.data.count
|
|
|
})
|
|
|
- },
|
|
|
- init() {
|
|
|
- this.floorSelect = []
|
|
|
- if (this.floorsArr.length > 0) {
|
|
|
- this.floorsArr.forEach(e => {
|
|
|
- let obj = {
|
|
|
- id: e,
|
|
|
- name: e
|
|
|
- }
|
|
|
- this.floorSelect.push(obj)
|
|
|
- })
|
|
|
- }
|
|
|
}
|
|
|
},
|
|
|
watch: {
|
|
@@ -155,7 +199,6 @@ export default {
|
|
|
handler(newV, oldV) {
|
|
|
if (newV != oldV) {
|
|
|
this.queryTableList()
|
|
|
- this.init()
|
|
|
this.tabFind()
|
|
|
}
|
|
|
},
|
|
@@ -169,18 +212,20 @@ export default {
|
|
|
padding: 16px 24px 40px;
|
|
|
.gdqd-dialog-top {
|
|
|
display: flex;
|
|
|
- margin-bottom: 20px;
|
|
|
- }
|
|
|
- .foot {
|
|
|
- position: absolute;
|
|
|
- height: 32px;
|
|
|
- right: 26px;
|
|
|
+ flex-wrap: wrap;
|
|
|
+ height: 90px;
|
|
|
}
|
|
|
td {
|
|
|
overflow: hidden;
|
|
|
text-overflow: ellipsis;
|
|
|
white-space: nowrap;
|
|
|
}
|
|
|
+ .foot {
|
|
|
+ height: 32px;
|
|
|
+ display: flex;
|
|
|
+ justify-content: flex-end;
|
|
|
+ margin-top: 28px;
|
|
|
+ }
|
|
|
}
|
|
|
</style>
|
|
|
<style lang="less">
|