From 0f08e702553ca4f2faceaa8fa7d19ed8bee64cb7 Mon Sep 17 00:00:00 2001 From: junhong Date: Tue, 13 May 2025 16:09:15 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=A4=A7=E5=B1=8F=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/prompt/api.js | 2 +- src/components/prompt/index.vue | 89 ++++++++++--------- .../progress-alert/api.js | 10 +-- .../progress-alert/index.vue | 13 +-- src/views/large-screen/api.js | 10 +-- src/views/large-screen/index.vue | 23 +++-- 6 files changed, 61 insertions(+), 86 deletions(-) diff --git a/src/components/prompt/api.js b/src/components/prompt/api.js index dbf6d200..30e22f05 100644 --- a/src/components/prompt/api.js +++ b/src/components/prompt/api.js @@ -2,7 +2,7 @@ import axios from '@/utils/request' // 查询分页数据: export const iengineerlogList = (arg) => { return axios.request({ - url: '/iproductionplan/querywarn', + url: '/iwarn/list', method: 'get', params: arg, dataType: 'json', diff --git a/src/components/prompt/index.vue b/src/components/prompt/index.vue index 70d13730..b20603d7 100644 --- a/src/components/prompt/index.vue +++ b/src/components/prompt/index.vue @@ -15,57 +15,58 @@ const state = reactive({ arr: [], }); onMounted(() => { - proxy.$getsystemdict('purpose_expenses').then((res) => { - if (res.length > 0) { - iengineerlogList({ day: res[0].value }).then((res) => { - if (res.code == 200) { - res.data.slice(0, 3).map((item) => { - setTimeout(() => { - notify.value[item.id] = ElNotification({ - title: "进度预警提示", - zIndex: 999999999999, - duration: 10000, - position: "bottom-right", - message: h("div", [ - h( - "p", - {}, - "有" + - item.planName + - "的计划已滞后"+"需要您查看。" - ), + iengineerlogList().then((res) => { + if (res.code == 200) { + res.data.list.map((item) => { + setTimeout(() => { + notify.value[item.id] = ElNotification({ + title: "进度预警提示", + zIndex: 999999999999, + duration: 10000, + position: "bottom-right", + message: h("div", [ + h( + "p", + {}, + "有" + + item.planName + + "的计划已滞后" + "需要您查看。" + ), + h( + "p", + { + style: "display: flex;justify-content: space-between;", + }, + [ h( - "p", + "div", { - style: "display: flex;justify-content: space-between;", + style: + "color: #409EFF;cursor: pointer;text-align: right;margin-top: 10px;", + onClick: function () { + router.push({ + path: "/constructionScheduling/progressAlert" + }) + }, }, - [ - h( - "div", - { - style: - "color: #409EFF;cursor: pointer;text-align: right;margin-top: 10px;", - onClick: function () { - router.push({ - path:"/constructionScheduling/progressAlert" - }) - }, - }, - // "已了解,不再提醒" - "去查看" - ), - ] + // "已了解,不再提醒" + "去查看" ), - ]), - type: "warning", - }); - }, 10); - }) - - } + ] + ), + ]), + type: "warning", + }); + }, 10); }) + } }) + // proxy.$getsystemdict('purpose_expenses').then((res) => { + // if (res.length > 0) { + + // } + // }) }); diff --git a/src/views/constructionScheduling/progress-alert/api.js b/src/views/constructionScheduling/progress-alert/api.js index eb52b01f..86b0c427 100644 --- a/src/views/constructionScheduling/progress-alert/api.js +++ b/src/views/constructionScheduling/progress-alert/api.js @@ -8,15 +8,7 @@ export const iwarnlist = (arg) => { dataType: 'json', }) } -export const iengineerlogList = (arg) => { - return axios.request({ - url: '/iproductionplan/querywarn', - method: 'get', - params: arg, - dataType: 'json', - - }) -} + // 查询详情数据: export const iengineerlogGetById = (arg) => { return axios.request({ diff --git a/src/views/constructionScheduling/progress-alert/index.vue b/src/views/constructionScheduling/progress-alert/index.vue index 68658a58..8536f4bf 100644 --- a/src/views/constructionScheduling/progress-alert/index.vue +++ b/src/views/constructionScheduling/progress-alert/index.vue @@ -1,6 +1,6 @@ diff --git a/src/views/large-screen/api.js b/src/views/large-screen/api.js index 19895da6..0ed97656 100644 --- a/src/views/large-screen/api.js +++ b/src/views/large-screen/api.js @@ -24,15 +24,7 @@ export const iengineerlogList = (arg) => { dataType: 'json' }) } -// 进度预警 -export const querywarn = (arg) => { - return axios.request({ - url: '/iproductionplan/querywarn', - method: 'get', - params: arg, - dataType: 'json' - }) -} + // 工种统计 export const iuserworkerType = (arg) => { return axios.request({ diff --git a/src/views/large-screen/index.vue b/src/views/large-screen/index.vue index 349c112f..186add08 100644 --- a/src/views/large-screen/index.vue +++ b/src/views/large-screen/index.vue @@ -165,16 +165,19 @@
- + +
{{ item.planName }}
开始时间:{{ item.startTime }}
计划结束时间:{{ item.endTime }}
当前进度:
+ color="#0AA0FE" :stroke-width="8" + :percentage="Number(item.currentProgress ? item.currentProgress : 0)" + class="jd">
-
预警信息:{{ item.warnInfo ? item.warnInfo : '-' }}
+
备注:当前计划进度已滞后
@@ -289,7 +292,7 @@ import { ref, onMounted, reactive, nextTick } from 'vue' import { echartsZhu, echartsBing } from "./echartsOptions"; import { echart } from "../../echarts"; import { stausList } from './options' -import { getRecordPage, iengineerlogList, querywarn, iuserworkerType, iresourcescheduleList, vehiclestat, statistics, dataOverview, iwarnlist } from './api' +import { getRecordPage, iengineerlogList, iuserworkerType, iresourcescheduleList, vehiclestat, statistics, dataOverview, iwarnlist } from './api' const { proxy } = getCurrentInstance(); const tableTrue = ref(false); const router = useRouter(); @@ -519,16 +522,12 @@ function getIuserworkerType() { } // 进度预警 function getQuerywarn(params) { - proxy.$getsystemdict('purpose_expenses').then(async (res) => { - if (res.length > 0) { - // await querywarn({ day: res[0].value }) - await iwarnlist().then((res) => { - if (res.code == 200) { - state.warnList = res.data.list - } - }) + iwarnlist().then((res) => { + if (res.code == 200) { + state.warnList = res.data.list } }) + } // 门禁记录