Learn about Redwood and be one of the first to join the conversation

Visit Redwood Community
Need help on groovy script — Cloud Customer Connect
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Need help on groovy script

Received Response
25
Views
8
Comments
edited Dec 10, 2020 6:56PM in Order Management 8 comments

Content

Hi,

 I am trying to avoid users from creating a SO when selecting a specific Order Type. I tried the below groovy script but facing errors. Can anyone please help 

 

import oracle.apps.scm.doo.common.extensions.ValidationException;
import oracle.apps.scm.doo.common.extensions.Message;
String CustomerOrderType = header.getAttribute("TransactionTypeCode");
if( customerOrderType == null ) return;
if(CustomerOrderType=="SVC ADV. EXCHANGE")  {
    throw new ValidationException(new Message(Message.MessageType.WARNING, " !!!"));}
return;

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!