Skip to content

Crud bug on dynamically disabled rows #2212

@mkrecek234

Description

@mkrecek234

Crud's ActionsButtons can be set either statically disabled or enabled, or dynamically a) via a passed function via $isDisabled parameter or b) via a dynamically set UserAction->enabled = function ($row) ....

There is however a logical error in

$this->isEnabledFxs[$name] = $isDisabled;

as $this->isEnabledFxs[$name] = $isDisabled; This has to be the negation - or we call $isDisabled better $isEnabled an change references. I am in favor of this, as Atk4\Model always refers to "enabled" and not "disabled".
Let me know, then we can change all $isDisabled to $isEnabled in Atk4\Ui together.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions