| | |
| | | <el-form-item> |
| | | <el-button size="mini" type="primary" icon="el-icon-search">搜索</el-button></el-form-item> |
| | | </el-form> |
| | | <el-table :data="tableData" style="width: 100%"> |
| | | <el-table-column prop="id" label="编号" width="60"> |
| | | <el-table :data="faultList" style="width: 100%"> |
| | | <el-table-column prop="deviceId" label="设备编号" width="80"> |
| | | </el-table-column> |
| | | <el-table-column prop="id" label="设备名称"> |
| | | <el-table-column prop="deviceName" label="设备名称"> |
| | | </el-table-column> |
| | | <el-table-column prop="erectoName" label="客户名" width="100"> |
| | | <el-table-column prop="userName" label="客户名" width="100"> |
| | | </el-table-column> |
| | | <el-table-column prop="userName" label="客户电话" width="100"> |
| | | <el-table-column prop="userPhone" label="客户电话" width="100"> |
| | | </el-table-column> |
| | | <el-table-column prop="userPhone" label="设备故障描述"> |
| | | <template slot-scope="scope"> |
| | | <div v-if="scope.row.sysStatus == 0"> |
| | | 正常空闲状态 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 1"> |
| | | 缺水停机状态 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 2"> |
| | | 制水中 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 3"> |
| | | 冲洗中 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 4"> |
| | | 维护中 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 5"> |
| | | 未激活 |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination background :current-page="pageIndex" @current-change="changePage" :page-size="pageSize" |
| | |
| | | data() { |
| | | return { |
| | | state: -1, |
| | | tableData: [], |
| | | faultList: [], |
| | | pageIndex: 1, |
| | | pageSize: 10, |
| | | total: 0, |
| | |
| | | }, |
| | | |
| | | mounted() { |
| | | |
| | | this.getList() |
| | | }, |
| | | methods: { |
| | | changePage(e) { |
| | |
| | | this.getList(); |
| | | }, |
| | | getList() { |
| | | let data = { |
| | | pageNum: 1,//页码 |
| | | pageSize: 5,//每页条数 |
| | | userId: localStorage.getItem('userID'),//用户id |
| | | roleKey: this.roleKey,//角色 |
| | | // |
| | | } |
| | | request({ |
| | | url: '/api/Equipment/GetFaultList', |
| | | method: 'get', |
| | | params: { |
| | | pageIndex: this.pageIndex, |
| | | pageSize: this.pageSize, |
| | | state: this.state, |
| | | // url: `/iot/device/faultList/${localStorage.getItem('userID')}`, |
| | | url: `/iot/device/deviceMalfunction`,//接口方式 |
| | | method: "get", |
| | | // params:data, //如果需要传参就放开 |
| | | }).then((res) => { |
| | | if (res.code == 200) { |
| | | this.faultList = res.rows |
| | | } else { |
| | | this.faultList = [] |
| | | } |
| | | }).then(res => { |
| | | this.tableData = res.data.data; |
| | | this.total = res.data.total; |
| | | }).catch((res) => { |
| | | this.faultList = [] |
| | | }) |
| | | } |
| | | |
| | |
| | | <el-form-item> |
| | | <el-button size="mini" type="primary" icon="el-icon-search">搜索</el-button></el-form-item> |
| | | </el-form> --> |
| | | <el-table :data="tableData" style="width: 100%"> |
| | | <el-table-column prop="id" label="编号" width="60"> |
| | | <el-table :data="cartridgeList" style="width: 100%"> |
| | | <el-table-column prop="deviceId" label="设备编号" width="80"> |
| | | </el-table-column> |
| | | <el-table-column prop="id" label="设备名称"> |
| | | <el-table-column prop="deviceName" label="设备名称"> |
| | | </el-table-column> |
| | | <el-table-column prop="erectoName" label="客户名" width="100"> |
| | | <el-table-column prop="deviceName" label="客户名" width="100"> |
| | | </el-table-column> |
| | | <el-table-column prop="userName" label="客户电话" width="100"> |
| | | <el-table-column prop="userPhone" label="客户电话" width="100"> |
| | | </el-table-column> |
| | | <el-table-column prop="userPhone" label="滤芯状态"> |
| | | <el-table-column label="滤芯寿命"> |
| | | <template slot-scope="scope"> |
| | | <div v-if="scope.row.filterA != null"> |
| | | 滤芯{{ scope.row.filterA }}% |
| | | </div> |
| | | <div v-if="scope.row.filterB != null"> |
| | | 滤芯{{ scope.row.filterB }}% |
| | | </div> |
| | | <div v-if="scope.row.filterC != null"> |
| | | 滤芯{{ scope.row.filterC }}% |
| | | </div> |
| | | <div v-if="scope.row.filterD != null"> |
| | | 滤芯{{ scope.row.filterD }}% |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination background :current-page="pageIndex" @current-change="changePage" :page-size="pageSize" |
| | |
| | | data() { |
| | | return { |
| | | state: -1, |
| | | tableData: [], |
| | | cartridgeList: [], |
| | | pageIndex: 1, |
| | | pageSize: 10, |
| | | total: 0, |
| | |
| | | }, |
| | | |
| | | mounted() { |
| | | this.getList |
| | | |
| | | }, |
| | | methods: { |
| | |
| | | this.getList(); |
| | | }, |
| | | getList() { |
| | | //字段设想,需要用,不需要就注释 |
| | | let data = { |
| | | pageNum: 1,//页码 |
| | | pageSize: 5,//每页条数 |
| | | userId: localStorage.getItem('userID'),//用户id |
| | | roleKey: this.roleKey,//角色 |
| | | //自定义参数 |
| | | } |
| | | request({ |
| | | url: '/api/Equipment/GetFaultList', |
| | | method: 'get', |
| | | params: { |
| | | pageIndex: this.pageIndex, |
| | | pageSize: this.pageSize, |
| | | state: this.state, |
| | | url: '/iot/device/FilterElement', |
| | | method: "get", |
| | | // params:data, //如果需要传参就放开 |
| | | }).then((res) => { |
| | | if (res.code == 200) { |
| | | this.cartridgeList = res.rows |
| | | } else { |
| | | this.cartridgeList = [] |
| | | } |
| | | }).then(res => { |
| | | this.tableData = res.data.data; |
| | | this.total = res.data.total; |
| | | }).catch((res) => { |
| | | this.cartridgeList = [] |
| | | }) |
| | | } |
| | | |
| | |
| | | <img src="../assets/images/less.png" alt="" |
| | | style="width: 100px;height: 100px;margin-left: calc(50% - 50px);"> |
| | | </div> |
| | | |
| | | </el-card> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | <span>设备故障表</span> |
| | | <el-button style="float: right; padding: 3px 0" type="text" @click="goFaultList">更多</el-button> |
| | | </div> |
| | | <el-table :data="tableWXData" style="width: 100%" v-if="tableWXData.length > 0"> |
| | | <el-table-column prop="id" label="设备名称"> |
| | | <el-table :data="faultList" style="width: 100%" v-if="faultList.length > 0"> |
| | | <el-table-column prop="deviceName" label="设备名称"> |
| | | </el-table-column> |
| | | <el-table-column prop="erectoName" label="客户名" width="100"> |
| | | <el-table-column prop="userName" label="客户名" width="100"> |
| | | </el-table-column> |
| | | <el-table-column prop="userName" label="客户电话" width="100"> |
| | | <el-table-column prop="userPhone" label="客户电话" width="100"> |
| | | </el-table-column> |
| | | <el-table-column prop="userPhone" label="设备故障描述"> |
| | | <template slot-scope="scope"> |
| | | <div v-if="scope.row.sysStatus == 0"> |
| | | 正常空闲状态 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 1"> |
| | | 缺水停机状态 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 2"> |
| | | 制水中 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 3"> |
| | | 冲洗中 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 4"> |
| | | 维护中 |
| | | </div> |
| | | <div v-if="scope.row.sysStatus == 5"> |
| | | 未激活 |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <div style="width: 100%;height: 117px;" v-else> |
| | |
| | | <el-table-column label="滤芯寿命"> |
| | | <template slot-scope="scope"> |
| | | <div v-if="scope.row.filterA != null"> |
| | | {{ scope.row.filterA }}% |
| | | 滤芯{{ scope.row.filterA }}% |
| | | </div> |
| | | <div v-if="scope.row.filterB != null"> |
| | | {{ scope.row.filterB }}% |
| | | 滤芯{{ scope.row.filterB }}% |
| | | </div> |
| | | <div v-if="scope.row.filterC != null"> |
| | | {{ scope.row.filterC }}% |
| | | 滤芯{{ scope.row.filterC }}% |
| | | </div> |
| | | <div v-if="scope.row.filterD != null"> |
| | | {{ scope.row.filterD }}% |
| | | 滤芯{{ scope.row.filterD }}% |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | this.getListAZ() //获取安装列表 |
| | | this.getListWX() //获取维修列表 |
| | | this.getCartridgeList() //获取滤芯寿命 |
| | | // this.deviceFault() //获取设备故障 |
| | | this.deviceFault() //获取设备故障 |
| | | |
| | | }, |
| | | methods: { |
| | |
| | | // |
| | | } |
| | | request({ |
| | | url: `/iot/device/faultList/${localStorage.getItem('userID')}`, |
| | | // url: `/iot/device/faultList`,//接口方式 |
| | | // url: `/iot/device/faultList/${localStorage.getItem('userID')}`, |
| | | url: `/iot/device/deviceMalfunction`,//接口方式 |
| | | method: "get", |
| | | // params:data, //如果需要传参就放开 |
| | | }).then((res) => { |
| | |
| | | <i class="el-icon-odometer"></i> |
| | | {{ item.name }} |
| | | </template> |
| | | |
| | | <el-link type="primary" v-if="item.name == '系统状态'" :underline="false"> |
| | | <el-link type="primary" :underline="false"> {{ getShowValue(item) }}</el-link> |
| | | <!-- <el-link type="primary" v-if="item.name == '系统状态'" :underline="false"> |
| | | {{ getShowValue(item) }} |
| | | </el-link> |
| | | <el-link type="primary" v-else :underline="false">{{ item.shadow }} |
| | | {{ item.unit == null ? "--" : item.unit }}</el-link> |
| | | {{ item.unit == null ? "--" : item.unit }}</el-link> --> |
| | | </el-descriptions-item> |
| | | </el-descriptions> |
| | | |
| | |
| | | methods: { |
| | | getShowValue(item) { |
| | | if (item.shadow == null || item.shadow == undefined || item.shadow == '') { |
| | | return '--' |
| | | return '暂无数据' |
| | | return false |
| | | } |
| | | for (let i = 0; i < item.enumList.length; i++) { |
| | | if (item.value == item.enumList[i].shadow) { |
| | | return item.enumList[i].text |
| | | return item.enumList[i].text+item.unit?item.unit:'' |
| | | } |
| | | } |
| | | }, |