CA Service Management

Expand all | Collapse all

CR Property Value As Site-Defined Condition

Jump to Best Answer
  • 1.  CR Property Value As Site-Defined Condition

    Posted 06-28-2018 04:47 PM

    Is it possible to make the Property Value an object that can be called in a Site-Defined Condition. For example: we have our environments (Dev, Test, QA, Prod) and I want a site-defined condition specified if it is Prod to be True, else False. 



  • 2.  Re: CR Property Value As Site-Defined Condition

    Posted 06-29-2018 01:04 AM

    Hi,

    this is possible but you need to complete your condition with a bit of selfwritten spel code, example could be found here: Classic Workflow Control Based on Property Value Selction 

    this example is based on label but my suggestion is to create and use owning rule instead.

    Regards,

    Timur



  • 3.  Re: CR Property Value As Site-Defined Condition

    Posted 06-29-2018 08:22 AM

    Thank you very much. I looked at the example but I am uncertain with the owning rule part of the response. May I get a quick example of what the owning rule would be in the code? 



  • 4.  Re: CR Property Value As Site-Defined Condition
    Best Answer

    Posted 06-29-2018 09:07 AM

    There are few type of properties: dropdown, checkbox, plain text (string).

    First 2 types are defined by validation rule which persists as constant id in property table when property label can be changed for some reason and you'll need to modify all related scripts/conditions. So query like:

    label = 'Server Type' AND owning_cr = 'cr:123456' AND value = 'DEV'

    will work but this one would be better:

    validation_rule = 123456 AND owning_cr = 'cr:123456' AND value = 'DEV'


  • 5.  Re: CR Property Value As Site-Defined Condition

    Posted 06-29-2018 09:58 AM

    Thank you!