Vue数据改变页面不更新this.$set()的用法
时间:2020-09-24 16:13:22
收藏:0
阅读:540
这个博客的逗号是中文https://www.cnblogs.com/wangqi2019/p/11690208.html
element的 table 改变数据列表不更新,但是没用对。。。
if (this.treeId == item1.id) {
// 因有重复的属性id 不能直接合并 需重新改属性并赋值
item1.classification_id = this.activeTree.id;
item1.classification_code_name = this.activeTree.code + ‘ - ‘ + this.activeTree.name;
this.$set(item1,‘self_update‘,this.activeTree.id); // 先使用强制更新一下
delete item1.self_update;然后把这个属性再删了
}
})
原文:https://www.cnblogs.com/wangduojing/p/13723455.html
评论(0)