on 01-27-2011 3:28 PM
Hello all,
I am writing an Activity Hook that checks for the time difference from the last completed operation to the start of a new operation to see if it is over a certain number of hours.
If the time difference is large, the Activity Hook should log an NC and send it to a rework router.
I can do all of it except the last part of sending it to the dispositioned rework router.
It works fine from the NC Client GUI, I just can't figure out the correct EJB and method to call.
Here is the code I have so far:
Data ncData = new Data();
ncData.put("SITE", site);
ncData.put("RESOURCE_BO", resourceBO);
ncData.put("OPERATION_BO", operationBO);
ncData.put("SFC_BO", sfcBO);
ncData.put("ACTIVITY", "NC500");
ncData.put("OWNER_GBO", userBO);
ncData.put("NC_CONTEXT_GBO", "SFCBO:"+site+","+sfc);
ncData.put("NC_CODE_BO", "NCCodeBO:"+site+","+NC_CODE);
ncData.put("COMMENTS", "Time limit of ["+hrsDiff+"] exceeded "+
"recommended value of ["+HOURS_TIME_LIMIT+"].");
try
{
// log the NC
com.genrad.app.nc.server.NCDataBOInterface ncDataEJB =
(com.genrad.app.nc.server.NCDataBOInterface)
com.genrad.frame.ServiceLocator.getEJB("NCDataBO");
Data ncDataResults = ncDataEJB.log(ncData);
// what is the code to run the disposition on the just logged NC?
}
catch(NamingException ne) {}
Thanks,
Mike
Hi all,
I went another way to get this working.
Thanks,
Mike Jewson
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
91 | |
10 | |
10 | |
6 | |
5 | |
5 | |
5 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.