<template>
    <div>
        <numberInput :value="inputValue" @sendValue="sendValue"></numberInput>
        <v-chart :options="chartOptions" style="height: 300px;"></v-chart>
    </div>
</template>

<script>
import numberInput from '../numberInput'
export default {
  name: 'chart',
  components: {
    numberInput
  },
  data() {
    return {
        inputValue: '1,2,23.4',
        chartOptions: {
            // ECharts 配置项...
            title: {
            text: '示例图表'
            },
            tooltip: {},
            xAxis: {
            data: ["衬衫","羊毛衫","雪纺衫","裤子","高跟鞋","袜子"]
            },
            yAxis: {},
            series: [{
            name: '销量',
            type: 'bar',
            data: [5, 20, 36, 10, 10, 20]
            }]
        }
    }
  },
  mounted() {
  },
  methods: {
    sendValue (data) {
        console.log('data-------', data)
    }
  }
};
</script>

<style lang="scss" scoped>
</style>