Commit 0ce5e00df87607518f929868a93f7fd00df8dfb0
Committed by
GitHub
Merge pull request #868 from lvqingan/2.0
修正table render的自定义组件中无法获取this.$store的问题
Showing
1 changed file
with
3 additions
and
0 deletions
Show diff stats
src/components/table/cell.vue
@@ -96,6 +96,9 @@ | @@ -96,6 +96,9 @@ | ||
96 | }, | 96 | }, |
97 | components: components | 97 | components: components |
98 | }); | 98 | }); |
99 | + if ($parent.$store != undefined) { | ||
100 | + component.$store = $parent.$store; | ||
101 | + } | ||
99 | component.row = this.row; | 102 | component.row = this.row; |
100 | component.column = this.column; | 103 | component.column = this.column; |
101 | 104 |