123456789101112131415161718192021222324 |
- import Vue from 'vue'
- import App from './App'
- Vue.config.productionTip = false
- Vue.config.silent = true
- openerp.vue_module = (instance, local) => {
- local.VueWidget = instance.Widget.extend({
- start() {
- this.vm = new Vue({
- el: this.el,
- template: '<App />',
- components: { App }
- })
- },
- destroy() {
- this.vm.$destroy()
- $(this.vm.$el).remove()
- this.vm = null
- }
- })
- instance.web.client_actions.add('vue_module.vue_module_action', 'instance.vue_module.VueWidget')
- }
|