Repository Model structure, with diff detection and diff-only save #3

Open
opened 2024-10-16 14:15:33 +02:00 by Madeorsk · 0 comments
Owner

To ease the use of models, it would be interesting to have a Model structure which holds the model and its known state in database. This would allow us to use a simple .save() on a model to save it, no matter its existence, and it would only save what has been changed.
This may be done by implementing a special field in the model structure (so it would be opt-in) with some metadata about the model (e.g. its known database value, if it exists).

To ease the use of models, it would be interesting to have a Model structure which holds the model and its known state in database. This would allow us to use a simple `.save()` on a model to save it, no matter its existence, and it would only save what has been changed. This may be done by implementing a special field in the model structure (so it would be opt-in) with some metadata about the model (e.g. its known database value, if it exists).
Madeorsk added the
Priority
Low
Kind/Feature
labels 2024-10-16 14:15:33 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: zedd/zrm#3
No description provided.