From b6c1e6879a6d358564c9f92a328d9e240618f376 Mon Sep 17 00:00:00 2001 From: songshankun <songshankun@foxmail.com> Date: 星期四, 28 九月 2023 14:04:40 +0800 Subject: [PATCH] fix: 修复列表组件在flex容器中高度不断增长的问题 --- src/components/makepager/TableCommonView.vue | 14 ++++++++++---- 1 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/components/makepager/TableCommonView.vue b/src/components/makepager/TableCommonView.vue index 93a80ef..4441978 100644 --- a/src/components/makepager/TableCommonView.vue +++ b/src/components/makepager/TableCommonView.vue @@ -216,10 +216,16 @@ .querySelector(".el-table__footer") var cell = current.rows[0].cells for (let i = 0; i < this.showSummary.mergeNumber; i++) { - cell[i].style.display = "none" + cell[i] && cell[i].style && (cell[i].style.display = "none") } - cell[this.showSummary.mergeNumber].classList.remove("is-left") - cell[this.showSummary.mergeNumber].colSpan = this.showSummary.mergeNumber.toString() + if (cell[this.showSummary.mergeNumber]){ + if (cell[this.showSummary.mergeNumber].classList){ + cell[this.showSummary.mergeNumber].classList.remove("is-left") + } + if (cell[this.showSummary.mergeNumber].colSpan){ + cell[this.showSummary.mergeNumber].colSpan = this.showSummary.mergeNumber.toString() + } + } } }) } @@ -455,7 +461,7 @@ // background: #06c062; top: 0; right: -6px; - z-index: 9999; + z-index: 11; .label { position: absolute; top: 6px; -- Gitblit v1.8.0