Skip to content

Commit 96f98bb

Browse files
authored
Merge pull request #2050 from soniiix/patch-1
Fix ActionColumn example to use RowActionCollection
2 parents 0124d17 + c55626a commit 96f98bb

File tree

1 file changed

+2
-2
lines changed
  • development/components/grid/columns-reference

1 file changed

+2
-2
lines changed

development/components/grid/columns-reference/action.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@ For more info about possible actions see [Actions reference][actions-reference].
2222
use PrestaShop\PrestaShop\Core\Grid\Column\Type\Common\ActionColumn;
2323
use PrestaShop\PrestaShop\Core\Grid\Column\ColumnCollection;
2424
use PrestaShop\PrestaShop\Core\Grid\Action\Row\Type\LinkRowAction;
25+
use PrestaShop\PrestaShop\Core\Grid\Action\Row\RowActionCollection;
2526

2627
$actionColumn = new ActionColumn('actions');
2728
$actionColumn->setName('Actions');
2829
$actionColumn->setOptions([
29-
'actions' => [
30+
'actions' => (new RowActionCollection())
3031
->add((new LinkRowAction('delete'))
3132
->setIcon('delete')
3233
->setOptions([
@@ -36,7 +37,6 @@ $actionColumn->setOptions([
3637
'confirm_message' => 'Delete selected item?',
3738
])
3839
)
39-
],
4040
]);
4141

4242
$columns = new ColumnCollection();

0 commit comments

Comments
 (0)