From 71bdd562ed0901296a5d28f071ceb078eaf0326c Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 4 Nov 2020 09:53:27 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=88=91=E7=9A=84=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=E7=95=8C=E9=9D=A2=E7=9A=84=E5=AE=9A=E6=97=B6=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E9=80=BB=E8=BE=91=EF=BC=8C=E6=AF=95=E7=AB=9F=E8=AF=B7?= =?UTF-8?q?=E6=B1=82=E9=87=8D=E5=8F=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/main_web/index/index.vue | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/views/main_web/index/index.vue b/src/views/main_web/index/index.vue index 9166f83b..13794171 100644 --- a/src/views/main_web/index/index.vue +++ b/src/views/main_web/index/index.vue @@ -251,7 +251,7 @@ export default { projPageList: [], // 分页项目数据 isEmpty: false, createUserId:'', - isProjectManager:0, + isProjectManager: false, newProjData: { projectData: { projID: "", @@ -305,6 +305,7 @@ export default { isShowProjSetting: false, isEditProjFolder: false, + fetchTickIns: null, }; }, mounted: function () { @@ -312,10 +313,14 @@ export default { //this.setDateTime(); //setInterval(this.setDateTime, 1000); this.listProjects(); - setInterval(this.listProjects, 1000 * 60); + // setInterval(this.listProjects, 1000 * 60); }, beforeDestroy() { sessionStorage.dotIndex = this.ind; + if(this.fetchTickIns) { + clearTimeout(this.fetchTickIns); + this.fetchTickIns = null; + } }, methods: { /** @@ -418,6 +423,7 @@ export default { const projectListRes = await prjService.queryProjectsByUserId(this.$store.state.accountId); this.projList=projectListRes.Data; this.projectsWithPage(); + this.fetchTickIns = setTimeout(() => this.listProjects(), 1000 * 60); }, /** * 设置分页项目数据