twenty
twenty copied to clipboard
Workspace sync metadata should compare fields and objects using unique identifier
Scope & Context
The current implementation of the sync compares objects and their fields in the DB with the standard object defined in the code. To do that and avoid any issue with the diff while maintaining the correct order, we map objects and fields with their names. However, because of that we can't easily rename them and the sync will interpret them as different entities.
Technical inputs
First improvement would be to introduce a new column: standardFieldId? The value will never change and will allow us to map standard fields with rows in DB even if they've been renamed.
cc @magrinj @charlesBochet
Same for SELECT options?
We have decided not to sync the SELECT options so it should not be useful!