Skip to content

Option to not archive dependent records #35

@aried3r

Description

@aried3r

Hey!

Would you be open to adding an option to not archive dependent records? We might have a specific use case in our app, but we also want to reduce complexity, for example, if A has_many Bs and A is archived, alls B's get archived. If I separately unarchive alls Bs, A does not get unarchived automatically.
Of course we can do that ourselves, but we'd rather save us all the trouble and just archive A and display that visually.

Maybe as an option to acts_as_archival, acts_as_archival archive_dependent: false.

Of course, this would be an all-or-nothing option, as in you wouldn't be able to configure that not all Bs should be archived, but A also has_many Cs, which you would want to archive.

If you agree to this option, I'd do the all-or-nothing option which is optional of course.
I found act_on_archivals but I don't think there's a way to override it?

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