Skip to content

Commit

Permalink
add project_name as part of the container data
Browse files Browse the repository at this point in the history
  • Loading branch information
moonyuet committed Nov 28, 2024
1 parent f2f0bac commit b21142c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions client/ayon_substancepainter/api/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,7 @@ def imprint_container(container,
("namespace", str(namespace) if namespace else None),
("loader", str(loader.__class__.__name__)),
("representation", context["representation"]["id"]),
("project_name", context["project"]["name"]),
]
for key, value in data:
container[key] = value
Expand Down
5 changes: 4 additions & 1 deletion client/ayon_substancepainter/plugins/load/load_mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,10 @@ def on_mesh_reload(status: substance_painter.project.ReloadMeshStatus):

# Update container representation
object_name = container["objectName"]
update_data = {"representation": repre_entity["id"]}
update_data = {
"representation": repre_entity["id"],
"project_name": context["project"]["name"]
}
set_container_metadata(object_name, update_data, update=True)

def remove(self, container):
Expand Down

0 comments on commit b21142c

Please sign in to comment.