凭证生成(保存、提交、审核)接口调用实例原创
10人赞赏了该文章
4,098次浏览
编辑于2022年10月25日 13:40:22
金蝶云星空V7.5.1450.1版本webAPI接口测试实例目录
说明:三方系统调用金蝶云星空 webAPI实现凭证生成(保存、提交、审核)
/**以下内容参考金蝶【C】webAPI接口文档说明整理形成,仅供交流参考。**/
1.保存接口测试:
(1)通过金蝶webAPI文档工具查看对应单据的文档信息,在线测试填写单据数据,拿返回实例json
*formid:可在金蝶webAPI文档工具中的代码示例中的client.Save中获取,如 GL_VOUCHER
POSTMAN测试实例:
*须在Headers 加入kdservice-sessionid 参数,值为登录接口是返回的kdservice-sessionid值
json格式:
{"formid":"GL_VOUCHER",
"data":{
"NeedUpDateFields": [],
"NeedReturnFields": [],
"IsDeleteEntry": "true",
"SubSystemId": "",
"IsVerifyBaseDataField": "false",
"IsEntryBatchFill": "true",
"ValidateFlag": "true",
"NumberSearch": "true",
"InterationFlags": "",
"IsAutoSubmitAndAudit": "false",
"Model": {
"FVOUCHERID": 0,
"FAccountBookID": {
"FNumber": "0010002"
},
"FDate": "2022-10-25 00:00:00",
"FBUSDATE": "2022-10-25 00:00:00",
"FVOUCHERGROUPID": {
"FNumber": "PRE001"
},
"FVOUCHERGROUPNO": "1",
"FISADJUSTVOUCHER": false,
"FDocumentStatus": "Z",
"FYEAR": 2022,
"FSourceBillKey": {
"FNumber": "78050206-2fa6-40e3-b7c8-bd608146fa38"
},
"FPERIOD": 10,
"FSOURCETYPE": "2",
"FEntity": [
{
"FEXPLANATION": "来源OA系统-编号:OA20221025010029",
"FACCOUNTID": {
"FNumber": "2202.01"
},
"FDetailID": {
"FDETAILID__FFLEX4": {
"FNumber": "SCM00004"
}
},
"FCURRENCYID": {
"FNumber": "PRE001"
},
"FEXCHANGERATETYPE": {
"FNumber": "HLTX01_SYS"
},
"FEXCHANGERATE": 1.0,
"FAMOUNTFOR": 2000.0,
"FDEBIT": 2000.0,
"FNOTE": "测试辅助账摘要信息:OA"
},
{
"FEXPLANATION": "来源OA系统-编号:OA20221025010029",
"FACCOUNTID": {
"FNumber": "1221.01"
},
"FDetailID": {
"FDETAILID__FFLEX7": {
"FNumber": "1092"
}
},
"FCURRENCYID": {
"FNumber": "PRE001"
},
"FEXCHANGERATETYPE": {
"FNumber": "HLTX01_SYS"
},
"FEXCHANGERATE": 1.0,
"FAMOUNTFOR": 2000.0,
"FCREDIT": 2000.0,
"FNOTE": "测试辅助账摘要信息:OA"
}
]
}
}
}
2.提交接口测试:
POSTMAN测试实例:
*须在Headers 加入kdservice-sessionid 参数,值为登录接口时返回的kdservice-sessionid值
*须根据保存接口返回的单据编号和内码id入参
json格式:
{"formid":"GL_VOUCHER",
"data":{
"CreateOrgId": "0",
"Numbers":"132202",
"Ids": "535009",
"SelectedPostId": "0"
}}
3.审核接口测试:
POSTMAN测试实例:
*须在Headers 加入kdservice-sessionid 参数,值为登录接口是返回的kdservice-sessionid值
*须根据保存接口返回的单据编号和内码id入参
json格式:
{"formid":"GL_VOUCHER",
"data":{
"CreateOrgId": "0",
"Numbers":"132202",
"Ids": "535009",
"InterationFlags": "0"
}}
赞 10
10人点赞
还没有人点赞,快来当第一个点赞的人吧!
打赏
0人打赏
还没有人打赏,快来当第一个打赏的人吧!
推荐阅读