Skip to content

feat: support atomic bulk actions #52

@frankdugan3

Description

@frankdugan3

Is your feature request related to a problem? Please describe.

I have a number of bulk actions that require auditing and atomic actions w/ rollback. For example, a packing list form which updates the ownership of a number of scanned items.

The trouble is that AshPaperTrail currently interferes with atomicity. :full_diff tracking mode may not be possible currently, but :changes_only should be possible to support atomically.

Describe the solution you'd like

The change for create_new_version should be refactored for support of bulk/atomic operations where possible. Currently, this would probably exclude :full_diff tracking mode, supporting only :snapshot and :changes_only.

Describe alternatives you've considered

  • Mixins aren't capable of adding this as an escape hatch.
  • Currently using a custom changeset to store changes in a []json column, which is pretty hacky.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions