Closed skid closed 8 months ago
Hi @michaelbromley,
I want to sync product data to another system and it would make it easier if i could check if the products is updated since the last sync.
Do you have any idea about how to solve this issue or ay idea about how to make a workaround for this issue? If you have a if you have a rough idea of how to solve it, maybe we can help.
Thanks in advance
/Tim
Hi,
I think a solution would involve modifying the TranslatableSaver.update() method so that it manually sets the updatedAt
field on the translation's parent entity and persists that to the DB.
A work-around that you could use for now though would be to define a custom field on the product which stores the last update time, and use the EventBus to subscribe to changes with the ProductEvent
and use that to update your custom field.
/bounty $30
/attempt #1464
with your implementation plan/claim #1464
in the PR body to claim the bountyThank you for contributing to vendure-ecommerce/vendure!
Add a bounty • Share on socials
Attempt | Started (GMT+0) | Solution |
---|---|---|
🟢 @furo321 | #2630 |
💡 @furo321 submitted a pull request that claims the bounty. You can visit your bounty board to reward.
The
updatedAt
column of translatable entities (e.g. Product) does not change when their translations are updated - only the translation'supdatedAt
column does. The intuitive expectation would be: When I change a product's name, itsupdatedAt
timestamp should change too.