|
@@ -102,7 +102,15 @@ export default {
|
|
|
props: {},
|
|
|
data() {
|
|
|
return {
|
|
|
- title: '高压进线柜(4)',
|
|
|
+ title: '',
|
|
|
+ // 查询下拉菜单,主列表使用
|
|
|
+ major: '', //系统
|
|
|
+ type_code: '', //自定义分类内码
|
|
|
+ brand: '', //品牌
|
|
|
+ classstructureid: '', //设备分类
|
|
|
+ manufacturer: '', //生产厂商
|
|
|
+ sbxh: '', //设备类型
|
|
|
+
|
|
|
keyword: '',
|
|
|
page: 1,
|
|
|
size: 10,
|
|
@@ -124,7 +132,6 @@ export default {
|
|
|
floor: '',
|
|
|
attribution: '',
|
|
|
},
|
|
|
- major: '暖通',
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
@@ -132,6 +139,26 @@ export default {
|
|
|
},
|
|
|
components: {},
|
|
|
created() {
|
|
|
+ // 从路由中获取参数
|
|
|
+
|
|
|
+ // title, 标题 高压进线柜(4)
|
|
|
+
|
|
|
+ // major, 暖通 等
|
|
|
+
|
|
|
+ // brand, 品牌如果没有传递‘--’
|
|
|
+ // classstructureid, 设备分类
|
|
|
+ // manufacturer, 生产厂商 如果没有传递‘--’
|
|
|
+ // sbxh, 设备类型 如果没有传递‘--’
|
|
|
+ // type_code 自定义分类内码
|
|
|
+ let { title, major, type_code, brand, classstructureid, manufacturer, sbxh } = this.$route.params
|
|
|
+ this.title = title || '高压进线柜(4)'
|
|
|
+ this.major = major || '暖通'
|
|
|
+ this.type_code = type_code || 'nt023'
|
|
|
+ this.brand = brand || '--'
|
|
|
+ this.classstructureid = classstructureid || '1714'
|
|
|
+ this.manufacturer = manufacturer || '深圳麦克威尔空调制冷有限公司'
|
|
|
+ this.sbxh = sbxh || '050A'
|
|
|
+
|
|
|
// 设置 筛选抽屉中的 楼层
|
|
|
let floorList = [{ code: '全部', gcname: '全部', gcode: '全部', gname: '全部', seq: null, active: 'active' }]
|
|
|
this.floorsArr.map(({ code, gcname, gcode, gname, seq }) => {
|
|
@@ -142,10 +169,13 @@ export default {
|
|
|
this.onLoad()
|
|
|
// 查询归属管理
|
|
|
this.getOptions()
|
|
|
- },
|
|
|
+ },
|
|
|
beforeMount() {},
|
|
|
mounted() {},
|
|
|
methods: {
|
|
|
+ /**
|
|
|
+ * 查询管理归属下拉菜单
|
|
|
+ */
|
|
|
async getOptions() {
|
|
|
let data = {
|
|
|
major: this.major,
|
|
@@ -153,7 +183,7 @@ export default {
|
|
|
onlyMainAsset: true,
|
|
|
}
|
|
|
// TODO: type_code
|
|
|
- let postParams = [{ columnName: { sbglgs: 'sbglgs' }, params: { type_code: 'nt011' }, tableName: 'sms_asset' }]
|
|
|
+ let postParams = [{ columnName: { sbglgs: 'sbglgs' }, params: { type_code: this.type_code }, tableName: 'sms_asset' }]
|
|
|
let res = await queryOptions({ data, postParams })
|
|
|
if (!res?.data?.data) {
|
|
|
this.attributionList = [{ text: '全部', id: '全部', active: 'active' }]
|
|
@@ -218,11 +248,11 @@ export default {
|
|
|
onlyMainAsset: true,
|
|
|
},
|
|
|
postParams: {
|
|
|
- brand: '--',
|
|
|
- classstructureid: '1714',
|
|
|
- manufacturer: '深圳麦克威尔空调制冷有限公司',
|
|
|
- sbxh: '050A',
|
|
|
- type_code: 'nt023',
|
|
|
+ brand: this.brand,
|
|
|
+ classstructureid: this.classstructureid,
|
|
|
+ manufacturer: this.manufacturer,
|
|
|
+ sbxh: this.sbxh,
|
|
|
+ type_code: this.type_code,
|
|
|
},
|
|
|
}
|
|
|
// 关键字搜索
|