Model.hm_ae_get_partson#
- Model.hm_ae_get_partson(attatchments)#
Returns the part for given attachments.
- Parameters:
attatchments (Collection) – The collection containing the attachment entities to retun the part IDs.
- Returns:
hwReturnStatus- Status objectHmQueryResult- Result object containing the output values:parts (EntityList) - Entity Type:
Part
Example#
Get the parts for all attachments#import hm import hm.entities as ent model = hm.Model() attachment_collection = hm.Collection(model, ent.Attachment) _, result = model.hm_ae_get_partson(attatchments=attachment_collection) print("Parts:", [p.id for p in result.parts])