【新增】 IOT 设备管理
This commit is contained in:
@ -103,7 +103,7 @@
|
||||
import { ProductApi, ProductVO } from '@/api/iot/product'
|
||||
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
|
||||
|
||||
defineOptions({ name: 'ProductForm' })
|
||||
defineOptions({ name: 'IoTProductForm' })
|
||||
|
||||
const { t } = useI18n()
|
||||
const message = useMessage()
|
||||
|
||||
@ -20,7 +20,7 @@ import { ProductApi, ProductVO } from '@/api/iot/product'
|
||||
import ProductDetailsHeader from '@/views/iot/product/detail/ProductDetailsHeader.vue'
|
||||
import ProductDetailsInfo from '@/views/iot/product/detail/ProductDetailsInfo.vue'
|
||||
|
||||
defineOptions({ name: 'IotProductDetail' })
|
||||
defineOptions({ name: 'IoTProductDetail' })
|
||||
|
||||
const route = useRoute()
|
||||
const message = useMessage()
|
||||
|
||||
@ -44,7 +44,11 @@
|
||||
<!-- 列表 -->
|
||||
<ContentWrap>
|
||||
<el-table v-loading="loading" :data="list" :stripe="true" :show-overflow-tooltip="true">
|
||||
<el-table-column label="产品名称" align="center" prop="name" />
|
||||
<el-table-column label="产品名称" align="center" prop="name">
|
||||
<template #default="scope">
|
||||
<el-link @click="openDetail(scope.row.id)">{{ scope.row.name }}</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="ProductKey" align="center" prop="productKey" />
|
||||
<el-table-column label="设备类型" align="center" prop="deviceType">
|
||||
<template #default="scope">
|
||||
@ -106,7 +110,7 @@ import ProductForm from './ProductForm.vue'
|
||||
import { DICT_TYPE } from '@/utils/dict'
|
||||
|
||||
/** iot 产品 列表 */
|
||||
defineOptions({ name: 'Product' })
|
||||
defineOptions({ name: 'IoTProduct' })
|
||||
|
||||
const message = useMessage() // 消息弹窗
|
||||
const { t } = useI18n() // 国际化
|
||||
@ -166,7 +170,7 @@ const openForm = (type: string, id?: number) => {
|
||||
/** 打开详情 */
|
||||
const { currentRoute, push } = useRouter()
|
||||
const openDetail = (id: number) => {
|
||||
push({ name: 'IotProductDetail', params: { id } })
|
||||
push({ name: 'IoTProductDetail', params: { id } })
|
||||
}
|
||||
|
||||
/** 删除按钮操作 */
|
||||
|
||||
Reference in New Issue
Block a user