Important

You are browsing documentation for version 5.1 of OroCommerce, supported until March 2026. Read the documentation for version 6.0 (the latest LTS version) to get up-to-date information.

See our Release Process documentation for more information on the currently supported and upcoming releases.

Grid Views Extension 

Configure All Grid View Label 

All Grid View Label is set in Oro\Bundle\DataGridBundle\EventListener\DefaultGridViewLoadListener and in orodatagrid/js/datagrid/grid-views/view.

There are two ways to set a label for All grid view:

  • Via an option in datagrid config:

# ...
options:
    gridViews:
        allLabel: acme.bundle.translation_key # Translation key for All label
  • Via a pre-defined translation key for the entity used in the datagrid datasource. The translation key uses the following pattern: [vendor].[bundle].[entity].entity_grid_all_view_label, e.g. for Oro\Bundle\TranslationBundle\Entity\Language - oro.translation.language.entity_grid_all_view_label.

If bundle name equals entity name, then entity name is skipped, e.g. for Oro\Bundle\TranslationBundle\Entity\Translation - oro.translation.entity_grid_all_view_label.

Suppose the allLabel option is not specified, and the translation key is not translated. In that case, the label for All grid view is created by concatenating the oro.datagrid.gridView.all translation key and the entity name in the plural form, e.g., for the Contact entity in the English language, it is “All Contacts”.

Related Articles