付款申请单银行账号字段,携带到付款单明细页签原创
2人赞赏了该文章
277次浏览
编辑于2023年05月15日 12:26:20
先再付款单上加基础资料字段,标识为F_QMFM_yhzh,然后再转换规则里注册插件,字段一直可直接复制一下语句!
clr.AddReference("Kingdee.BOS.DataEntity")
from Kingdee.BOS.DataEntity import *
from Kingdee.BOS.Core.Metadata.FieldElement import *
from Kingdee.BOS.Core.Metadata.FieldElement import *
def AfterConvert(e):
headEntity = e.Result.FindByEntityKey("FBillHead")
for item in headEntity:
data=item["PAYBILLENTRY"]
src=item["PAYBILLSRCENTRY"]
if len(data)!=len(src):
continue
for index in range(len(data)):
data[index]["FACCOUNTID_ID"]=src[index]["F_QMFM_yhzh_SRC_ID"]
data[index]["FACCOUNTID"]=src[index]["F_QMFM_yhzh_SRC"]
headEntity = e.Result.FindByEntityKey("FBillHead")
for item in headEntity:
data=item["PAYBILLENTRY"]
src=item["PAYBILLSRCENTRY"]
if len(data)!=len(src):
continue
for index in range(len(data)):
data[index]["FACCOUNTID_ID"]=src[index]["F_QMFM_yhzh_SRC_ID"]
data[index]["FACCOUNTID"]=src[index]["F_QMFM_yhzh_SRC"]
推荐阅读