Merge remote-tracking branch 'upstream/2.0' into 2.0
This commit is contained in:
commit
67ab89108c
3 changed files with 47 additions and 64 deletions
|
@ -63,13 +63,21 @@
|
|||
});
|
||||
const res = Vue.compile(cell.outerHTML);
|
||||
// todo 临时解决方案
|
||||
|
||||
// 获取父组件使用的局部 component
|
||||
const components = {};
|
||||
Object.getOwnPropertyNames($parent.$options.components).forEach(item => {
|
||||
components[item] = $parent.$options.components[item];
|
||||
});
|
||||
|
||||
const component = new Vue({
|
||||
render: res.render,
|
||||
staticRenderFns: res.staticRenderFns,
|
||||
methods: methods,
|
||||
data () {
|
||||
return $parent._data;
|
||||
}
|
||||
},
|
||||
components: components
|
||||
});
|
||||
component.row = this.row;
|
||||
component.column = this.column;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue