no message

Former-commit-id: 0de9bd387316a073692d5f9eb91b396e278d91eb
Former-commit-id: 0d79fe94dc93c64ce24d9d1d193a7ce8dd7e29d4
Former-commit-id: 8ba36adb3ffcdb3a607cc86310dadd8418e2f5e8
This commit is contained in:
李杨
2018-02-17 12:36:11 +08:00
parent fb4c27f0d6
commit 012595753a

View File

@@ -44,15 +44,13 @@ export default {
mounted () { mounted () {
// 如果设置了在 mounted 后自动初始化 就在这里初始化 // 如果设置了在 mounted 后自动初始化 就在这里初始化
if (this.autoInit) { if (this.autoInit) {
setTimeout(() => { this.init()
this.initHandler()
}, 0)
} }
}, },
watch: { watch: {
// 数据改变 // 数据改变
data () { data () {
this.changeData() this.refreshData()
} }
}, },
methods: { methods: {
@@ -92,6 +90,20 @@ export default {
} else { } else {
// 以后看着办 // 以后看着办
} }
},
// 初始化
init () {
this.$log(
'@/components/charts/G2/mixins/G2.js',
'如果你看到这条消息 请检查是否在图表组件中设置init方法'
)
},
// 更新数据
refreshData () {
this.$log(
'@/components/charts/G2/mixins/G2.js',
'如果你看到这条消息 请检查是否在图表组件中设置refreshData方法'
)
} }
} }
} }