How to prevent certain relationships from being copied?

Hi, when copying an Item, also the Relationships are duplicated. This is most of the time very useful (e.g. for BOM items), but sometimes I would prefer, if some Relationships wouldn´t be copied (e.g. Costs). What´s the best way to prevent certain Relationships from being copied? I have found these two options so far, but I am not sure what´s the best approach: Option 1: Use a custom onCopy Method, that dublicates the Item with the use of theclone method. The method clone contains a parameter that can be used to decide, whether Relationships shall be cloned or not. But I am not sure, if this parameter applies to all relationships of the source Item. Option 2: Create an onAfterCopy Method that removes the unwanted Relationships. But this somehow feels like hedge trimming with AML. It produces a nice result, but is pretty rough. Another option would be, to trigger an additional dialog where users can choose which Relationships to copy. But that's too much work for me right now and I do not need such a luxury solution. What would you recommend? Or is there some other option available that I haven´t discovered yet? Thanks for any feedback! Angela
Parents
  • Hi Chris, Thanks for your feedback! This is not an high-priority issue, but it's always good to know about the possibilities. I think for the moment I will solve the problem like a real PLM admin: "You released the Part and forgot to check the relationships? You are welcome to start a change process!". Problem solved. Angela
Reply
  • Hi Chris, Thanks for your feedback! This is not an high-priority issue, but it's always good to know about the possibilities. I think for the moment I will solve the problem like a real PLM admin: "You released the Part and forgot to check the relationships? You are welcome to start a change process!". Problem solved. Angela
Children
No Data