AngyL75
AngyL75
AEAsh Elixir
Created by AngyL75 on 5/25/2025 in #support
AshArchival
Dear team, I am currently trying to implement AshArchival. In order to be able to read the archived and none archived value. the documentation says I need to create a separate resource. Shall this separate resource have everything same as the original one, except it does not have the 'extensions: [AshArchival.Resource]' and instead have the
attributes do
attribute(:archived_at, :utc_datetime_usec, public?: true)
end
attributes do
attribute(:archived_at, :utc_datetime_usec, public?: true)
end
Should I also duplicate all the policies, calculation etc... too ? Regards, Angy.
14 replies
AEAsh Elixir
Created by AngyL75 on 5/20/2025 in #support
Slow pages ... due to too many load of data...
Hi Community, In a platform I am currently developing, some pages are slow. Too many load of data... I am wondering if there is a config option that permit to have in the log the files/component/lines that call the ash.load or Ash.get... which do the SQL access to the DB ? In order to analyze the issue quicker ?
8 replies
AEAsh Elixir
Created by AngyL75 on 5/11/2025 in #support
Ash Paper Trail, destroy action
I would like to know how to remove the versions of an object that I deleted. I have used a destroy action on a parent object. this parent object has a version system in place with the following configuration:
paper_trail do
primary_key_type :uuid
only_when_changed? true
change_tracking_mode :changes_only
store_action_name? true
store_action_inputs? true
ignore_attributes [:inserted_at, :updated_at]
reference_source? false
# for multitenancy
attributes_as_attributes [:organization_id]
belongs_to_actor :actor, CauseBeacon.Accounts.User, public?: false
end
paper_trail do
primary_key_type :uuid
only_when_changed? true
change_tracking_mode :changes_only
store_action_name? true
store_action_inputs? true
ignore_attributes [:inserted_at, :updated_at]
reference_source? false
# for multitenancy
attributes_as_attributes [:organization_id]
belongs_to_actor :actor, CauseBeacon.Accounts.User, public?: false
end
I would like to be able to delete all the related versions in the "paper-trail" table, related to the row/object that I want to destroy. when using reference_source? true, I fail to destroy my row. now it destroy my row, but I have new row in my version, every time I am destroying an object (since I do not have the
ignore_actions [:destroy]
ignore_actions [:destroy]
) Regards, Angy
6 replies