The modelSaved method is not called reliable, i.e. as for the alias generation (see comments 1-3 at MetaModels/contao-frontend-editing#6).
We can
a) deprecate the modelSaved() and switch to the pre-persist event of the DCG. Problem: The event has no knowledge of its prior value, and an alias value might be overwritten even if already present in the database.
b) pass the up-to-date data to the modelSaved(). Problem: more time costs at runtime
(@discordier feel free to edit this post)
The
modelSavedmethod is not called reliable, i.e. as for the alias generation (see comments 1-3 at MetaModels/contao-frontend-editing#6).We can
a) deprecate the
modelSaved()and switch to the pre-persist event of the DCG. Problem: The event has no knowledge of its prior value, and an alias value might be overwritten even if already present in the database.b) pass the up-to-date data to the
modelSaved(). Problem: more time costs at runtime(@discordier feel free to edit this post)