Skip to content

Commit 6c4fb09

Browse files
ENGCOM-4084: Add the ability to disable/remove an action from Mass(Tree)Action #20881
- Merge Pull Request #20881 from Itonomy/magento2:feature/DisableMassActionSetting - Merged commits: 1. f8e407d 2. eb4284f 3. 4461a29
2 parents c503449 + 4461a29 commit 6c4fb09

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

app/code/Magento/Ui/Component/MassAction.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
namespace Magento\Ui\Component;
77

88
/**
9+
* Mass action UI component.
10+
*
911
* @api
1012
* @since 100.0.2
1113
*/
@@ -21,12 +23,12 @@ public function prepare()
2123
$config = $this->getConfiguration();
2224

2325
foreach ($this->getChildComponents() as $actionComponent) {
24-
$actionComponentConfig = $actionComponent->getConfiguration();
25-
$disabledAction = $actionComponentConfig['actionDisable'] ?? false;
26+
$componentConfig = $actionComponent->getConfiguration();
27+
$disabledAction = $componentConfig['actionDisable'] ?? false;
2628
if ($disabledAction) {
2729
continue;
2830
}
29-
$config['actions'][] = $actionComponentConfig;
31+
$config['actions'][] = $componentConfig;
3032
}
3133

3234
$origConfig = $this->getConfiguration();

0 commit comments

Comments
 (0)