How to create participant work item plugin for first save
Hi,
I am using CLM Version 5.0.1.
I want to create a participant plugin which will trigger only when work item will save first time.
Means I want to create a plugin which will trigger only when work item creates.
I tried using below code but it fails
if (data instanceof ISaveParameter) {
// Get state of auditable item
ISaveParameter saveParameter = (ISaveParameter) data;
IAuditable auditable = saveParameter.getOldState();
if(auditable==null)
{
// If everything is correct, the auditable is an WorkItem
if (auditable instanceof IWorkItem)
{
IWorkItem workItem = (IWorkItem) auditable;
//actual plugin code
}
}
}
Any code??
Any idea???
One answer
The needed code is presented and explained in the Extensions Workshop. See https://rsjazz.wordpress.com/2015/09/30/learning-to-fly-getting-started-with-the-rtc-java-apis/