fix: 删除无用代码
This commit is contained in:
@@ -15,6 +15,7 @@
|
|||||||
type="selection"
|
type="selection"
|
||||||
width="55">
|
width="55">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!--key只使用item.prop的话,拖拽后,界面无响应,添加index后问题解决-->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
v-for="(item, index) in customTableTitles"
|
v-for="(item, index) in customTableTitles"
|
||||||
:key="item.prop+index"
|
:key="item.prop+index"
|
||||||
@@ -74,22 +75,7 @@ export default {
|
|||||||
prop: 'remark',
|
prop: 'remark',
|
||||||
show: true
|
show: true
|
||||||
}
|
}
|
||||||
],
|
]
|
||||||
isRefresh: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
customTableTitles (n) {
|
|
||||||
// 数据变化,界面未渲染,vue3.2弃用$set,使用reactive绑定数组,界面也未响应,该方法不优美,后续有更佳替代方案时替换
|
|
||||||
if (n && n.length > 0) {
|
|
||||||
if (n[0].flag === 'drag') {
|
|
||||||
// 重新渲染,会导致界面偶现闪的情况,点击checkbox时界面闪会比较丑,故不处理点击的情况
|
|
||||||
this.isRefresh = false
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.isRefresh = true
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user