bug修复

This commit is contained in:
BianLzhaoMin 2025-03-26 17:31:53 +08:00
parent 938efea6b4
commit f2a731f9e8
1 changed files with 262 additions and 261 deletions

View File

@ -1,6 +1,13 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="68px"
>
<el-form-item prop="deviceName">
<el-input
v-model="queryParams.deviceName"
@ -71,15 +78,15 @@
<el-table-column label="装备类目" align="center" prop="typeName" width="250px" sortable>
<template slot-scope="scope">
<span
>{{ scope.row.firstName }} <span v-show="scope.row.firstName">></span>
{{ scope.row.secondName }}<span v-show="scope.row.secondName">></span
>{{ scope.row.thirdName }}</span
>{{ scope.row.firstName }} <span v-show="scope.row.firstName">></span> {{ scope.row.secondName
}}<span v-show="scope.row.secondName">></span>{{ scope.row.thirdName }}</span
>
</template>
</el-table-column>
<el-table-column label="装备型号" align="center" prop="typeName" sortable />
<el-table-column label="所属公司" align="center" prop="companyName" sortable />
<el-table-column label="上架时间" align="center" prop="createTime" sortable/>
<!-- <el-table-column label="上架时间" align="center" prop="createTime" sortable/> -->
<el-table-column label="创建时间" align="center" prop="createTime" sortable />
<el-table-column label="更新时间" align="center" prop="updateTime" sortable />
</el-table>
@ -90,15 +97,13 @@
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
import { getEquipmentTypeApi,getEquipmentListApi, } from "@/api/search/equipment";
import { getEquipmentTypeApi, getEquipmentListApi } from '@/api/search/equipment'
export default {
name: "equipment",
name: 'equipment',
data() {
return {
//
@ -106,7 +111,6 @@ export default {
loadingTwo: false,
// Id
showName: false,
@ -135,7 +139,7 @@ export default {
teamTempList: [],
warnList: [],
//
title: "",
title: '',
//
open: false,
//
@ -176,51 +180,49 @@ export default {
},
//
form: {},
};
}
},
created() {
this.getTypeTreeData();
this.getList();
this.getTypeTreeData()
this.getList()
},
methods: {
/** 查询树形列表 */
getTypeTreeData() {
getEquipmentTypeApi().then(response => {
this.deviceTypeTree = response.data;
});
getEquipmentTypeApi().then((response) => {
this.deviceTypeTree = response.data
})
},
/** 查询装备信息列表 */
async getList() {
this.loading = true;
this.loading = true
if (this.dateRange.length > 0) {
this.queryParams.startTime = this.dateRange[0]
this.queryParams.endTime = this.dateRange[1]
}
await getEquipmentListApi(this.queryParams).then(response => {
await getEquipmentListApi(this.queryParams).then((response) => {
console.log('11111', response)
this.tableData = response.data.rows;
this.total = response.data.total;
this.loading = false;
});
this.tableData = response.data.rows
this.total = response.data.total
this.loading = false
})
},
//
openTeam(row) {
this.teamId = row.teamId;
this.title = "查看人员"
this.showTeam = true;
this.getListTeam();
this.teamId = row.teamId
this.title = '查看人员'
this.showTeam = true
this.getListTeam()
},
//
openTeamTemp(row) {
this.teamId = row.teamId;
this.title = "查看临时人员"
this.showTeamTemp = true;
this.getListTeamTemp();
this.teamId = row.teamId
this.title = '查看临时人员'
this.showTeamTemp = true
this.getListTeamTemp()
},
//
@ -242,18 +244,18 @@ export default {
// },
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.queryParams.pageNum = 1
this.getList()
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.dateRange = [];
this.resetForm('queryForm')
this.dateRange = []
this.deviceTypeList = []
this.queryParams.startTime = ''
this.queryParams.endTime = ''
this.queryParams.typeId = ''
this.handleQuery();
this.handleQuery()
},
//-change
@ -264,10 +266,9 @@ export default {
} else {
this.queryParams.typeId = ''
}
},
},
}
}
};
</script>
<style lang="scss" scoped>
.uploadImg {