应收单和收款单接口调用实例

栏目:云星空知识作者:金蝶来源:金蝶云社区发布:2024-09-16浏览:1

应收单和收款单接口调用实例

金蝶云星空V7.5.1450.1版本webAPI接口测试实例目录

说明:三方系统调用金蝶云星空 应收单和收款单接口实现单据保存、提交、审核、下推,实现三方系统联动

/**以下内容参考金蝶【C】webAPI接口文档说明整理形成,仅供交流参考。**/


1.保存接口测试:


(1)通过金蝶webAPI文档工具查看对应单据的文档信息,在线测试填写单据数据,拿返回实例json

image.webp

*formid:可在金蝶webAPI文档工具中的代码示例中的client.Save中获取,如 AR_receivable

POSTMAN测试实例:

image.webp


*须在Headers 加入kdservice-sessionid 参数,值为登录接口是返回的kdservice-sessionid值

image.webp

json格式:

{"formid":"AR_receivable",
    "data":{
    "NeedUpDateFields": [],
    "NeedReturnFields": [],
    "IsDeleteEntry""true",
    "SubSystemId""",
    "IsVerifyBaseDataField""false",
    "IsEntryBatchFill""true",
    "ValidateFlag""true",
    "NumberSearch""true",
    "InterationFlags""",
    "IsAutoSubmitAndAudit""false",
    "Model": {
        "FID"0,
        "FBillTypeID": {
            "FNUMBER""YSD01_SYS"
        },
        "FDATE""2022-08-30 00:00:00",
        "FISINIT"false,
        "FENDDATE_H""2022-08-30 00:00:00",
        "FCUSTOMERID": {
            "FNumber""10-201"
        },
        "FCURRENCYID": {
            "FNumber""PRE001"
        },
        "FPayConditon": {
            "FNumber""SKTJ00_SYS"
        },
        "FISPRICEEXCLUDETAX"true,
        "FSETTLEORGID": {
            "FNumber""0051014"
        },
        "FPAYORGID": {
            "FNumber""0051014"
        },
        "FSALEORGID": {
            "FNumber""0051014"
        },
        "FISTAX"true,
        "FCancelStatus""A",
        "FBUSINESSTYPE""BZ",
        "F_TP_Text1""测试应收单数据保存",
        "FSetAccountType""1",
        "FISHookMatch"false,
        "FISINVOICEARLIER"false,
        "FWBOPENQTY"false,
        "FsubHeadSuppiler": {
            "FORDERID": {
                "FNumber""10-201"
            },
            "FTRANSFERID": {
                "FNumber""10-201"
            },
            "FChargeId": {
                "FNumber""10-201"
            }
        },
        "FsubHeadFinc": {
            "FACCNTTIMEJUDGETIME""2022-08-30 00:00:00",
            "FMAINBOOKSTDCURRID": {
                "FNumber""PRE001"
            },
            "FEXCHANGETYPE": {
                "FNumber""HLTX01_SYS"
            },
            "FExchangeRate"1.0,
            "FTaxAmountFor"291.26,
            "FNoTaxAmountFor"9708.74
        },
        "FEntityDetail": [
            {
                "FMATERIALID": {
                    "FNumber""003"
                },
                "FMaterialDesc""服务费",
                "FPRICEUNITID": {
                    "FNumber""Pcs"
                },
                "FPriceQty"1.0,
                "FTaxPrice"10000.0,
                "FPrice"9708.737864,
                "FEntryTaxRate"3.00,
                "FNoTaxAmountFor_D"9708.74,
                "FTAXAMOUNTFOR_D"291.26,
                "FALLAMOUNTFOR_D"10000.00,
                "FDeliveryControl"false,
                "FStockUnitId": {
                    "FNumber""Pcs"
                },
                "FStockQty"1.0,
                "FIsFree"false,
                "FStockBaseQty"1.0,
                "FSalUnitId": {
                    "FNumber""Pcs"
                },
                "FSalQty"1.0,
                "FSalBaseQty"1.0,
                "FPriceBaseDen"1.0,
                "FSalBaseNum"1.0,
                "FStockBaseNum"1.0
            }
        ],
        "FEntityPlan": [
            {
                "FENDDATE""2022-08-30 00:00:00",
                "FPAYRATE"100.00000,
                "FPAYAMOUNTFOR"10000.00
            }
        ]
    }
}
}


2.提交接口测试:


POSTMAN测试实例:

image.webp

*须在Headers 加入kdservice-sessionid 参数,值为登录接口时返回的kdservice-sessionid值

*须根据保存接口返回的单据编号和内码id入参

json格式:

{"formid":"AR_receivable",
 "data":{
    "CreateOrgId""0",
    "Numbers":"AR00000243",
    "Ids""101019",
    "SelectedPostId""0"
}}


3.审核接口测试:


POSTMAN测试实例:

image.webp

*须在Headers 加入kdservice-sessionid 参数,值为登录接口是返回的kdservice-sessionid值

*须根据保存接口返回的单据编号和内码id入参

json格式:

{"formid":"AR_receivable",
 "data":{
    "CreateOrgId""0",
    "Numbers":"AR00000243",
    "Ids""101019",
    "InterationFlags""0"
}}


4.下推接口测试:


POSTMAN测试实例:

image.webp


应收单转收款单参数说明:

参数列表

参数含义

 备注  

formid

应收单模板ID:AR_receivable

必录

data

数据包

{\"Ids\":\"\",

\"Numbers\":[],

\"EntryIds\":\"\",

\"RuleId\":\"\",

\"TargetBillTypeId\":\"\",

\"TargetOrgId\":\"0\",

\"TargetFormId\":\"\",

\"IsEnableDefaultRule\":\"false\",

\"CustomParams\":{}}

1. Ids:应收单单据内码ID

2.Numbers:应收单单据编号

3.EntryIds: 

4.RuleId:应收单转收款单规则ID(在开发平台单据转换里获取)        

5.TargetBillTypeId:空

6.TargetOrgId:结算组织内码,从T_ORG_ORGANIZATIONS_L中获取的FORGID值

7.TargetFormId:收款单单据模板ID

8.IsEnableDefaultRule:false

9.IsDraftWhenSaveFail: false

10.CustomParams:空

  

*TargetOrgId:select FORGID from T_ORG_ORGANIZATIONS_L where FNAME='结算组织名称'

json格式:

{"formid":"AR_receivable",
    "data":{
    "Ids""101019",
    "Numbers":"AR00000243",
    "EntryIds""",
    "RuleId""AR_recableToRecBill",
    "TargetBillTypeId""",
    "TargetOrgId""100003",
    "TargetFormId""AR_RECEIVEBILL",
    "IsEnableDefaultRule""false",
    "IsDraftWhenSaveFail""false",
    "CustomParams": {}
}}


*下推成功后再通过提交、审核接口对下推生成的收款单进行提交和审核操作即可。




应收单和收款单接口调用实例

金蝶云星空V7.5.1450.1版本webAPI接口测试实例目录说明:三方系统调用金蝶云星空 应收单和收款单接口实现单据保存、提交、审核、下推,实...
点击下载文档
确认删除?
回到顶部
客服QQ
  • 客服QQ点击这里给我发消息