动态(DEP)创建的单据如何使用实体的方法

栏目:eas cloud知识作者:金蝶来源:金蝶云社区发布:2024-09-22浏览:2

动态(DEP)创建的单据如何使用实体的方法

动态创建的单据对象,没有具体的java代码,在环境中也没有class对象。那么如何在代码中引用到这些对象呢?

动态创建的模板类可以在客户端-动态扩展模板上可以查询到:

单据:com.kingdee.eas.ep.CoreBillBaseCustom

单据分录:com.kingdee.eas.ep.CoreBillBaseCustomEntry

基础资料:com.kingdee.eas.ep.DataBaseCustom

新建单据分录对象(伪代码)

CoreBillBaseCustomEntryInfo info = new CoreBillBaseCustomEntryInfo();
Info.setBosType(new BOSObjectType("ABCDEFGH"));
Info.put("number", "123");
Info.put("name", "新分录1");
CoreBillBaseCustomEntryCollection newEnties = new CoreBillBaseCustomEntryCollection();
newEnties.add(info);
// 把分录赋给单据
orderInfo.put("newEnties", newEnties);


*** 注意,bosType可以在实体元数据中查看


调用实体方法,以提交为例(伪代码)

Context ctx = WafContext.getInstance().getContext();
CoreBillBaseCustom custom = new CoreBillBaseCustom(ctx);
custom.setType(BOSObjectType.create("F9CF6716"));
CoreBillBaseCustomInfo customInfo=custom.getCoreBillBaseCustomInfo(new ObjectStringPK(cardls[i]));
custom.submit(customInfo);

动态(DEP)创建的单据如何使用实体的方法

动态创建的单据对象,没有具体的java代码,在环境中也没有class对象。那么如何在代码中引用到这些对象呢?动态创建的模板类可以在客户端-动...
点击下载文档
确认删除?
回到顶部
客服QQ
  • 客服QQ点击这里给我发消息