| | |
| | | {{ getDeviceTypeName(row.droneType) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="deviceCode" label="设备编码" /> |
| | | <el-table-column prop="deviceSn" label="设备编码" /> |
| | | <el-table-column label="设备状态"> |
| | | <template v-slot="{ row }"> |
| | | {{ getDeviceStatus(row) }} |
| | | {{ getDictLabel(row.deviceStatus, dictObj.deviceStatus) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | import { getDictionaryByCode } from '@/api/system/dictbiz' |
| | | import { exportFwDroneAlarmRecordApi, fwDroneAlarmRecordPageApi } from './fwDroneAlarmRecord' |
| | | import FormDiaLog from './FormDiaLog.vue' |
| | | import { blobDownload, dateRangeFormat } from '@ztzf/utils' |
| | | import { blobDownload, dateRangeFormat, getDictLabel } from '@ztzf/utils' |
| | | |
| | | const initSearchParams = () => ({ |
| | | droneName: '', // 无人机名称 |
| | |
| | | getList() |
| | | } |
| | | |
| | | // 查看 |
| | | function handleView(row) { |
| | | dialogRef.value?.open({ mode: 'view', row: { ...row } }) |
| | | } |
| | | |
| | | function exportFile() { |
| | | exportLoading.value = true |
| | | exportFwDroneAlarmRecordApi() |
| | |
| | | }) |
| | | } |
| | | |
| | | function getDeviceStatus(row) { |
| | | return row.deviceStatus ?? row.status ?? '-' |
| | | } |
| | | |
| | | function getDeviceTypeName(value) { |
| | | return deviceTypeMap.value.get(value) || value || '-' |
| | | } |
| | | |
| | | // 获取字典 |
| | | function getDictList() { |
| | | getDictionaryByCode('deviceType').then(res => { |
| | | getDictionaryByCode('deviceType,deviceStatus').then(res => { |
| | | dictObj.value = res.data.data |
| | | }) |
| | | } |