From 34b387da804c923d4fba05828bccbfa0ba394035 Mon Sep 17 00:00:00 2001
From: X_Rian <904416525@qq.com>
Date: Mon, 29 Jul 2024 17:19:55 +0800
Subject: [PATCH] =?UTF-8?q?flx=EF=BC=9A=E4=BF=AE=E6=94=B9=E6=8C=87?=
=?UTF-8?q?=E6=8C=A5=E9=83=A8=E5=A4=A7=E5=B1=8F?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.env.development | 4 +-
.env.production | 4 +-
src/api/modules/agjtCommandApi.ts | 28 +-
src/config/config.ts | 4 +-
src/routers/modules/staticRouter.ts | 4 +-
.../commandCenter/centerBottom.vue | 28 +-
.../commandScreen/commandCenter/centerTop.vue | 79 ++-
.../commandScreen/commandCenter/index.vue | 2 +-
.../commandCenter/leftBottom.vue | 10 +-
.../dialogCompnnents/data-dialog.vue | 58 +-
.../dialogCompnnents/member-count-list.vue | 1 +
.../month-safe-score-detail.vue | 242 ++++++++
.../dialogCompnnents/month-safe-score.vue | 281 ++++-----
.../dialogCompnnents/oldmonth-safe-score.vue | 548 ++++++++++++++++++
.../dialogCompnnents/progress-tree.vue | 31 +-
.../dialogCompnnents/weather-info.vue | 55 +-
16 files changed, 1134 insertions(+), 245 deletions(-)
create mode 100644 src/views/commandScreen/dialogCompnnents/month-safe-score-detail.vue
create mode 100644 src/views/commandScreen/dialogCompnnents/oldmonth-safe-score.vue
diff --git a/.env.development b/.env.development
index 4f79e0e..b2363f9 100644
--- a/.env.development
+++ b/.env.development
@@ -4,7 +4,7 @@ NODE_ENV = 'development'
# 本地环境接口地址(/api/index.ts文件中使用)
# 后端本地
# VITE_API_URL = 'http://192.168.34.155:19111'
-VITE_API_URL = 'http://192.168.34.221:9111' #雄哥本地
+# VITE_API_URL = 'http://192.168.34.221:9111' #雄哥本地
# VITE_API_URL = 'http://182.90.224.237:51234' #雄哥远程
# VITE_API_URL = 'http://192.168.34.221:28889'
# VITE_API_URL = 'http://121.196.214.246/api'
@@ -17,7 +17,7 @@ VITE_API_URL = 'http://192.168.34.221:9111' #雄哥本地
# 演示平台
# VITE_API_URL = 'http://jxj.zhgdyun.com:9809'
# 百色七参数线上地址
-# VITE_API_URL = 'http://101.43.164.214:11111'
+VITE_API_URL = 'http://101.43.164.214:11111'
# 七参数标准版(测试平台)
# VITE_API_URL = 'http://jxj.zhgdyun.com:15551'
# 七参数标准版(测试平台)
diff --git a/.env.production b/.env.production
index 2cbd7de..be47104 100644
--- a/.env.production
+++ b/.env.production
@@ -21,10 +21,10 @@ NODE_ENV = "production"
# 七参数标准版(测试平台)
# VITE_API_URL = 'http://182.90.224.237:15551'
# agjt
-VITE_API_URL = 'http://42.180.188.17:9809' #生产环境
+# VITE_API_URL = 'http://42.180.188.17:9809' #生产环境
# VITE_API_URL = 'http://42.180.188.17:11211' #测试环境
# 苏立信/重庆市南岸区
-# VITE_API_URL = 'http://101.43.164.214:11111'
+VITE_API_URL = 'http://101.43.164.214:11111'
# 中科安信
# VITE_API_URL = 'http://8.136.222.164:8808'
# 中科佳成
diff --git a/src/api/modules/agjtCommandApi.ts b/src/api/modules/agjtCommandApi.ts
index 9720ee7..9d55701 100644
--- a/src/api/modules/agjtCommandApi.ts
+++ b/src/api/modules/agjtCommandApi.ts
@@ -148,7 +148,9 @@ export const getStatsDirectorateBigScreenApi = (params: {}, showLoading: boolean
};
// centerTop评分数据接口
export const getStatScoreApi = (params: {}, showLoading: boolean) => {
- return http.get(BASEURL + `/xmgl/xzSecurityQualityInspectionRecord/getStatScore`, params, { headers: { noLoading: showLoading } });
+ return http.get(BASEURL + `/xmgl/xzSecurityQualityInspectionRecord/getStatScore`, params, {
+ headers: { noLoading: showLoading }
+ });
};
// 项目人员考勤
@@ -232,6 +234,26 @@ export const getXzParentChildTaskListApi = (params: {}) => {
export const getXzMilestoneListApi = (params: {}) => {
return http.post(BASEURL + `/xmgl/xzMilestone/list`, params, { headers: { noLoading: true } });
};
-
-
// 甘特图接口结束位置
+// 获取月度安全综合评分(五种)
+export const getFiveScoresApi = (params: {}, showLoading: boolean) => {
+ return http.post(BASEURL + `/xmgl/safetyInspectionStandardBigScreen/getFiveScores`, params, {
+ headers: { noLoading: showLoading }
+ });
+};
+// 获取月度安全综合评分(十种)
+export const getScoresApi = (params: {}) => {
+ return http.post(BASEURL + `/xmgl/safetyInspectionStandardBigScreen/getScores`, params, { headers: { noLoading: true } });
+};
+// 获取分项检查评分表列表
+export const getTypeRecordListApi = (params: {}) => {
+ return http.post(BASEURL + `/xmgl/safetyInspectionStandardBigScreen/getTypeRecordList`, params, {
+ headers: { noLoading: true }
+ });
+};
+// 获取分项检查评分表详情
+export const getScoresDetailsApi = (params: {}) => {
+ return http.post(BASEURL + `/xmgl/safetyInspectionStandardBigScreen/getScoresDetails`, params, {
+ headers: { noLoading: true }
+ });
+};
diff --git a/src/config/config.ts b/src/config/config.ts
index dde00df..6a00fc6 100644
--- a/src/config/config.ts
+++ b/src/config/config.ts
@@ -29,7 +29,7 @@ export const BASE_IMAGE_URL = import.meta.env.VITE_BASE_IMAGE_URL;
// export const COMPANY: string = "as"; //鞍山项目
// export const COMPANY: string = "agjt"; //鞍钢集团
// export const COMPANY: string = "tj"; // 同济项目
-export const COMPANY: string = "agjtLive"; //鞍钢集团现场大屏
+// export const COMPANY: string = "agjtLive"; //鞍钢集团现场大屏
// export const COMPANY: string = "agjtCommand"; //鞍钢集团指挥部大屏
// export const COMPANY: string = "agjtProjectKanban"; //鞍钢集团项目看板大屏
// export const COMPANY: string = "agjtOverviewScreen"; //鞍钢集团项目总览
@@ -42,7 +42,7 @@ export const COMPANY: string = "agjtLive"; //鞍钢集团现场大屏
// export const COMPANY: string = "jsyc"; // 江苏盐城项目
// export const COMPANY: string = "syhy"; //沈阳合盈盘锦项目 (需要去src\routers\modules\staticRouter.ts更换首页)
// export const COMPANY: string = "jxwjj"; //嘉兴王江泾公用码头项目 (需要去src\routers\modules\staticRouter.ts更换首页)
-// export const COMPANY: string = "phmw"; //鄱湖美湾医疗、医美产业集群项目 (需要去src\routers\modules\staticRouter.ts更换首页)
+export const COMPANY: string = "phmw"; //鄱湖美湾医疗、医美产业集群项目 (需要去src\routers\modules\staticRouter.ts更换首页)
// export const COMPANY: string = "xjnb"; // 新建宁波项目
// export const COMPANY: string = "ahsa"; // 安徽水安项目
// export const COMPANY: string = "zkax"; // 中科安信项目
diff --git a/src/routers/modules/staticRouter.ts b/src/routers/modules/staticRouter.ts
index f875a6c..a2c57e0 100644
--- a/src/routers/modules/staticRouter.ts
+++ b/src/routers/modules/staticRouter.ts
@@ -26,11 +26,11 @@ export const staticRouter: RouteRecordRaw[] = [
name: "大屏",
// component: () => import("@/views/sevenLargeScreen/indexL.vue"), //七参数标准版
// component: () => import("@/views/commandScreen/indexCommand.vue"), //指挥部大屏
- component: () => import("@/views/agjtLiveScreen/indexLive.vue"), //鞍钢现场大屏
+ // component: () => import("@/views/agjtLiveScreen/indexLive.vue"), //鞍钢现场大屏
// component: () => import("@/views/overviewScreen/indexCommand.vue"), //总览大屏
// component: () => import("@/views/locationLive/locationL.vue"), //人员定位大屏
// component: () => import("@/views/agjtProjectKanban/indexL.vue"), //鞍钢集团项目看板大屏
- // component: () => import("@/views/sevenLargeScreen/indexL_syhy.vue"), // 只有一级路由(盘锦、嘉兴、鄱湖美湾医疗项目需切换至该首页)
+ component: () => import("@/views/sevenLargeScreen/indexL_syhy.vue"), // 只有一级路由(盘锦、嘉兴、鄱湖美湾医疗项目需切换至该首页)
children: [
{
path: "/headNoise",
diff --git a/src/views/commandScreen/commandCenter/centerBottom.vue b/src/views/commandScreen/commandCenter/centerBottom.vue
index 2439026..07b533e 100644
--- a/src/views/commandScreen/commandCenter/centerBottom.vue
+++ b/src/views/commandScreen/commandCenter/centerBottom.vue
@@ -318,6 +318,7 @@ const getNoticeList = async (showLoading: boolean) => {
// listData.value = res.result.records;
// listData.value = res.result.page.records;
+ console.log(333333333, res.result.page.records);
listData.value = res.result.page.records.map((item: any) => {
let statusMsg1 = item.status == 2 ? "未整改" : item.status == 3 ? "未复查" : item.status == 4 ? "未核验" : "";
// item.status == 5 ? "合格":
@@ -1026,7 +1027,7 @@ onMounted(async () => {
width: 100%;
line-height: 110%;
display: flex;
- align-items: center;
+ // align-items: center;
// justify-content: flex-start;
justify-content: space-between;
// background-color: green;
@@ -1036,7 +1037,7 @@ onMounted(async () => {
white-space: nowrap;
display: flex;
justify-content: center;
- align-items: center;
+ // align-items: center;
font-size: 16px;
width: 80%;
@@ -1046,7 +1047,7 @@ onMounted(async () => {
background: rgba(224, 32, 32, 0.4);
border-radius: 3px;
padding: 0 15px;
- margin: 9px 0;
+ // margin: 9px 0;
margin-left: 2px;
}
@@ -1057,7 +1058,7 @@ onMounted(async () => {
background: rgba(244, 102, 73, 0.4);
border-radius: 3px;
padding: 0 15px;
- margin: 9px 0;
+ // margin: 9px 0;
margin-left: 2px;
}
@@ -1068,7 +1069,7 @@ onMounted(async () => {
background: rgba(236, 190, 69, 0.4);
border-radius: 3px;
padding: 0 15px;
- margin: 9px 0;
+ // margin: 9px 0;
margin-left: 2px;
}
@@ -1079,7 +1080,7 @@ onMounted(async () => {
background: rgba(83, 148, 247, 0.4);
border-radius: 3px;
padding: 0 15px;
- margin: 9px 0;
+ // margin: 9px 0;
margin-left: 2px;
}
@@ -1090,7 +1091,7 @@ onMounted(async () => {
background: rgba(148, 0, 211, 0.4);
border-radius: 3px;
padding: 0 15px;
- margin: 9px 0;
+ // margin: 9px 0;
margin-left: 2px;
}
@@ -1101,16 +1102,19 @@ onMounted(async () => {
background: rgba(0, 206, 209, 0.4);
border-radius: 3px;
padding: 0 15px;
- margin: 9px 0;
+ // margin: 9px 0;
margin-left: 2px;
}
-
+ > div:not(.itemContent) {
+ margin-top: 10px;
+ }
.itemContent {
margin-left: 10px;
font-size: 15px;
- white-space: nowrap;
+ // white-space: nowrap;
overflow: hidden;
- text-overflow: ellipsis;
+ // text-overflow: ellipsis;
+ white-space: normal;
width: 100%;
line-height: 30px;
}
@@ -1120,7 +1124,7 @@ onMounted(async () => {
// background-color: #fff;
width: 20%;
font-size: 16px;
-
+ line-height: 30px;
.timeInfo {
display: flex;
justify-content: flex-end;
diff --git a/src/views/commandScreen/commandCenter/centerTop.vue b/src/views/commandScreen/commandCenter/centerTop.vue
index 51fec7c..3133237 100644
--- a/src/views/commandScreen/commandCenter/centerTop.vue
+++ b/src/views/commandScreen/commandCenter/centerTop.vue
@@ -6,14 +6,20 @@
{{ statScore.hiddenDangerScore }}分
-->
- 安全隐患治理
+
+
+ 安全管理
+
@@ -21,59 +27,70 @@
-
安全教育
+
+
+ 施工支具
+
上月安全综合评分
- {{ statScore.lastMonthTotal }}
+ {{ statScore2.lastMonthScore }}
分
相较上月{{
- statScore.radio > 0
- ? "上升" + (statScore.radio ? statScore.radio : 0)
- : "下降" + (statScore.radio ? statScore.radio.toString().substr(1) : 0)
+ statScore2.differScoreRate > 0
+ ? "上升" + (statScore2.differScoreRate ? statScore2.differScoreRate : 0)
+ : "下降" + (statScore2.differScoreRate ? statScore2.differScoreRate.toString().substr(1) : 0)
}}
%
- {{ statScore.radio > 0 ? "↑" : "↓" }}
+ {{ statScore2.differScoreRate > 0 ? "↑" : "↓" }}
+
- {{ statScore.total }}
+ {{ statScore2.monthScore }}
分
-
+
-
+
-
+
安全评分
差
@@ -121,7 +138,7 @@ import * as echarts from "echarts";
import "echarts-liquidfill";
import { editProjectInfo, eidtProjectShowConfig, queryBySnData } from "@/api/modules/projectOverview";
-import { getStatsDirectorateBigScreenApi, getStatScoreApi } from "@/api/modules/agjtCommandApi";
+import { getStatsDirectorateBigScreenApi, getStatScoreApi, getFiveScoresApi } from "@/api/modules/agjtCommandApi";
import { selectLiveVideoListApi } from "@/api/modules/video";
import ckplayerComp from "./ckplayerComp.vue";
import { COMPANY } from "@/config/config";
@@ -216,7 +233,7 @@ function drawAqWater() {
label: {
normal: {
formatter: function () {
- return statScore.value.hiddenDangerScore + "分";
+ return statScore2.value.thisMonthScores.aqgl + "分";
},
textStyle: {
// color: "#6495ED", //蓝色
@@ -295,7 +312,7 @@ function drawWdWater() {
label: {
normal: {
formatter: function () {
- return statScore.value.dangerEngScore + "分";
+ return statScore2.value.thisMonthScores.wmsg + "分";
},
textStyle: {
color: "#fff",
@@ -373,8 +390,8 @@ function drawJyWater() {
label: {
normal: {
formatter: function () {
- // return statScore.value + "分"
- return "30分";
+ // return statScore2.value + "分"
+ return statScore2.value.thisMonthScores.sgzj + "分";
},
textStyle: {
color: "#fff",
@@ -452,7 +469,7 @@ function drawFxWater() {
label: {
normal: {
formatter: function () {
- return statScore.value.riskScore + "分";
+ return statScore2.value.thisMonthScores.gcqx + "分";
},
textStyle: {
color: "#fff",
@@ -530,7 +547,7 @@ function drawZnWater() {
label: {
normal: {
formatter: function () {
- return statScore.value.aiScore + "分";
+ return statScore2.value.thisMonthScores.wxzy + "分";
},
textStyle: {
color: "#fff",
@@ -606,11 +623,28 @@ let statScore = ref({
total: 0,
lastMonthTotal: 0
} as any);
+const statScore2 = ref({
+ differScoreRate: 0,
+ lastMonthScore: 0,
+ monthScore: 0,
+ thisMonthScores: {
+ aqgl: 0,
+ gcqx: 0,
+ sgzj: 0,
+ wmsg: 0,
+ wxzy: 0
+ }
+} as any);
//获取centerTop底部按钮显示数据
const getStatScore = async (showLoading: boolean) => {
+ // getStatScoreApi
const res = await getStatScoreApi({ projectSn: store.sn }, showLoading);
statScore.value = res.result;
+ const result = await getFiveScoresApi({ projectSn: store.sn }, showLoading);
+ statScore2.value = result.result;
+ console.log("获取月度安全综合评分(五种)", res.result);
+
drawAqWater();
drawWdWater();
drawJyWater();
@@ -931,6 +965,7 @@ onMounted(async () => {
background-size: cover;
background-position: center;
background-repeat: no-repeat;
+ cursor: pointer;
}
}
}
diff --git a/src/views/commandScreen/commandCenter/index.vue b/src/views/commandScreen/commandCenter/index.vue
index be771aa..7e65cd4 100644
--- a/src/views/commandScreen/commandCenter/index.vue
+++ b/src/views/commandScreen/commandCenter/index.vue
@@ -124,7 +124,7 @@ function goBackend(item: any) {
if (item.url != "") {
// window.location.replace('http://localhost:8080/#/login?command=1&pathItem='+ item.url +'&token=' + store.token);
console.log(BASEURL);
- window.open("http://192.168.34.175:8080" + "/#/login?command=1&pathItem=" + item.url + "&token=" + store.token, "_blank");
+ window.open("http://42.180.188.17:9809" + "/#/login?command=1&pathItem=" + item.url + "&token=" + store.token, "_blank");
// window.open('http://10.0.1.77:8080' + '/#/login?command=1&pathItem='+ item.url +'&token=' + store.token, '_blank');
}
}
diff --git a/src/views/commandScreen/commandCenter/leftBottom.vue b/src/views/commandScreen/commandCenter/leftBottom.vue
index b21fb64..0d7e3ee 100644
--- a/src/views/commandScreen/commandCenter/leftBottom.vue
+++ b/src/views/commandScreen/commandCenter/leftBottom.vue
@@ -310,8 +310,14 @@ const queryAttendanceOfEachCompany = async (showLoading: boolean) => {
);
if (res.result) {
projectCompanyWorkTotalList.value = res.result.projectCompanyWorkTotalList;
- xData.value = projectCompanyWorkTotalList.value.map(item => item.enterpriseName.substring(0, 4));
- yData.value = projectCompanyWorkTotalList.value.map(item => item.attendancePersonNum);
+ xData.value = projectCompanyWorkTotalList.value
+ .filter((item: any) => item.attendancePersonNum > 0)
+ .sort((a: any, b: any) => b.attendancePersonNum - a.attendancePersonNum)
+ .map((item: any) => item.enterpriseName.substring(0, 4));
+ yData.value = projectCompanyWorkTotalList.value
+ .filter((item: any) => item.attendancePersonNum > 0)
+ .sort((a: any, b: any) => b.attendancePersonNum - a.attendancePersonNum)
+ .map((item: any) => item.attendancePersonNum);
if (projectCompanyWorkTotalList.value.length > 0) {
isFlag.value = true;
drawBar();
diff --git a/src/views/commandScreen/dialogCompnnents/data-dialog.vue b/src/views/commandScreen/dialogCompnnents/data-dialog.vue
index 9fe07d2..f1b2198 100644
--- a/src/views/commandScreen/dialogCompnnents/data-dialog.vue
+++ b/src/views/commandScreen/dialogCompnnents/data-dialog.vue
@@ -1,12 +1,24 @@
@@ -77,11 +89,26 @@
+
+
+
-
+
@@ -122,6 +149,7 @@ import myMap from "./my-map.vue";
import radarMapList from "./radar-map-list.vue";
import memberAllShow from "./member-all-show.vue";
import memberMoreList from "./member-more-list.vue";
+import monthSafeScoreDetail from "./month-safe-score-detail.vue";
// import { GlobalStore } from "@/stores";
let showDialog = ref(false as any);
@@ -303,7 +331,7 @@ onMounted(async () => {});
background-size: 100% 100%;
z-index: 21;
}
- .dialog-content-ai{
+ .dialog-content-ai {
position: absolute;
box-sizing: border-box;
padding: 1%;
@@ -315,6 +343,20 @@ onMounted(async () => {});
background-size: 100% 100%;
z-index: 21;
}
+
+ .dialog-content-table {
+ position: absolute;
+ box-sizing: border-box;
+ padding: 1%;
+ left: 50%;
+ top: 50%;
+ width: 100%;
+ height: 90%;
+ background: url("@/assets/images/commandScreen/dialog-bg.png") no-repeat;
+ background-size: 100% 100%;
+ z-index: 21;
+ transform: translate(-49%, -65%);
+ }
.dialog-content-more {
position: absolute;
box-sizing: border-box;
@@ -326,12 +368,16 @@ onMounted(async () => {});
background: url("@/assets/images/commandScreen/dialog-bg.png") no-repeat;
background-size: 100% 100%;
z-index: 21;
+ // left: 50%;
+ // top: 50%;
+ // transform: translate(-50%, -50%);
}
.dialog-content,
.dialog-content-show,
.dialog-content-more,
.dialog-content-three,
+ .dialog-content-table,
.dialog-content-ai {
padding-top: 50px;
position: relative;
@@ -391,6 +437,10 @@ onMounted(async () => {});
padding-top: 70px;
position: relative;
}
+
+ .dialog-content-table {
+ padding-top: 35px;
+ }
.dialog-content-ai {
padding-top: 70px;
position: relative;
diff --git a/src/views/commandScreen/dialogCompnnents/member-count-list.vue b/src/views/commandScreen/dialogCompnnents/member-count-list.vue
index 35f2d74..81bc383 100644
--- a/src/views/commandScreen/dialogCompnnents/member-count-list.vue
+++ b/src/views/commandScreen/dialogCompnnents/member-count-list.vue
@@ -476,6 +476,7 @@ const searchForm = ref({
//tab控制属性
const currentTab = ref("danger" as any);
function handleChangeTab(val: any) {
+ if (currentTab.value == val) return;
currentTab.value = val;
partyMemberList.value = [];
pageNo.value = 1;
diff --git a/src/views/commandScreen/dialogCompnnents/month-safe-score-detail.vue b/src/views/commandScreen/dialogCompnnents/month-safe-score-detail.vue
new file mode 100644
index 0000000..7ba19d6
--- /dev/null
+++ b/src/views/commandScreen/dialogCompnnents/month-safe-score-detail.vue
@@ -0,0 +1,242 @@
+
+
+
+
+
+
+
+
+ |
+ {{ item }}
+ |
+
+
+
+
+ | {{ index + 1 }} |
+
+ 保证项目
+ |
+
+ 一般项目
+ |
+ |
+ {{ item.name }} |
+ {{ item.shouldScore }} |
+ {{ item.deductScore }} |
+ {{ item.score }} |
+
+
+ {{ eIndex + 1 }}、 {{ ele.inspectTime }}检查到{{ ele.mainEnterpriseName }}的{{
+ ele.regionName
+ }}责任区域内有一条{{ ele.dangerItemContent }}的隐患{{
+ ele.status == 2 ? "未整改" : ele.status == 3 ? "未复查" : ele.status == 4 ? "未核验" : ""
+ }},扣{{ ele.deductScore }}分
+
+ |
+
+ {{ tableInfo.score }}
+ |
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/commandScreen/dialogCompnnents/month-safe-score.vue b/src/views/commandScreen/dialogCompnnents/month-safe-score.vue
index bea1bd8..7763244 100644
--- a/src/views/commandScreen/dialogCompnnents/month-safe-score.vue
+++ b/src/views/commandScreen/dialogCompnnents/month-safe-score.vue
@@ -2,154 +2,100 @@
- 综合得分:{{ countData.total || 0 }}
+ 综合得分:{{ tableInfo.score || 0 }}
月度安全综合评分表
工程名称:{{ projectData.projectName || "" }}
- 表格日期:{{ currentDate }}
+
+ 按月筛选:
-
考核分类
-
考核指标
-
指标说明
-
单模块权重
-
单模块得分
-
扣除分数
-
模块权重
-
模块得分
+
项目名称及分值(点击进入各分项查看扣分详情)
+
+
+
+
+
+ |
+ {{ item.name }} |
+
+
+
+
+ | 单模块权重 |
+ {{ item }}% |
+
+
+ | 单项扣分 |
+
+ {{ item }}
+ |
+
+
+ | 单项得分 |
+ {{ item }} |
+
+
+
+
+ | 总计得分 |
+ {{ tableInfo.score }} |
+
+
+
-
-
-
-
- {{ key2 }}
-
-
-
-
- {{ index3 }}
-
-
{{ item.name }}
-
- {{ item.value }}
-
-
- {{ item.score }}
-
-
- {{ item.deduction }}
-
-
-
-
- 35%
- 15%
- 0%
- 30%
-
-
- {{ countData.hiddenDangerScore || 0 }}
- {{ countData.dangerEngScore || 0 }}
- {{ countData.riskscore || 0 }}
- 30
-
-
-
-
- AI报警
-
-
-
-
- AI违章抓拍
-
-
告警数量月度环比对比
-
- 100%
-
-
- {{ countData.aiModuleScore || 0 }}
-
-
- {{ countData.aiModuleDeScore || 0 }}
-
-
-
-
- 20%
-
-
- {{ countData.aiScore || 0 }}
-
-
-
-
-
综合得分
-
- {{ countData.total || 0 }}
-
-
-
-
-
+
diff --git a/src/views/commandScreen/dialogCompnnents/progress-tree.vue b/src/views/commandScreen/dialogCompnnents/progress-tree.vue
index 16333bd..05c5d2b 100644
--- a/src/views/commandScreen/dialogCompnnents/progress-tree.vue
+++ b/src/views/commandScreen/dialogCompnnents/progress-tree.vue
@@ -29,7 +29,7 @@
@@ -188,12 +188,13 @@ const getGanttStyle = (project: any) => {
const endLeft = endRef?.offsetLeft;
const ganttWidth = endLeft - startLeft + endWidth;
- return { left: startLeft + "px", width: ganttWidth + "px" };
+ return { left: startLeft + "px", width: ganttWidth + "px" } as any;
};
-const configGantts = (projects: any) => {
- // console.log("进入渲染 setGantts -- ", projects);
- projects.forEach((project: any) => {
- let { finishDate, name, gantts } = project;
+const configGantts = (projects: any[]) => {
+ console.log("进入渲染 setGantts -- ", projects, projects.length);
+ if (projects.length == 0) return;
+ Array.from(projects).forEach((project: any) => {
+ let { finishDate, name, gantts } = project as any;
const gantt = getGanttStyle(project);
if (gantt.background) return;
// gantt.background = colors.value[project.state - 1];
@@ -218,14 +219,14 @@ const configGantts = (projects: any) => {
// gantts.push(gantt);
// }
// }
- if (project.children.length > 0) {
- project.children && configGantts(project.children);
- }
+ // if (project.children.length > 0) {
+ // project.children && configGantts(project.children, type);
+ // }
});
};
-const setGantts = () => {
- if (props.treeData.length == 0) return;
- configGantts(props.treeData);
+const setGantts = (treeData: any[]) => {
+ if (treeData.length == 0) return;
+ configGantts(treeData);
};
const increaseDate = (date: any, delay: any) => {
const timestamp = new Date(date).getTime() + (delay + 1) * 1000 * 60 * 60 * 24;
@@ -266,9 +267,7 @@ const getDays = (date: any) => {
})();
};
onMounted(() => {
- nextTick(() => {
- setGantts();
- });
+ setGantts(props.treeData);
});
const handleOpen = (index: any, children: any) => {
// console.log(666);
@@ -280,7 +279,7 @@ const handleOpen = (index: any, children: any) => {
children.openedIndex = index;
}
// nextTick(() => {
- // setGantts(children);
+ // setGantts(children.children);
// });
// setTimeout(() => {
// setGantts(children);
diff --git a/src/views/commandScreen/dialogCompnnents/weather-info.vue b/src/views/commandScreen/dialogCompnnents/weather-info.vue
index 3560de5..471d8eb 100644
--- a/src/views/commandScreen/dialogCompnnents/weather-info.vue
+++ b/src/views/commandScreen/dialogCompnnents/weather-info.vue
@@ -152,7 +152,7 @@
备注:更新(进度填报)内容后该甘特图将自动更新
-
+
-
+
{{ tooltipContent.taskName }}
@@ -450,7 +450,12 @@ const headerList = reactive([
// { label: "逾期已完成", color: "#C13F5B" }
]);
-const projects = ref([] as any);
+const projectsInfo = reactive({
+ projectListAll: [] as any[],
+ pageNo: 1,
+ pageSize: 10,
+ projects: [] as any[]
+});
// const projects = ref([
// {
// pName: "抹灰工程1",
@@ -514,8 +519,8 @@ const onUpdate = async () => {
ElMessage.success("页面已更新");
};
-const scrollLeft = ref(0);
-const scrollTimer = ref(0);
+const scrollLeft = ref(0 as any);
+const scrollTimer = ref(0 as any);
const tooltipsStyle = ref({
display: "none",
@@ -553,14 +558,19 @@ const getDataList = () => {
projectSn: searchSn.value,
enterpriseId: treeData.value.id
}).then(res => {
- projects.value = dealArr(res.result);
+ projectsInfo.projects = dealArr(res.result);
+ // projectsInfo.projectListAll = dealArr(res.result);
+ // projectsInfo.projects = projectsInfo.projectListAll.slice(
+ // (projectsInfo.pageNo - 1) * projectsInfo.pageSize,
+ // projectsInfo.pageNo * projectsInfo.pageSize
+ // );
// console.log("获取甘特图数据", projects.value);
});
};
-const dealArr = arr => {
- arr.map(item => {
- item.gantts = [];
+const dealArr = (arr: any) => {
+ arr.map((item: any) => {
+ item.gantts = [] as any[];
item.delay = 0;
if (item.children && item.children.length > 0) {
dealArr(item.children);
@@ -621,6 +631,17 @@ const getDays = (date: any) => {
};
const handleScroll = (e: any) => {
+ // if (e.target.clientHeight + e.target.scrollTop === e.target.scrollHeight) {
+ // console.log(e.target.scrollLeft, e.target.scrollTop, e.target.scrollBottom);
+ // if (projectsInfo.projects.length >= projectsInfo.projectListAll.length) return;
+ // projectsInfo.pageNo += 1;
+ // const resultList = projectsInfo.projectListAll.slice(
+ // (projectsInfo.pageNo - 1) * projectsInfo.pageSize,
+ // projectsInfo.pageNo * projectsInfo.pageSize
+ // );
+ // projectsInfo.projects = projectsInfo.projects.concat(resultList);
+ // return;
+ // }
if (scrollTimer.value) {
clearTimeout(scrollTimer.value);
}
@@ -628,11 +649,10 @@ const handleScroll = (e: any) => {
scrollLeft.value = e.target.scrollLeft;
scrollTimer.value = null;
}, 100);
- // console.log(scrollLeft.value);
// if (e.target.scrollLeft == 0) return;
- const fixedElement1 = document.querySelectorAll(".fixed_1");
- const fixedElement2 = document.querySelectorAll(".fixed_2");
- const fixedElement3 = document.querySelectorAll(".fixed_3");
+ const fixedElement1: any = document.querySelectorAll(".fixed_1");
+ const fixedElement2: any = document.querySelectorAll(".fixed_2");
+ const fixedElement3: any = document.querySelectorAll(".fixed_3");
// console.log(fixedElement1);
// console.log(fixedElement1[0]);
// console.log(fixedElement1.length);
@@ -669,15 +689,16 @@ const handleLeave = () => {
tooltipsStyle.value.display = "none";
};
const dateList = computed(() => {
- let dates = [];
- const mapDates = data => {
- data.map(p => {
+ let dates = [] as any[];
+ const mapDates = (data: any) => {
+ data.map((p: any) => {
dates.push(p.startDate);
dates.push(p.finishDate);
+ if (p.children == 0) return;
p.children && mapDates(p.children);
});
};
- mapDates(projects.value);
+ mapDates(projectsInfo.projects);
dates = dates.map(date => date.slice(0, 7)).sort();
dates = [...new Set(dates)];
console.log("dateList----", dates);