Skip to content

Set non displayed property to null #3

Open
@mpiot

Description

@mpiot

When the dependent field is not displayed, but is previously set, it should be nice to set it to null or a default value we want.
I don't really know if this can be implemented rirectly, or maybe, mentioned in the documentation to remind people implement it.

Eg:

public function setMeal(Meal $meal): static {
    $this->meal = $meal;

    if ('breakfast' !== $meal) {
        $this->rating = null;
    }

   return $this;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions