<template>
    <div class="special">
        <report-option @query="handleQuery"></report-option>
        <report-table ref="table"></report-table>
    </div>
</template>

<script>
    import ReportOption from './component/ReportOption.vue'
    import ReportTable from './component/ReportTable.vue'

    export default {
        name:"Report",
        components: {
            ReportOption,
            ReportTable
        },
        methods: {
            resetForm() {
                if (this.$refs.table) {
                    this.$refs.table.resetForm()
                }
            },
            handleQuery(data) {
                if (this.$refs.table) {
                    this.$refs.table.resetForm(data)
                }
            }
        }
    }
</script>