新增子单据体行以及赋值的方法

新增子单据行要用
CreateNewEntryRow(DynamicObject parentRow, SubEntryEntity entity, int row)
这个重载方法,例如
  1.   //获取单据体元数据
  2.             EntryEntity entry = this.View.BillBusinessInfo.GetEntryEntity("FEntry");
  3.             //获取指定一行的单据体数据
  4.             DynamicObject entity_obj = this.Model.GetEntityDataObject(entry,0);
  5.             //获取子单据体元数据
  6.             SubEntryEntity sub_entry = this.View.BillBusinessInfo.GetEntryEntity("FSubEntry") as SubEntryEntity;
  7.             //创建新的子单据体分录行
  8.             this.Model.CreateNewEntryRow(entity_obj, sub_entry, 0);
复制代码


子单据体行赋值用this.View.Model.SetValue(field,value, rowNo),给当前单据体行对应的子单据体赋值
posted @ 2020-06-04 11:42  木古白水  阅读(489)  评论(0编辑  收藏  举报