easy_admin:
    entities:
        Article:
            class: App\ArticleBundle\Entity\Article
            controller: App\ArticleBundle\Controller\Backend\ArticlesAdminController
            list:
                title: 'entity.article.title.list'
                fields:
                    - { property: id, label: common.id }
                    - { property: title, label: common.title }
                    - { property: image, label: common.image, type: image, base_path: "%app.path.articles_images%" }
                    - property: categories
                      label: entity.article_category.name.multiple_simple
                      template: ArticleBundle:backend:article_categories.html.twig
                    - property: sections
                      label: entity.section.name.multiple
                      template: AppSectionsBundle:backend:sections_names.html.twig
                    - property: updateDate
                      label: common.update_date
                    - property: createdDate
                      label: common.creation_date
                    - property: isPublished
                      label: common.whether_published
                actions:
                    - { name: 'new', icon: 'plus' }
                    - { name: 'article', icon: 'eye', type: 'route', label: common.preview }
                    - { name: 'edit', icon: 'pencil' }
                    - { name: 'delete', icon: 'trash' }
            show:
                fields:
                    - { property: 'image', type: 'image', base_path: "%app.path.articles_images%" }
            form:
                fields:
                    - type: group
                      css_class: col-md-12
                      label: common.main_content
                      icon: paint-brush


                    - property: locales
                      type: collection
                      type_options:
                          label: false
                          entry_type: App\ArticleBundle\Form\Type\ArticleLocaleType
                          error_bubbling: false
                          by_reference: false

                    - property: categories
                      label: entity.article_category.name.multiple_simple
                      type: App\ArticleBundle\Form\Type\ArticleCategorySelectType
                      type_options:
                        class: App\ArticleBundle\Entity\ArticleCategory
                        required: true

                    - property: isPublished
                      label: common.whether_published
                    - property: imageFile
                      type: Vich\UploaderBundle\Form\Type\VichImageType
                      label: common.image

                    - type: group
                      css_class: col-md-12
                      label: entity.article.form.label.related

                    - property: relatedArticles
                      label: false
                      type: collection
                      type_options:
                          label: false
                          entry_type: App\ArticleBundle\Form\Type\ArticlesType
                          error_bubbling: false
                          by_reference: false

                    - type: group
                      css_class: col-md-12
                      label: common.attachments
                      icon: files-o


                    - property: articleFiles
                      type: collection
                      type_options:
                          label: false
                          entry_type: App\ArticleBundle\Form\Type\ArticleAttachmentsType
                          by_reference: false
                          error_bubbling: false
            new:
                title: entity.article.title.add
            edit:
                title: entity.article.title.edit
        ArticleCategory:
            class: App\ArticleBundle\Entity\ArticleCategory
            controller: App\ArticleBundle\Controller\Backend\ArticlesCategoriesAdminController
            list_type: tree
            list:
                title: entity.article_category.title.list
                fields:
                    - { property: id, label: common.id }
                    - { property: title, label: common.name }
            show:
                title: entity.article_category.title.profile
                fields:
                    - { property: id, label: common.id }
                    - { property: title, label: common.name }
            form:
                fields:
                    - type: group
                      css_class: col-md-7
                      label: common.main_content
                      icon: paint-brush


                    - property: locales
                      type: collection
                      type_options:
                          label: false
                          entry_type: App\ArticleBundle\Form\Type\ArticleCategoryLocaleType
                          error_bubbling: false
                          by_reference: false

                    - type: group
                      css_class: col-sm-5
                      label: entity.menu_item.form.group.tree
                      icon: cogs


                    - property: parent
                      label: common.parent_element
                      type: App\ArticleBundle\Form\Type\ArticleCategorySelectType
                      type_options:
                        required: true
                        class: App\ArticleBundle\Entity\ArticleCategory

                    - property: weight
                      label: common.weight
                      help: common.weight.help


            new:
                title: entity.article_category.title.add
            edit:
                title: entity.article_category.title.edit