Important

You are browsing the documentation for version 4.1 of OroCommerce, OroCRM and OroPlatform, which is no longer maintained. Read version 5.1 (the latest LTS version) of the Oro documentation to get up-to-date information.

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

Mass Action Configuration

Using the themeOptions parameters in the bundle layout.yml file, you can customize and tune the way individual mass actions and the mass actions group are shown in the UI, when the items delivered by the bundle are shown in the grid view.

Sample configuration in the layout.yml file(s) in the Resources/views/layouts/theme/page/folder in the bundle (e.g., OrderBundle):

 1 layout:
 2     actions:
 3         - '@setOption':
 4             id: test_datagrid_id
 5             optionName: grid_render_parameters
 6             optionValue:
 7                 themeOptions:
 8                     cellActionsHideCount: 3
 9                     cellLauncherOptions:
10                         launcherMode: 'icon-only' # 'icon-only' | 'icon-text' | 'text-only'
11                         actionsState:  'hide'     # 'hide' | 'show'

Controlling Actions List View

The cellActionsHideCount and cellLauncherOptions > actionsState parameters control the way mass actions collapse into the show more group () and will be displayd on hover over the .

When not collapsed, the actions show inline with the item: ‘three dots’ menu is hidden.

To collapse all actions into the show more group (), set actionsState to hide. In this case, the actionsHideCount value is ignored.

Hint

You get similar outcome with the options actionsState: show and actionsHideCount: 0

A user sees only the ‘three dots’ menu.

To keep all actions expanded, set actionsState to show and actionsHideCount to a reasonably large value (up to the max number of the actions you expect to get).

A user sees all line items.

To optimize the space organization, keep most used actions expanded and hide the less frequent ones. To do so, set actionsHideCount to the average number of the frequently used actions (e.g., 3).

Hint

Some line items are inline, other are hidden.

A user sees only some line items and the ‘three dots’ menu.

Controlling the Action View

Based on the launcherMode value, the individual mass actions can be displayed in one of the following modes.

Label and Icon

launcherMode: icon-text

<a class="action" href="#action_url">
    <i class="fa-<%= icon %>"></i>
    <%= label %>
</a>

Icon Only

launcherMode: icon-only

<a class="action" href="#action_url">
    <i class="fa-<%= icon %>"></i>
</a>

Label Only

launcherMode: text-only

<a class="action" href="#action_url">
    <%= label %>
</a>