From cef6deaa8830160b3e20c6a64e41ee6706b79649 Mon Sep 17 00:00:00 2001 From: kim131 <1035828775@qq.com> Date: Tue, 12 Jan 2021 11:26:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E6=8C=87=E6=B4=BE=E5=85=A8?= =?UTF-8?q?=E9=80=89=E6=9C=89=E6=97=B6=E5=80=99=E6=97=A0=E6=B3=95=E7=82=B9?= =?UTF-8?q?=E5=87=BBbug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../projDetail/components/personnel-list.vue | 4 +- .../components_web/projDetail/projDetail.vue | 85 ++++++++----------- 2 files changed, 40 insertions(+), 49 deletions(-) diff --git a/src/views/components_web/projDetail/components/personnel-list.vue b/src/views/components_web/projDetail/components/personnel-list.vue index a4ad80bf..d1d89b48 100644 --- a/src/views/components_web/projDetail/components/personnel-list.vue +++ b/src/views/components_web/projDetail/components/personnel-list.vue @@ -91,7 +91,9 @@ } .personnel-list { width: 100%; - min-width: 180px; + min-width: 375px; + max-width: 375px; + background-color: #fcfcfc; border-top-left-radius: 8px; border-top-right-radius: 8px; diff --git a/src/views/components_web/projDetail/projDetail.vue b/src/views/components_web/projDetail/projDetail.vue index 378dc3a6..cbac18ee 100644 --- a/src/views/components_web/projDetail/projDetail.vue +++ b/src/views/components_web/projDetail/projDetail.vue @@ -191,8 +191,9 @@ - + :handleCheckedOne="handleCheckedOne" + /> + @@ -312,37 +313,25 @@ import NestTemp from '../project/nestTemp.vue'; FileUploader, NestTemp, }, - watch: { - isShowDistWorkPage(val) { - if(val) { - setTimeout(()=> { - this.distWorkPartEl = this.$refs.distworkpart; - if(this.distWorkPartEl) { - this.distWorkPartEl.addEventListener('scroll', this.watchDistWorkPartScroll); - } - }, 50) - } - }, - isProjDescScroll(val) { - if(val) { - setTimeout(()=> { - this.projDescEl = this.$refs.projdesc; - if(this.projDescEl) { - this.projDescEl.addEventListener('scroll', this.watchProjDescScroll); - } - }, 50) - } - }, - isTemplateDescScroll(val) { - if(val) { - setTimeout(()=> { - this.templateDescEl = this.$refs.templatedesc; - if(this.templateDescEl) { - this.templateDescEl.addEventListener('scroll', this.watchTemplateDescScroll); - } - }, 50) - } + updated() { + if(this.$refs.projdesc) { + this.projDescEl = this.$refs.projdesc; + this.projDescEl.removeEventListener('scroll', this.watchProjDescScroll); + this.projDescEl.addEventListener('scroll', this.watchProjDescScroll); } + + if(this.$refs.distworkpart) { + this.distWorkPartEl = this.$refs.distworkpart; + this.distWorkPartEl.removeEventListener('scroll', this.watchDistWorkPartScroll); + this.distWorkPartEl.addEventListener('scroll', this.watchDistWorkPartScroll); + } + + if(this.$refs.templateDescEl) { + this.templateDescEl = this.$refs.templatedesc; + this.templateDescEl.removeEventListener('scroll', this.watchTemplateDescScroll); + this.templateDescEl.addEventListener('scroll', this.watchTemplateDescScroll); + } + }, mounted() { @@ -356,18 +345,18 @@ import NestTemp from '../project/nestTemp.vue'; // 加载项目详情 this.fetchProjectDetail(); this.getNestNode(sessionStorage.templateID); - // this.projDescEl = this.$refs.projdesc; - this.distWorkPartEl = document.querySelector('#distwork-part'); + this.projDescEl = this.$refs.projdesc; + // this.distWorkPartEl = document.querySelector('#distwork-part'); if(this.projDescEl) { this.projDescEl.addEventListener('scroll', this.watchProjDescScroll); } - // this.distWorkPartEl = this.$refs.distworkpart; - this.projDescEl = document.querySelector('#proj-desc'); + this.distWorkPartEl = this.$refs.distworkpart; + // this.projDescEl = document.querySelector('#proj-desc'); if(this.distWorkPartEl) { this.distWorkPartEl.addEventListener('scroll', this.watchDistWorkPartScroll); } - // this.templateDescEl = this.$refs.templatedesc; - this.templateDescEl = document.querySelector('#template-desc'); + this.templateDescEl = this.$refs.templatedesc; + // this.templateDescEl = document.querySelector('#template-desc'); if(this.templateDescEl) { this.templateDescEl.addEventListener('scroll', this.watchTemplateDescScroll); } @@ -606,7 +595,7 @@ import NestTemp from '../project/nestTemp.vue'; this.selectedUser.forEach(user => { user.folderPerm = (user.id === clickUser.id) ? 2 : 1; if(user.folderPerm === 2) { - this.InitData.manageUser.splice(0,1,user); + this.InitData && this.InitData.manageUser && this.InitData.manageUser.splice(0,1,user); } }) }, @@ -864,7 +853,7 @@ import NestTemp from '../project/nestTemp.vue'; // 删除的是具有项目管理权限的 且能运行到这里是可以删除的 const index = this.listManagerUser.findIndex(people => people.id === user.id); if(index > -1) { - this.listManageUser.splice(index, 1); + this.listManagerUser.splice(index, 1); } } @@ -1186,7 +1175,7 @@ import NestTemp from '../project/nestTemp.vue'; workNode.GeneralId = folder.listUser.length > 0 ? tempListUser.map(user => { return user.id }).join(',') : ''; const originFolder = oldPlainFolderList.find(oldFolder => oldFolder.id == folder.id); - console.log(originFolder); + // console.log(originFolder); const oldManagerId = originFolder.manageUser.length > 0 ? originFolder.manageUser[0].id : ''; workNode.OldManager = oldManagerId; workNode.OldGeneralId = originFolder.listUser.length > 0 ? originFolder.listUser.filter(oldUser => oldUser.id !== oldManagerId).map(user => { return user.id }).join(',') : ''; @@ -1376,21 +1365,20 @@ import NestTemp from '../project/nestTemp.vue'; .content-wrap { display:flex; - padding: 0 64px; align-items: flex-start; - } - + justify-content: center; + padding: 0 64px; - .set-content-wrap { - padding: 0 198px; } .content-wrap .graph-left-part, .content-wrap .right-part { width: 50%; + min-width: 480px; + max-width: 660px; } .right-part { - min-width: 400px; + // min-width: 400px; box-sizing: border-box; border-top-left-radius: 8px; border-top-right-radius: 8px; @@ -1576,7 +1564,8 @@ import NestTemp from '../project/nestTemp.vue'; } .set-personnel-list-width { - min-width: 180px; + min-width: 375px; + max-width: 375px; width: 36.231% !important; transition: width 2.5s ease; }