You can allow batch actions to be performed on selected rows in selectable datagrids. You can make the action
choices contextual to the selection by showing certain actions only if the selection meets the criteria.
Add a clr-dg-action-bar
inside a clr-datagrid
.
The content inside of it will be projected when one or more items is selected. We recommend that that you use
a button bar with small buttons as in the example.
In the following example, we simply display the names of the selected users, but since we have access to the full objects, we could perform any operation we want on them.
Depending on the role of certain batch actions, you can choose to break button bars up into separate button groups. To increase the visibility of the most important batch actions within each button group, we recommend organizing batch actions in priority order from left to right.
Users to be added to group: No user selected. {{user.name}}
User to be edited: No user selected. {{toEdit.name}}
Users to be deleted: No user selected. {{user.name}}
Users to be exported: No user selected. {{user.name}}