Skip to main content
18-Opal
November 20, 2017
Question

about Customized Approve Promotion

  • November 20, 2017
  • 0 replies
  • 1326 views

Hi i'm SeonHo

 

I wonder how to configure for the promotion workflow.
I am using the "Designing - Review - Released - Design Change" lifecycle.
You can promote to the Released state through a Promotion request.


It seems to modify the state of the object associated with promotions via conditional routing and Unlock Target in the promotion workflow.


Lifecycle lockout is used to convert to a "Review" state during a promotion request.
Accepted will be converted to Released.
It is converted to its original state through rejection.


Using rework in a routing expression uses the following expression

wt.maturity.PromotionNotice pn = (wt.maturity.PromotionNotice) primaryBusinessObject;
try
{
        wt.maturity.MaturityServerHelper.service.lockTargets (pn);
}
catch (Exception wte)
{
      wte.printStackTrace ();
}


When you use Reject in a routing expression, you use the following expression

wt.maturity.PromotionNotice pn = (wt.maturity.PromotionNotice) primaryBusinessObject;
try
{
wt.util.WTProperties props = wt.util.WTProperties.getLocalProperties ();
VERBOSE = props.getProperty ("wt.maturity.verbose", VERBOSE);
}
catch (Throwable t)
{
 
}
try {
     wt.maturity.MaturityServerHelper.service.unlockTargets (pn);
} catch (wt.maturity.MaturityException me) {
       if (VERBOSE)
         me.printStackTrace ();
}

I want to modify the code to set the state of the associated object to 'design change' by selecting routing named rework or selecting routing named reject

 

However, I have not been able to figure out what expressions are used in windchill or what each variable means.
Please. How do I configure it to get the results I want?


Thank you.