mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-12 09:17:50 -06:00
Fix serialize hotend id in xml material.
Contributes to issue CURA-4243.
This commit is contained in:
parent
4245847dab
commit
a387c10686
1 changed files with 3 additions and 2 deletions
|
@ -238,7 +238,8 @@ class XmlMaterialProfile(InstanceContainer):
|
|||
if not variant_containers:
|
||||
continue
|
||||
|
||||
builder.start("hotend", {"id": variant_containers[0]["id"]})
|
||||
# The hotend identifier is not the containers name, but its "name".
|
||||
builder.start("hotend", {"id": variant_containers[0]["name"]})
|
||||
|
||||
# Compatible is a special case, as it's added as a meta data entry (instead of an instance).
|
||||
compatible = hotend.getMetaDataEntry("compatible")
|
||||
|
@ -897,4 +898,4 @@ def _fillMissingVariants():
|
|||
Logger.log("w", "Could not find variant for variant-specific material {material_id}.".format(material_id = variant_metadata["id"]))
|
||||
continue
|
||||
variant_metadata["variant"] = variants[0]["id"]
|
||||
ContainerRegistry.allMetadataLoaded.connect(_fillMissingVariants)
|
||||
ContainerRegistry.allMetadataLoaded.connect(_fillMissingVariants)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue