cms
cms copied to clipboard
Copy field values from other sites
Continuation of #12436 but instead of handling the copy server-side, the controller will return fragments of HTML that we use to replace fields and immediately save a draft. This simplifies the logic a bit as we can rely on existing "Save Draft" processes to save the values.
Description
On the entry/category edit page (elements that support autosaving drafts):
- Added an item to the action menu that allows you to copy all, translatable, changed values from another site
- translatable field icon now triggers a HUD, which contains a form that allows you to copy just that field’s value from the selected site; copy action is applied to the top-level fields (e.g. entire matrix field)
- plugins need to implement CopyableFieldInterface to use this feature
IMPORTANT: once this feature is released, an update to craftcms/html-field needs to be released; https://github.com/craftcms/html-field/pull/6
https://github.com/craftcms/cms/assets/1843073/e7278397-aa1b-4fdb-bc9a-0694b8a865e0
I think this was "missing piece" of multi-language functionality of Craft CMS. Thanks for adding this.
I think this was "missing piece" of multi-language functionality
I concur; really looking forward to seeing it merged. Any chance it'll make it into 5.2? 😇