refactor(测试跟踪): 测试报告表格在浏览器尺寸发生变化下触发重新布局函数,防止表格错位
--bug=1025014 --user=宋天阳 【测试跟踪】报告列表-将窗口从显示器拖动到MAC终端-复选框和列表数据显示错位 https://www.tapd.cn/55049933/s/1358153
This commit is contained in:
parent
ec3a42c9ea
commit
939b152149
|
@ -295,10 +295,18 @@ export default {
|
||||||
watch: {
|
watch: {
|
||||||
$route(to, from) {},
|
$route(to, from) {},
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
window.addEventListener("resize", this.resizeTable, false);
|
||||||
|
},
|
||||||
activated() {
|
activated() {
|
||||||
this.init();
|
this.init();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
resizeTable() {
|
||||||
|
if (this.$refs.testPlanReportTable) {
|
||||||
|
this.$refs.testPlanReportTable.doLayout();
|
||||||
|
}
|
||||||
|
},
|
||||||
init() {
|
init() {
|
||||||
this.projectId = this.$route.params.projectId;
|
this.projectId = this.$route.params.projectId;
|
||||||
this.batchButtons = this.publicButtons;
|
this.batchButtons = this.publicButtons;
|
||||||
|
|
Loading…
Reference in New Issue