From 547b799dff4a0a52275cdd4c7876ed61a858753b Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Wed, 28 Feb 2024 11:15:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../jiaoshi/KcZhihuijiaoshiStateLog.data.ts | 154 +++++++++++------- src/views/kc/jiaoshi/index.vue | 25 +-- 2 files changed, 105 insertions(+), 74 deletions(-) diff --git a/src/views/kc/jiaoshi/KcZhihuijiaoshiStateLog.data.ts b/src/views/kc/jiaoshi/KcZhihuijiaoshiStateLog.data.ts index 78bb719..ea2dd66 100644 --- a/src/views/kc/jiaoshi/KcZhihuijiaoshiStateLog.data.ts +++ b/src/views/kc/jiaoshi/KcZhihuijiaoshiStateLog.data.ts @@ -28,40 +28,68 @@ export const columns: BasicColumn[] = [ dataIndex: 'jsmc' }, { - title: '教师近景', + title: '教室近景', align: "center", - dataIndex: 'lbzj' + dataIndex: 'lbzj', + customRender: ({ text }) => { + if(text == 'green'){ + return "正常"; + }else{ + return "异常"; + } + }, }, { - title: '教师全景', + title: '教室全景', align: "center", - dataIndex: 'jsqj' + dataIndex: 'jsqj', + customRender: ({ text }) => { + if(text == 'green'){ + return "正常"; + }else{ + return "异常"; + } + }, }, { title: '学生全景', align: "center", - dataIndex: 'xsqj' + dataIndex: 'xsqj', + customRender: ({ text }) => { + if(text == 'green'){ + return "正常"; + }else{ + return "异常"; + } + }, }, { title: 'PPT', align: "center", - dataIndex: 'ppt' - }, - { - title: '绿色的数量', - align: "center", - dataIndex: 'greenNum' - }, - { - title: '状态指示', - align: "center", - dataIndex: 'type', - }, - { - title: '状态指示(标记)', - align: "center", - dataIndex: 'forceState', + dataIndex: 'ppt', + customRender: ({ text }) => { + if(text == 'green'){ + return "正常"; + }else{ + return "异常"; + } + }, }, + // { + // title: '绿色的数量', + // align: "center", + // dataIndex: 'greenNum' + // }, + // { + // title: '状态指示', + // align: "center", + // dataIndex: 'type', + // }, + // { + // title: '状态指示(标记)', + // align: "center", + // dataIndex: 'forceState', + // }, ]; //查询数据 @@ -69,53 +97,53 @@ export const searchFormSchema: FormSchema[] = [ { label: "教学楼名称", field: 'jxlName', - component: 'Input', + component: 'JInput', colProps: {span: 6}, }, { label: "教室名称", field: 'jsmc', - component: 'Input', - colProps: {span: 6}, - }, - { - label: "教师近景", - field: 'lbzj', - component: 'Input', - colProps: {span: 6}, - }, - { - label: "教师全景", - field: 'jsqj', - component: 'Input', - colProps: {span: 6}, - }, - { - label: "学生全景", - field: 'xsqj', - component: 'Input', - colProps: {span: 6}, - }, - { - label: "PPT", - field: 'ppt', - component: 'Input', - colProps: {span: 6}, - }, - { - label: "绿色的数量", - field: 'greenNum', - component: 'Input', - colProps: {span: 6}, - }, - { - label: "状态指示灯", - field: 'type', - component: 'JDictSelectTag', - componentProps:{ - }, + component: 'JInput', colProps: {span: 6}, }, + // { + // label: "教室近景", + // field: 'lbzj', + // component: 'Input', + // colProps: {span: 6}, + // }, + // { + // label: "教室全景", + // field: 'jsqj', + // component: 'Input', + // colProps: {span: 6}, + // }, + // { + // label: "学生全景", + // field: 'xsqj', + // component: 'Input', + // colProps: {span: 6}, + // }, + // { + // label: "PPT", + // field: 'ppt', + // component: 'Input', + // colProps: {span: 6}, + // }, + // { + // label: "绿色的数量", + // field: 'greenNum', + // component: 'Input', + // colProps: {span: 6}, + // }, + // { + // label: "状态指示灯", + // field: 'type', + // component: 'JDictSelectTag', + // componentProps:{ + // }, + // colProps: {span: 6}, + // }, ]; //表单数据 @@ -131,12 +159,12 @@ export const formSchema: FormSchema[] = [ component: 'Input', }, { - label: '教师近景', + label: '教室近景', field: 'lbzj', component: 'Input', }, { - label: '教师全景', + label: '教室全景', field: 'jsqj', component: 'Input', }, diff --git a/src/views/kc/jiaoshi/index.vue b/src/views/kc/jiaoshi/index.vue index f18fba9..5bb6e2e 100644 --- a/src/views/kc/jiaoshi/index.vue +++ b/src/views/kc/jiaoshi/index.vue @@ -48,7 +48,7 @@
未检测
-
{{ statusLogList.filter(x => x.forceState == 'red' || x.type != 'green' ).length || 0 }}
+
{{ statusLogList.filter(x => x.forceState == 'red' ).length || 0 }}
设备异常 @@ -121,13 +121,13 @@ {{ item.jsNum }} {{ item.child.filter(x => x.zbgn == '0').length || 0 }} - {{ item.child.filter(x => x.tjKftkzt == 1).length || 0 }} + {{ item.child.filter(x => x.tjKftkzt == 1).length || 0 }} 未检测 - {{ statusLogList.filter(x => x.jxlName == item.jxlName && ( x.forceState == 'red' || x.type != 'green') ).length }} + {{ statusLogList.filter(x => x.jxlName == item.jxlName && ( x.forceState == 'red' ) ).length }} 总数 可直播 开放听课 - +
设备异常
{{ statusLogList.find(x => x.jxlName == item.jxlName)?.createTime }}
@@ -198,13 +198,13 @@ - + @@ -507,7 +507,7 @@ 关闭前台展示 | 开放听课 | 关闭听课 - | 手动检测 + 检测教室 | 标记为有效 | @@ -1254,7 +1254,10 @@ function changeFlag(record, flag){ defHttp.post({ url: '/jiaoshi/kcZhihuijiaoshiStateLog/updateByJsbh', params: { jsbh: record.jsbh, forceState: flag - }}); + }}).then(res => { + queryParam.value.jxlName = null; + loadData(); + }); } function tableChange(pagination) {