3、NC系统接口集(持续更新)

**

3、 NC系统接口集(持续更新)

**
1、自定义参照查询接口

IDefdocQryService defdocqry = NCLocator.getInstance().lookup(IDefdocQryService.class);
//查询方法

DefdocVO[] prodareaVOs = defdocqry.queryDefdocByPk(new String[]{materialVOs[0].getProdarea()});

2、 修改保存单据(包括审批流和非审批流)

IplatFormEntry iIplatFormEntry =(IplatFormEntry)NCLocator.getInstance().lookup(IplatFormEntry.class.getName());
用法1
//修改保存检验单
HashMap map = new HashMap();
map.put(“notechecked”, “notechecked”);
IplatFormEntry iIplatFormEntry = (IplatFormEntry)NCLocator.getInstance().lookup(IplatFormEntry.class.getName());
CheckBillVO[] checkBillVOs = (CheckBillVO[]) iIplatFormEntry.processAction(“SAVEBASE”, QCBillType.CheckBill.getCode(), null, billVO, null, map);
//修改保存后返回VO没有交易类型和制单人
if(PfServiceScmUtil.isExistWorkflowDefinition(billVOs[0].getParentVO().getVtrantypecode(), billVOs[0].getParentVO().getPk_org(), billVOs[0].getParentVO().getBillmaker(), WorkflowTypeEnum.Approveflow.getIntValue())){
//有审批流true,推提交态
WorkflownoteVO worknoteVO = ((IWorkflowMachine)NCLocator.getInstance().lookup(IWorkflowMachine.class)).checkWorkFlow(“SAVE”, QCBillType.CheckBill.getCode(), checkBillVOs[0], map);
iIplatFormEntry.processAction(“SAVE”, QCBillType.CheckBill.getCode(), worknoteVO, checkBillVOs[0], null, map);
}else{//无审批流false,推审批态
//审批检验单
MsgcenterUtil pushApproveUtil = new MsgcenterUtil();
pushApproveUtil.approveBill(QCBillType.CheckBill.getCode(), pk_checkbill, “Y”,"");
}
用法2 iPFBusiAction
IPFBusiAction iPFBusiAction = NCLocator.getInstance().lookup(IPFBusiAction.class);
iPFBusiAction.processAction(“SAVEBASE”, “FJDS”, null, reAggVo, null, null);

3、人员数据更新接口
IPsndocService ips = NCLocator.getInstance().lookup(IPsndocService.class);
用法
// 存储加密密文
人员VO
psndocvO.setAttributeValue(“glbdef45”,encodestr);
ips.updatePsndoc(psndocvO);
4、通用查询接口(查询单个字段)
IUifService service = NCLocator.getInstance().lookup(IUifService.class);
String mobile = (String) service.findColValue(“bd_psndoc”, “mobile”, " pk_psndoc=’" + psn + "’ ");

你可能感兴趣的:(NC,NC,NC接口,NC65接口,NC63接口)