feat: Extend snapshots to include custom fields and tags #57
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Extend the content snapshot engine to capture additional related tables:
#__fields(where context = 'com_content.article') — custom field definitions#__fields_values— custom field values for articles#__fields_categories— field-to-category mappings#__tags— tag definitions (currently only tag mappings are captured)#__ucm_content— unified content metadataWhy
Sites using Joomla custom fields lose field data when restoring article snapshots. The current snapshot captures tag mappings but not the tag definitions themselves, so restored tag mappings may point to non-existent tags.
Files
src/Engine/SnapshotEngine.php— add tables to TYPE_TABLES/ARTICLE_RELATEDsrc/Engine/SnapshotRestoreEngine.php— add PRIMARY_KEYS and truncate filters