在 Quickbooks 桌面版中,当我为发票的交易类型运行交易详细报告时,我显示了 5 个帐户:应收帐款、库存资产、应付销售税、销售额和销售成本。
但是,当我通过 .NET IPP DevKit v2 运行此程序时,我只看到其中的 3 个帐户:应收帐款、应付销售税和销售额。因此,缺少库存和已售商品成本。
代码:
CustomTxnDetail detail = new CustomTxnDetail();
detail.OfferingId = offeringId.ipp;
detail.OfferingIdSpecified = true;
detail.ReportBasis = ReportBasisEnum.Accrual;
detail.ReportBasisSpecified = true;
detail.ItemsElementName = new ItemsChoiceType6[] {
ItemsChoiceType6.StartTransactionDate,
ItemsChoiceType6.EndTransactionDate,
};
detail.Items = new object[] {
new DateTime(2013, 1, 1),
new DateTime(2013, 12, 31),
};
detail.Columns = new[] {
DetailColumnsEnum.AccountId,
DetailColumnsEnum.AccountName,
DetailColumnsEnum.Amount,
DetailColumnsEnum.DocNum,
DetailColumnsEnum.ItemId,
DetailColumnsEnum.ItemName,
DetailColumnsEnum.ItemType,
DetailColumnsEnum.TxnDate,
DetailColumnsEnum.TxnId,
DetailColumnsEnum.TxnLineId,
DetailColumnsEnum.TxnType,
DetailColumnsEnum.UnitPrice,
};
detail.TxnType = new[] {
TxnTypeEnum.Invoice,
};
ReportingServices rptSvc = new ReportingServices(context);
Report rpt = rptSvc.CustomTxnDetailsReport(detail);
要求:
<?xml version="1.0" encoding="utf-8"?>
<AdvancedReportQuery xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.intuit.com/sb/cdm/v2">
<CustomTxnDetail>
<OfferingId>ipp</OfferingId>
<StartTransactionDate>2013-01-01T00:00:00</StartTransactionDate>
<EndTransactionDate>2013-12-31T00:00:00</EndTransactionDate>
<TxnType>Invoice</TxnType>
<ReportBasis>Accrual</ReportBasis>
<Columns>AccountId</Columns>
<Columns>AccountName</Columns>
<Columns>Amount</Columns>
<Columns>DocNum</Columns>
<Columns>ItemId</Columns>
<Columns>ItemName</Columns>
<Columns>ItemType</Columns>
<Columns>TxnDate</Columns>
<Columns>TxnId</Columns>
<Columns>TxnLineId</Columns>
<Columns>TxnType</Columns>
<Columns>UnitPrice</Columns>
</CustomTxnDetail>
</AdvancedReportQuery>
回复:
<?xml version="1.0" encoding="UTF-8"?>
<!--XML GENERATED by IntuitDataSyncEngine (IDS) using \\SBDomainServices\CDM\branches\3.9.0-rel-1-->
<RestResponse xmlns="http://www.intuit.com/sb/cdm/v2"
xmlns:xdb ="http://xmlns.oracle.com/xdb"
xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation ="http://www.intuit.com/sb/cdm/v2 RestDataFilter.xsd">
<Report name="CustomerTxnDetail">
<ColDesc>
<ColTitle>AccountId</ColTitle>
<ColType>ids_IdType</ColType>
</ColDesc>
<ColDesc>
<ColTitle>AccountName</ColTitle>
<ColType>ids_String</ColType>
</ColDesc>
<ColDesc>
<ColTitle>Amount</ColTitle>
<ColType>ids_Amount</ColType>
</ColDesc>
<ColDesc>
<ColTitle>DocNum</ColTitle>
<ColType>ids_String</ColType>
</ColDesc>
<ColDesc>
<ColTitle>ItemId</ColTitle>
<ColType>ids_IdType</ColType>
</ColDesc>
<ColDesc>
<ColTitle>ItemName</ColTitle>
<ColType>ids_String</ColType>
</ColDesc>
<ColDesc>
<ColTitle>ItemType</ColTitle>
<ColType>ids_String</ColType>
</ColDesc>
<ColDesc>
<ColTitle>TxnDate</ColTitle>
<ColType>ids_Date</ColType>
</ColDesc>
<ColDesc>
<ColTitle>TxnId</ColTitle>
<ColType>ids_IdType</ColType>
</ColDesc>
<ColDesc>
<ColTitle>TxnLineId</ColTitle>
<ColType>ids_IdType</ColType>
</ColDesc>
<ColDesc>
<ColTitle>TxnType</ColTitle>
<ColType>ids_String</ColType>
</ColDesc>
<ColDesc>
<ColTitle>UnitPriceQnty</ColTitle>
<ColType>ids_Amount</ColType>
</ColDesc>
<Data>
<DataRow>
<ColData>6</ColData>
<ColData>Sales</ColData>
<ColData>-524.85</ColData>
<ColData/>
<ColData>39</ColData>
<ColData>201</ColData>
<ColData>Inventory</ColData>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData>34.99</ColData>
</DataRow>
<DataRow>
<ColData>6</ColData>
<ColData>Sales</ColData>
<ColData>-174.95</ColData>
<ColData/>
<ColData>40</ColData>
<ColData>200</ColData>
<ColData>Inventory</ColData>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData>34.99</ColData>
</DataRow>
<DataRow>
<ColData>6</ColData>
<ColData>Sales</ColData>
<ColData>-209.94</ColData>
<ColData/>
<ColData>37</ColData>
<ColData>203</ColData>
<ColData>Inventory</ColData>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData>34.99</ColData>
</DataRow>
<DataRow>
<ColData>32</ColData>
<ColData>Sales Tax Payable</ColData>
<ColData>0</ColData>
<ColData/>
<ColData>1</ColData>
<ColData>Out of State</ColData>
<ColData>Sales Tax Item</ColData>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData/>
</DataRow>
<DataRow>
<ColData>32</ColData>
<ColData>Sales Tax Payable</ColData>
<ColData>0</ColData>
<ColData/>
<ColData>1</ColData>
<ColData>Out of State</ColData>
<ColData>Sales Tax Item</ColData>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData/>
</DataRow>
<DataRow>
<ColData>35</ColData>
<ColData>Accounts Receivable</ColData>
<ColData>734.79</ColData>
<ColData/>
<ColData/>
<ColData/>
<ColData/>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData/>
</DataRow>
<DataRow>
<ColData>35</ColData>
<ColData>Accounts Receivable</ColData>
<ColData>174.95</ColData>
<ColData/>
<ColData/>
<ColData/>
<ColData/>
<ColData>2013-09-18</ColData>
<ColData/>
<ColData/>
<ColData>Invoice</ColData>
<ColData/>
</DataRow>
</Data>
</Report>
</RestResponse>
有什么想法吗?我完全被困住了:(