From 959fae1b74a4ff59f8afc47c3522dd17a3e2d18b Mon Sep 17 00:00:00 2001 From: haha Date: Thu, 10 Aug 2023 23:36:55 +0800 Subject: [PATCH] update code --- src/api/project/index.js | 11 +- src/components/header.js | 2 +- src/pages/index/indexDlg2.vue | 341 +++++++++++++++++++++++++------ src/pages/init.js | 3 +- src/pages/progress/indexDlg1.vue | 11 +- src/pages/progress/indexDlg3.vue | 62 ++++-- 6 files changed, 345 insertions(+), 85 deletions(-) diff --git a/src/api/project/index.js b/src/api/project/index.js index 13cc970..2ecc7e6 100644 --- a/src/api/project/index.js +++ b/src/api/project/index.js @@ -13,8 +13,17 @@ const getProjectBuildNode=projectId=>{ method: 'get' }) } +const getProgressProjects=()=>{ + return request({ + url:`bgscreen/project/getProgressProjects`, + method: 'get' + }) +}; export default{ findProjectByDept, - getProjectBuildNode + getProjectBuildNode, + getProgressProjects } + + diff --git a/src/components/header.js b/src/components/header.js index 46145c0..8a3012f 100644 --- a/src/components/header.js +++ b/src/components/header.js @@ -15,7 +15,7 @@ Vue.component("screen-header", {
质量管理
进度管理
视频管理
-
技术管理
+
工程管理
diff --git a/src/pages/index/indexDlg2.vue b/src/pages/index/indexDlg2.vue index e79fc36..49ab5df 100644 --- a/src/pages/index/indexDlg2.vue +++ b/src/pages/index/indexDlg2.vue @@ -1,6 +1,6 @@ @@ -88,6 +154,7 @@ export default { return { nav: 0, show: false, + fontSize:0, tableData1: [], tableData2: [], tableData3: [], @@ -180,6 +247,9 @@ export default { }, methods: { + getState(s){ + return 'state-'+['','正常','滞后'].indexOf(s); + }, toggleNav(n) { this.nav = n; }, @@ -207,4 +277,147 @@ export default { color: #6de9f7; } } -} \ No newline at end of file +} + \ No newline at end of file diff --git a/src/pages/init.js b/src/pages/init.js index 19136e9..44449f3 100644 --- a/src/pages/init.js +++ b/src/pages/init.js @@ -15,4 +15,5 @@ Vue.prototype.$tryToJson=(str,def=null)=>{ }catch(e){ return def; } - } \ No newline at end of file +} +window.jhcaches={}; \ No newline at end of file diff --git a/src/pages/progress/indexDlg1.vue b/src/pages/progress/indexDlg1.vue index b9601de..2734201 100644 --- a/src/pages/progress/indexDlg1.vue +++ b/src/pages/progress/indexDlg1.vue @@ -4,7 +4,7 @@
- - + - - +
-
项目形象进度
+
项目形象进度
@@ -10,7 +10,8 @@
    -
  • {{ item.text }} +
  • {{ + item.projectName }}
@@ -20,7 +21,7 @@
- - - - + + +
+ style="flex-grow: 1;max-height: 750px;min-height:400px;overflow: auto;width: calc(100% - 504px);margin-top:8px;">
-
+
暂无数据
@@ -146,7 +152,15 @@ export default { }, mounted() { - + let objs = window.jhcaches?.progressProjects + if (objs && objs.length > 0) { + this.prjs = objs; + return; + } + this.$api.project.getProgressProjects().then(d => { + this.prjs = d.data || []; + window.jhcaches.progressProjects = this.prjs; + }); }, methods: { @@ -159,25 +173,36 @@ export default { }, modifyLeftBtn() { let item = this.findItem(); + let idx = 0; if (item) { - let idx = this.prjs.indexOf(item); + idx = this.prjs.indexOf(item); if (idx > 0) { idx--; + } else { + idx = this.prjs.length - 1; } - this.setScreenLiSel2(this.prjs[idx]); + + } else { + idx = 0; } + this.setScreenLiSel2(this.prjs[idx]); }, modifyRightBtn() { let item = this.findItem(); + let idx = 0; if (item) { - let idx = this.prjs.indexOf(item); + idx = this.prjs.indexOf(item); if (idx < this.prjs.length - 2) { idx++; + } else { + idx = 0; } - this.setScreenLiSel2(this.prjs[idx]); + } else { + idx = 0; } + this.setScreenLiSel2(this.prjs[idx]); }, showScreenUlSel2() { this.showSel2 = true @@ -186,7 +211,6 @@ export default { this.showSel2 = false }, showDialog(scheduleInfo, prjs) { - this.prjs = prjs; this.scheduleInfo = scheduleInfo; this.localStorage2 = JSON.parse(localStorage.getItem("data2")) this.dept2 = this.localStorage2.text; @@ -231,6 +255,7 @@ export default { } } } + &.font-size-1 { .popup-project-introduction-details { .col-2 { @@ -253,6 +278,13 @@ export default { width: 40px !important; height: 40px !important; cursor: pointer; + + &.active { + * { + fill: aqua; + } + } + } }