fix(devicePreset): 修改删除预置位接口参数及调用方式

refactor(securitySurveillance): 添加项目ID参数到监控列表请求
style(camera): 注释掉未使用的设备操作按钮代码
This commit is contained in:
tcy
2025-09-24 17:52:51 +08:00
parent 64c538775f
commit b7c716509d
4 changed files with 65 additions and 53 deletions

View File

@ -101,7 +101,7 @@ import EZUIKit from 'ezuikit-js';
// import TitleComponent from '@/components/TitleComponent';
import { getToken, getMonitoringList } from '@/api/securitySurveillance/index.js';
import { ref, onMounted, watch, nextTick, onUnmounted } from 'vue';
import { useUserStore } from '@/store/modules/user';
const activeIndex = ref(0); // 初始选中第一个视频
const isExpanded = ref(true); // 初始为扩展
const accessToken = ref('')
@ -111,6 +111,7 @@ const totalRecords = ref(0);
const activeTab = ref('live');
const bigVideoRef = ref<HTMLDivElement>(null);
const smallVideoRefs = ref<Array<HTMLDivElement | null>>([]); // 使用数组存储多个视频容器引用
const currentProject = computed(() => useUserStore().selectedProject);
const videoList = ref([]);
// 存储第二页的数据,用于处理扩展视图右边视频不足的情况
@ -178,7 +179,9 @@ const getMonitoringListData = async () => {
const currentPageSize = isExpanded.value ? 4 : 9;
const { data: { object, sum }, } = await getMonitoringList({
pageStart: pageStart.value,
pageSize: currentPageSize
pageSize: currentPageSize,
isflow: true,
projectId: currentProject.value?.id,
})
totalRecords.value = Number(sum)
// 确保object是数组如果不是则使用空数组