Improve update function
Open
enhancement
- Dominant language
- Elixir
- Stars
- 15
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Currently we've had to override the update function for a few of our modules in CS, because we need to add in the `many_to_many` or `one_to_many` associations.
It should be possible to abstract this out into this module, by using
`__MODULE__.__schema__(:associations)` to get all of the associations, then map through that with `__MODULE__.__schema__(:association, assoc)` to get detailed information on each association, including whether it's a `many_to_many`, `one_to_many` etc, then comparing it with the updated attributes and dealing with any updated associations in the appropriate way.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.