<template>
    <el-date-component-picker v-model="value"></el-date-component-picker>
</template>

<script>
    import ElDateComponentPicker from "./src/picker/date-picker"

    export default {
        name: "sh-select",
        components:{
            ElDateComponentPicker,
        },
        watch:{
            value: 'changeData' // 值可以为methods的方法名
        },
        data() {
            return{
                value: ''
            }
        },
        methods:{
            changeData(curVal,oldVal){//监听value变化
                this.$emit('dateChange', curVal)
            }
        }
    }
</script>

<style scoped>
</style>
