sylius_grid:
    grids:
        sylius_mollie_plugin_mollie_subscription:
            driver:
                name: doctrine/orm
                options:
                    class: "%sylius_mollie.model.mollie_subscription.class%"
            actions:
                item:
                    show:
                        type: show
            sorting:
                id: asc
            fields:
                id:
                    type: string
                    label: sylius.ui.id
                    sortable: id
                state:
                    type: twig
                    label: sylius_mollie.ui.subscription.fields.state
                    sortable: state
                    options:
                        template: "@SyliusMolliePlugin/admin/mollie_subscription/grid/field/state.html.twig"
                paymentState:
                    type: twig
                    label: sylius_mollie.ui.subscription.fields.payment_state
                    sortable: paymentState
                    options:
                        template: "@SyliusMolliePlugin/admin/mollie_subscription/grid/field/payment_state.html.twig"
                orders:
                    type: twig
                    label: sylius_mollie.ui.subscription.fields.orders
                    path: .
                    options:
                        template: "@SyliusMolliePlugin/admin/mollie_subscription/grid/field/orders.html.twig"

                createdAt:
                    type: datetime
                    label: sylius.ui.created_at
                    sortable: createdAt
                    options:
                        format: 'Y-m-d H:i:s'
                startedAt:
                    type: datetime
                    label: sylius_mollie.ui.subscription.fields.started_at
                    sortable: startedAt
                    options:
                        format: 'Y-m-d H:i:s'
                recentFailedPaymentsCount:
                    type: string
                    sortable: recentFailedPaymentsCount
                    label: sylius_mollie.ui.subscription.fields.recent_failed_payments_count
            filters:
                createdAt:
                    type: date
                    label: sylius_mollie.ui.subscription.grid.filters.created_at
                    options:
                        field: createdAt
                        label: test
                startedAt:
                    type: date
                    label: sylius_mollie.ui.subscription.grid.filters.started_at
                    options:
                        field: startedAt
                        label: test
                state:
                    type: subscription_state
                    label: sylius_mollie.ui.subscription.grid.filters.state
                    options:
                        field: state
                        label: test
    templates:
        filter:
            subscription_state: "@SyliusMolliePlugin/admin/mollie_subscription/grid/filter/states.html.twig"
