<template>
    <v-sheet
        :height="height"
    >
        <cs-datatable 
            :datatable="datatable"
            :width="datatableWidth"
            :height="height - 8"
        />
    </v-sheet>
</template>

<script>
    export default {
        
        props: {
            app: {required: true},
            dataprovider: {required: true},
            height: {default: null},
            width: {default: null},
        },

        computed: {
            datatable() {
                return this.app.datatables.Team;
            },

            datatableWidth() {
                let r = this.width ? this.width : 100000;

                if(this.datatable.dtWidth < r)
                {
                    r = this.datatable.dtWidth;
                }
                return r;
            }
        },

        components: {
            CsDatatable: require('@CsVueComp/datatable/CsDatatable').default,
        },

        name: 'TeamItems',

    }
</script>