- Issue created by @Anybody
- 🇩🇪Germany Anybody Porta Westfalica
From https://www.drupal.org/project/field_tools/issues/1349646#comment-14945075: ✨ Move fields from one entity to another Closed: won't fix
> It's quite dangerous, if someone clones a field across entity types currently, isn't it?
I suggest only showing current entities fields, until this is properly implementedIt should be fine, but you have to:
a. check the field name isn't already used on the destination entity type
b. clone the field storage as well as the instances - 🇩🇪Germany Anybody Porta Westfalica
Note to myself: Before starting here, check what exactly happens currently (
cex --diff
) when cloning to a different entity bundle! - 🇬🇧United Kingdom joachim
Can you check the module first to see how much of this is already done?
The comments and code in FieldCloner make it look like this is already handled in part:
* @param string $destination_entity_type_id * The entity type to clone the field to. If this is different from the * source field, then one of the following will happen: * - a) a new field storage is created * - b) an existing field storage is used, if its type matches the source * field. * - c) an exception is thrown if the existing type does not match.
- Status changed to Closed: cannot reproduce
10 months ago 3:57pm 28 May 2024 - 🇩🇪Germany Anybody Porta Westfalica
Thanks @joachim indeed I can not reproduces the issues anymore. I think it was fixed in the meantime. Works great, even X entity type! :)