|
|
|
@ -9,6 +9,7 @@ import { useModal } from '@/components/Modal'
|
|
|
|
|
import { getCloudCommandLogs, getMessageContent } from '@/api/device-manage/device/cloud-command' |
|
|
|
|
import type { Device } from '@/api/device-manage/device/types' |
|
|
|
|
import { CloudCommandType } from '@/api/device-manage/device/types' |
|
|
|
|
import { usePermission } from '@/hooks/web/usePermission' |
|
|
|
|
|
|
|
|
|
defineProps<{ device?: Device }>() |
|
|
|
|
|
|
|
|
@ -65,6 +66,8 @@ const [register, { reload }] = useTable({
|
|
|
|
|
inset: true, |
|
|
|
|
canResize: false, |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
const { hasPermission } = usePermission() |
|
|
|
|
</script> |
|
|
|
|
|
|
|
|
|
<template> |
|
|
|
@ -72,6 +75,7 @@ const [register, { reload }] = useTable({
|
|
|
|
|
<div flex="~ items-center gap-12px" mb="12px"> |
|
|
|
|
<Segmented v-model:value="selectedCommonType" :options="commandTypes" @change="() => reload()" /> |
|
|
|
|
<a-button |
|
|
|
|
v-if="hasPermission('device_cloud_command_action')" |
|
|
|
|
type="primary" |
|
|
|
|
@click="openModal(true, { |
|
|
|
|
deviceId: device!.id, |
|
|
|
|