easy_admin:
    entities:
       # List the entity class name you want to manage
        Gallery:
            class: App\Entity\Gallery
            controller: App\Controller\GalleryController
            help: 'Create your galleries and attach them to your pages, articles and properties'
            list:
                title: '%menu.list.label.galleries%'
                actions: [ '-show', 'edit', 'delete' ]
                batch_actions: [{ name: 'delete', ask_confirm: true }]
                fields:
                    - { property: 'ID' }
                    - { property: 'name' }
                    - { property: 'imageGalleries', label: '%label.image_galleries%', template: 'components/gallery_access.html.twig' }
                    - { property: 'dateCreated' }
            form:
                fields:
                    - { type: 'group', label: '%group.label.select_images%', columns: 8 }
                    -  property: 'images'
                       type: 'easyadmin_autocomplete'
                       type_options:
                            by_reference: false 
                            attr: { class: '_select2_custom' }
                    # - { property: 'imageGalleries', label: '', type: embedded_list, type_options: { entity: ImageGallery, ext_filters: { 'entity.gallery': 'form:parent.data.id' } } }
                    - { property: 'name', label: '%group.label.gallery.name%' }
                    - { property: 'width', columns: 6 }
                    - { property: 'height', columns: 6 }
                    # - { property: 'regenerateFormat', type_options: { data: false } }

                    - { type: 'group', label: '%group.label.basic.document%', columns: 4 }
                    - { property: 'userCreated', type: 'text', type_options: { disabled: true } }
                    - { property: 'userLastModified', type: 'text', type_options: { disabled: true } }
                    # -   property: 'images'
                    #     type: 'easyadmin_autocomplete'
                    #     type_options:
                    #         class: 'App\Entity\MediaObject'

                    # -  property: 'images'
                    #    # type: choice
                    #    type_options:
                    #        expanded: false
                    #        multiple: true

                    # -   property: 'images'
                    #     label: ' '
                    #     type: 'collection'
                    #     type_options:
                    #         entry_type: 'App\Form\DocumentType'
                    #         by_reference: false
                            # attr: { class: 'collection_item', label_item: 'item' }
            show:
                fields:
                    - { property: 'name' }
                    - { property: 'slug' }
                    - { property: 'id' }
                    - { property: 'imageGalleries', label: '', type: embedded_list }
                    - { property: 'dateCreated' }
                    - { property: 'dateModified' }
                    - { property: 'userCreated' }
                    - { property: 'userLastModified' }