From 00b1ebb438e9c76e33e69a8058c58a6ccb26067f Mon Sep 17 00:00:00 2001 From: wwp <782568523@qq.com> Date: Thu, 15 Aug 2024 11:50:17 +0800 Subject: [PATCH 1/8] =?UTF-8?q?=E9=A2=84=E8=AD=A6=E6=A0=91=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SafeCampus.WEB/src/views/warn/zjrq/index.vue | 294 ++++++++++--------- 1 file changed, 162 insertions(+), 132 deletions(-) diff --git a/SafeCampus.WEB/src/views/warn/zjrq/index.vue b/SafeCampus.WEB/src/views/warn/zjrq/index.vue index a2ad315..1b63d83 100644 --- a/SafeCampus.WEB/src/views/warn/zjrq/index.vue +++ b/SafeCampus.WEB/src/views/warn/zjrq/index.vue @@ -4,125 +4,147 @@ * @Date: 2023-12-15 15:44:05 !--> @@ -157,18 +179,19 @@ let warnOptions = ref([]); function getWarnTypeList() { setTimeout(async ()=> { await warnZJRQApi.warnType({}).then((res:any) => { - let { code, data } = res; - - if (code == 200) { - warnOptions.value = data.map((item:any) => { - return { - label: item.name, - value: item.code - }; - }) - - } - }); + let { code, data } = res; + + if (code == 200) { + warnOptions.value = data; + // warnOptions.value = data.map((item:any) => { + // return { + // label: item.name, + // value: item.code + // }; + // }) + + } + }); }) } @@ -225,10 +248,10 @@ const columns: ColumnProps[] = [ prop: "alarmType", label: "预警类型", enum: warnOptions, - search: { - el: "tree-select", - // span: 1 - } + // search: { + // el: "tree-select", + // // span: 1 + // } }, { prop: "warnHand", @@ -252,7 +275,7 @@ const columns: ColumnProps[] = [ }, search: { el: "tree-select", - // span: 1 + span: 0.1 } }, { @@ -265,7 +288,7 @@ const columns: ColumnProps[] = [ return (
[] = [ time-format="HH:mm:ss" value-format="YYYY-MM-DD HH:mm:ss" /> - - + {/* - */} + - [] = [ { prop: "operation", label: "操作", width: 250, fixed: "right" } ]; + /** * 删除 * @param ids id数组 @@ -336,13 +361,18 @@ const videoUrls = ref(''); const onPlay = (url:string) => { videoVisible.value = true; videoUrls.value = url - console.log(videoUrls.value) } const handleCloseVideo = () => { videoVisible.value = false; videoUrls.value = '' }; - +const alarmType = ref() +function changeType(val: number | string) { + alarmType.value = val + proTable.value!.pageable.pageNum = 1; + proTable.value!.searchParam.alarmType = val; + proTable.value!.search(); +} \ No newline at end of file diff --git a/SafeCampus.WEB/src/views/screen/component/classroom/classNotice.vue b/SafeCampus.WEB/src/views/screen/component/classroom/classNotice.vue index 83f6a5a..e10cff8 100644 --- a/SafeCampus.WEB/src/views/screen/component/classroom/classNotice.vue +++ b/SafeCampus.WEB/src/views/screen/component/classroom/classNotice.vue @@ -30,7 +30,13 @@ const props = defineProps({ }); const alarmList = ref([]); onMounted(() => { + init(); +}); +const init = () => { alarmList.value = props.screenData.alarmList || []; +}; +defineExpose({ + init }); \ No newline at end of file diff --git a/SafeCampus.WEB/src/views/screen/component/classroom/stuEnterList.vue b/SafeCampus.WEB/src/views/screen/component/classroom/stuEnterList.vue index 653aea8..f136e30 100644 --- a/SafeCampus.WEB/src/views/screen/component/classroom/stuEnterList.vue +++ b/SafeCampus.WEB/src/views/screen/component/classroom/stuEnterList.vue @@ -37,11 +37,17 @@ const props = defineProps({ }); const studentList = ref([]); onMounted(() => { + init(); +}); +const init = () => { studentList.value = props.screenData.studentList; studentList.value = studentList.value.map(e => { e.faceUrl = e.faces.length ? e.faces[0].faceUrl : ""; return e; }); +}; +defineExpose({ + init });