iot设备绑定记录接口调试完成

This commit is contained in:
BianLzhaoMin 2024-08-05 17:02:58 +08:00
parent 2f62f9f2ed
commit 5a98e03656
3 changed files with 15 additions and 8 deletions

View File

@ -19,7 +19,7 @@ export function getDeviceListApi(query) {
// 查询绑定记录
export function getDeviceBindRecordApi(query) {
return request({
url: '/material/xxxx',
url: '/material/iotMachine/getRecordList',
method: 'get',
params: query
})

View File

@ -11,10 +11,10 @@ export const dialogConfig = {
],
columnsList: [
{ t_width: '', t_props: 'machineTypeName', t_label: '绑定设备名称' },
{ t_width: '', t_props: 'specificationType', t_label: '设备编号' },
{ t_width: '', t_props: 'maCode', t_label: '绑定时间' },
{ t_width: '', t_props: 'scrapNum', t_label: '解绑时间' },
{ t_props: 'typeName', t_label: '绑定设备名称' },
{ t_props: 'maCode', t_label: '设备编号' },
{ t_props: 'bindTime', t_label: '绑定时间' },
{ t_props: 'unBindTime', t_label: '解绑时间' },
],
}

View File

@ -78,7 +78,7 @@
<el-button
type="text"
icon="el-icon-tickets"
@click="handleViewRecord()"
@click="handleViewRecord(row.iotId)"
>记录</el-button
>
<el-button
@ -161,6 +161,7 @@
<TableModel
:config="dialogConfig"
:sendParams="sendParams"
:sendApi="getDeviceBindRecordApi"
v-else
/>
</template>
@ -177,6 +178,7 @@ import {
getDeviceListApi,
deleteDeviceApi,
unbindDeviceApi,
getDeviceBindRecordApi,
} from '@/api/iotDevice'
export default {
components: {
@ -220,9 +222,13 @@ export default {
],
},
//
sendParams: {},
sendParams: {
iotId: '',
},
//
selectList: [],
// Api
getDeviceBindRecordApi,
}
},
@ -284,9 +290,10 @@ export default {
},
/** 查看记录 */
handleViewRecord() {
handleViewRecord(id) {
this.dialogConfig.outerWidth = '70%'
this.dialogConfig.outerTitle = '绑定记录'
this.sendParams.iotId = id
this.dialogConfig.outerVisible = true
},