Quantcast
Channel: PTC Community : Popular Discussions - Integrity
Viewing all articles
Browse latest Browse all 3432

[IM] Is it possible to prevent a relationship by a trigger?

$
0
0

Hi @all,

 

in our changemanagement-datamodel we have an itemtype, which can have three different specifications depending on one field. As example: The item is a release-item, and a field "element" can switch the specification of the release-item between "module", "library" and "package". The item holds a relationship-field, and by this field we can build some kind of hierarchy: A Library can contain some packages and also some modules, but not another library. Its alway the head of this hierarchy. A package can contain other packages and also modules, and modules shouldnt contain any other item, because they are the smallest artefact in this hierarchy. The relationship-field can be configured to allow only specific item-types, but it cannot distinguish between the different specifications of the same item-type.

 

So i want to do something like this: If a user tries to connect two items over this relationship-field, a trigger should look at both item-types and the "element"-field and decide if its an allowed connection or not. If it isnt allowed, the trigger should show the user a message and prevent the connection. Is this possible? Maybe some kind of abort-function?

 

Thanks, Jens

 

              

                 


Viewing all articles
Browse latest Browse all 3432

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>