SData-2.0 icon indicating copy to clipboard operation
SData-2.0 copied to clipboard

Sdata and Service Descriptions

Open mellowms opened this issue 7 years ago • 1 comments

Hello,

We often bill service items through our sage invoices and we are trying to build a link between our ticketing system and sage so clients can be billed automatically

Right now i have the following xml that created a sales invoice against a tradeAccount, adds a product then 2 commentary lines (for description purposes) then a final line item

<entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:cf="http://www.microsoft.com/schemas/rss/core/2005" xmlns="http://www.w3.org/2005/Atom" xmlns:sdatasync="http://schemas.sage.com/sdata/sync/2008/1" xmlns:sdata="http://schemas.sage.com/sdata/2008/1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:sme="http://schemas.sage.com/sdata/sme/2007" xmlns:http="http://schemas.sage.com/sdata/http/2008/1" xmlns:sc="http://schemas.sage.com/sc/2009" xmlns:crm="http://schemas.sage.com/crmErp/2008">
    <author />
    <sdata:payload>
        <crm:salesInvoice sdata:uuid="00000000-0000-0000-0000-000000000000">
            <crm:active>true</crm:active>
            <crm:reference />
            <crm:reference2 />
            <crm:status>Written</crm:status>
            <crm:allocationStatus xsi:nil="true" />
            <crm:deliveryStatus xsi:nil="true" />
            <crm:statusFlag xsi:nil="true" />
            <crm:statusFlagText xsi:nil="true" />
            <crm:type>Product Invoice</crm:type>
            <crm:tradingAccount sdata:uuid="2d748478-a869-4a3b-81aa-abf9629c67a3" />
            <crm:customerReference />
            <crm:opportunity xsi:nil="true" />
            <crm:pricelist xsi:nil="true" />
            <crm:copyFlag xsi:nil="true" />
            <crm:date>2018-07-07</crm:date>
            <crm:time xsi:nil="true" />
            <crm:taxDate>2018-07-07</crm:taxDate>
            <crm:taxCodes xsi:nil="true" />
            <crm:postalAddresses xsi:nil="true" />
            <crm:deliveryMethod xsi:nil="true" />
            <crm:deliveryTerms xsi:nil="true" />
            <crm:deliveryRule xsi:nil="true" />
            <crm:deliveryDate xsi:nil="true" />
            <crm:carrierCompany xsi:nil="true" />
            <crm:carrierTradingAccount xsi:nil="true" />
            <crm:carrierNetPrice>0.00</crm:carrierNetPrice>
            <crm:carrierTaxPrice>0.00</crm:carrierTaxPrice>
            <crm:carrierTotalPrice>0.00</crm:carrierTotalPrice>
            <crm:carrierSalesInvoice xsi:nil="true" />
            <crm:carrierTaxCodes xsi:nil="true" />
            <crm:carrierReference xsi:nil="true" />
            <crm:currency>GBP</crm:currency>
            <crm:operatingCompanyCurrency>GBP</crm:operatingCompanyCurrency>
            <crm:operatingCompanyCurrencyExchangeRate>1</crm:operatingCompanyCurrencyExchangeRate>
            <crm:operatingCompanyCurrencyExchangeRateDate>2018-07-07</crm:operatingCompanyCurrencyExchangeRateDate>
            <crm:customerTradingAccountCurrency xsi:nil="true" />
            <crm:customerTradingAccountCurrencyExchangeRate xsi:nil="true" />
            <crm:customerTradingAccountCurrencyExchangeRateOperator xsi:nil="true" />
            <crm:customerTradingAccountCurrencyExchangeRateDate xsi:nil="true" />
            <crm:buyerContact xsi:nil="true" />
            <crm:salespersons xsi:nil="true" />
            <crm:salesInvoiceLines>
                <crm:salesInvoiceLine sdata:uuid="00000000-0000-0000-0000-000000000000">
                    <crm:originatorDocumentLine xsi:nil="true" />
                    <crm:active>true</crm:active>
                    <crm:reference />
                    <crm:reference2 />
                    <crm:status xsi:nil="true" />
                    <crm:type>Stock Item</crm:type>
                    <crm:number>1</crm:number>
                    <crm:commodity sdata:uuid="e11bd06a-56a3-4e35-abe2-9a923490d5ab" />
                    <crm:text>Labour Charge</crm:text>
                    <crm:deliveryTerms xsi:nil="true" />
                    <crm:deliveryDate xsi:nil="true" />
                    <crm:carrierTradingAccount xsi:nil="true" />
                    <crm:carrierNetPrice xsi:nil="true" />
                    <crm:carrierTaxPrice xsi:nil="true" />
                    <crm:carrierTotalPrice xsi:nil="true" />
                    <crm:carrierSalesInvoiceLine xsi:nil="true" />
                    <crm:carrierTaxCodes xsi:nil="true" />
                    <crm:carrierReference xsi:nil="true" />
                    <crm:unitOfMeasure xsi:nil="true" />
                    <crm:quantity>1</crm:quantity>
                    <crm:initialPrice>11.00</crm:initialPrice>
                    <crm:pricelist xsi:nil="true" />
                    <crm:settlementDiscountType xsi:nil="true" />
                    <crm:settlementDiscountAmount xsi:nil="true" />
                    <crm:settlementDiscountPercent xsi:nil="true" />
                    <crm:settlementDiscountTerms xsi:nil="true" />
                    <crm:invoiceLineDiscountType xsi:nil="true" />
                    <crm:invoiceLineDiscountAmount>0.00</crm:invoiceLineDiscountAmount>
                    <crm:invoiceLineDiscountPercent>0.00</crm:invoiceLineDiscountPercent>
                    <crm:invoiceLineSubtotalDiscountType xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountAmount xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountPercent xsi:nil="true" />
                    <crm:actualPrice>11.00</crm:actualPrice>
                    <crm:netTotal>11.00</crm:netTotal>
                    <crm:chargesTotal xsi:nil="true" />
                    <crm:discountTotal>0.00</crm:discountTotal>
                    <crm:fOBPoint xsi:nil="true" />
                    <crm:taxCodes xsi:nil="true" />
                    <crm:priceTax xsi:nil="true" />
                    <crm:taxTotal>2.20</crm:taxTotal>
                    <crm:grossTotal>13.20</crm:grossTotal>
                    <crm:costTotal xsi:nil="true" />
                    <crm:profitTotal xsi:nil="true" />
                    <crm:project xsi:nil="true" />
                    <crm:salesOrderDeliveryLines xsi:nil="true" />
                    <crm:receipts xsi:nil="true" />
                    <crm:financialAccounts xsi:nil="true" />
                    <crm:notes xsi:nil="true" />
                </crm:salesInvoiceLine>
                <crm:salesInvoiceLine sdata:uuid="00000000-0000-0000-0000-000000000000">
                    <crm:originatorDocumentLine xsi:nil="true" />
                    <crm:active>true</crm:active>
                    <crm:reference />
                    <crm:reference2 />
                    <crm:status xsi:nil="true" />
                    <crm:type>Commentary</crm:type>
                    <crm:number>2</crm:number>
                    <crm:commodity xsi:nil="true" />
                    <crm:text>123345</crm:text>
                    <crm:deliveryTerms xsi:nil="true" />
                    <crm:deliveryDate xsi:nil="true" />
                    <crm:carrierTradingAccount xsi:nil="true" />
                    <crm:carrierNetPrice xsi:nil="true" />
                    <crm:carrierTaxPrice xsi:nil="true" />
                    <crm:carrierTotalPrice xsi:nil="true" />
                    <crm:carrierSalesInvoiceLine xsi:nil="true" />
                    <crm:carrierTaxCodes xsi:nil="true" />
                    <crm:carrierReference xsi:nil="true" />
                    <crm:unitOfMeasure xsi:nil="true" />
                    <crm:quantity>1</crm:quantity>
                    <crm:initialPrice>0.00</crm:initialPrice>
                    <crm:pricelist xsi:nil="true" />
                    <crm:settlementDiscountType xsi:nil="true" />
                    <crm:settlementDiscountAmount xsi:nil="true" />
                    <crm:settlementDiscountPercent xsi:nil="true" />
                    <crm:settlementDiscountTerms xsi:nil="true" />
                    <crm:invoiceLineDiscountType xsi:nil="true" />
                    <crm:invoiceLineDiscountAmount>0.00</crm:invoiceLineDiscountAmount>
                    <crm:invoiceLineDiscountPercent>0.00</crm:invoiceLineDiscountPercent>
                    <crm:invoiceLineSubtotalDiscountType xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountAmount xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountPercent xsi:nil="true" />
                    <crm:actualPrice>0.00</crm:actualPrice>
                    <crm:netTotal>0.00</crm:netTotal>
                    <crm:chargesTotal xsi:nil="true" />
                    <crm:discountTotal>0.00</crm:discountTotal>
                    <crm:fOBPoint xsi:nil="true" />
                    <crm:taxCodes xsi:nil="true" />
                    <crm:priceTax xsi:nil="true" />
                    <crm:taxTotal>0.00</crm:taxTotal>
                    <crm:grossTotal>0.00</crm:grossTotal>
                    <crm:costTotal xsi:nil="true" />
                    <crm:profitTotal xsi:nil="true" />
                    <crm:project xsi:nil="true" />
                    <crm:salesOrderDeliveryLines xsi:nil="true" />
                    <crm:receipts xsi:nil="true" />
                    <crm:financialAccounts xsi:nil="true" />
                    <crm:notes xsi:nil="true" />
                </crm:salesInvoiceLine>
                <crm:salesInvoiceLine sdata:uuid="00000000-0000-0000-0000-000000000000">
                    <crm:originatorDocumentLine xsi:nil="true" />
                    <crm:active>true</crm:active>
                    <crm:reference />
                    <crm:reference2 />
                    <crm:status xsi:nil="true" />
                    <crm:type>Commentary</crm:type>
                    <crm:number>3</crm:number>
                    <crm:commodity xsi:nil="true" />
                    <crm:text>16</crm:text>
                    <crm:deliveryTerms xsi:nil="true" />
                    <crm:deliveryDate xsi:nil="true" />
                    <crm:carrierTradingAccount xsi:nil="true" />
                    <crm:carrierNetPrice xsi:nil="true" />
                    <crm:carrierTaxPrice xsi:nil="true" />
                    <crm:carrierTotalPrice xsi:nil="true" />
                    <crm:carrierSalesInvoiceLine xsi:nil="true" />
                    <crm:carrierTaxCodes xsi:nil="true" />
                    <crm:carrierReference xsi:nil="true" />
                    <crm:unitOfMeasure xsi:nil="true" />
                    <crm:quantity>1</crm:quantity>
                    <crm:initialPrice>0.00</crm:initialPrice>
                    <crm:pricelist xsi:nil="true" />
                    <crm:settlementDiscountType xsi:nil="true" />
                    <crm:settlementDiscountAmount xsi:nil="true" />
                    <crm:settlementDiscountPercent xsi:nil="true" />
                    <crm:settlementDiscountTerms xsi:nil="true" />
                    <crm:invoiceLineDiscountType xsi:nil="true" />
                    <crm:invoiceLineDiscountAmount>0.00</crm:invoiceLineDiscountAmount>
                    <crm:invoiceLineDiscountPercent>0.00</crm:invoiceLineDiscountPercent>
                    <crm:invoiceLineSubtotalDiscountType xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountAmount xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountPercent xsi:nil="true" />
                    <crm:actualPrice>0.00</crm:actualPrice>
                    <crm:netTotal>0.00</crm:netTotal>
                    <crm:chargesTotal xsi:nil="true" />
                    <crm:discountTotal>0.00</crm:discountTotal>
                    <crm:fOBPoint xsi:nil="true" />
                    <crm:taxCodes xsi:nil="true" />
                    <crm:priceTax xsi:nil="true" />
                    <crm:taxTotal>0.00</crm:taxTotal>
                    <crm:grossTotal>0.00</crm:grossTotal>
                    <crm:costTotal xsi:nil="true" />
                    <crm:profitTotal xsi:nil="true" />
                    <crm:project xsi:nil="true" />
                    <crm:salesOrderDeliveryLines xsi:nil="true" />
                    <crm:receipts xsi:nil="true" />
                    <crm:financialAccounts xsi:nil="true" />
                    <crm:notes xsi:nil="true" />
                </crm:salesInvoiceLine>
                <crm:salesInvoiceLine sdata:uuid="00000000-0000-0000-0000-000000000000">
                    <crm:originatorDocumentLine xsi:nil="true" />
                    <crm:active>true</crm:active>
                    <crm:reference />
                    <crm:reference2 />
                    <crm:status xsi:nil="true" />
                    <crm:type>Commentary</crm:type>
                    <crm:number>4</crm:number>
                    <crm:commodity xsi:nil="true" />
                    <crm:text>4</crm:text>
                    <crm:deliveryTerms xsi:nil="true" />
                    <crm:deliveryDate xsi:nil="true" />
                    <crm:carrierTradingAccount xsi:nil="true" />
                    <crm:carrierNetPrice xsi:nil="true" />
                    <crm:carrierTaxPrice xsi:nil="true" />
                    <crm:carrierTotalPrice xsi:nil="true" />
                    <crm:carrierSalesInvoiceLine xsi:nil="true" />
                    <crm:carrierTaxCodes xsi:nil="true" />
                    <crm:carrierReference xsi:nil="true" />
                    <crm:unitOfMeasure xsi:nil="true" />
                    <crm:quantity>1</crm:quantity>
                    <crm:initialPrice>0.00</crm:initialPrice>
                    <crm:pricelist xsi:nil="true" />
                    <crm:settlementDiscountType xsi:nil="true" />
                    <crm:settlementDiscountAmount xsi:nil="true" />
                    <crm:settlementDiscountPercent xsi:nil="true" />
                    <crm:settlementDiscountTerms xsi:nil="true" />
                    <crm:invoiceLineDiscountType xsi:nil="true" />
                    <crm:invoiceLineDiscountAmount>0.00</crm:invoiceLineDiscountAmount>
                    <crm:invoiceLineDiscountPercent>0.00</crm:invoiceLineDiscountPercent>
                    <crm:invoiceLineSubtotalDiscountType xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountAmount xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountPercent xsi:nil="true" />
                    <crm:actualPrice>0.00</crm:actualPrice>
                    <crm:netTotal>0.00</crm:netTotal>
                    <crm:chargesTotal xsi:nil="true" />
                    <crm:discountTotal>0.00</crm:discountTotal>
                    <crm:fOBPoint xsi:nil="true" />
                    <crm:taxCodes xsi:nil="true" />
                    <crm:priceTax xsi:nil="true" />
                    <crm:taxTotal>0.00</crm:taxTotal>
                    <crm:grossTotal>0.00</crm:grossTotal>
                    <crm:costTotal xsi:nil="true" />
                    <crm:profitTotal xsi:nil="true" />
                    <crm:project xsi:nil="true" />
                    <crm:salesOrderDeliveryLines xsi:nil="true" />
                    <crm:receipts xsi:nil="true" />
                    <crm:financialAccounts xsi:nil="true" />
                    <crm:notes xsi:nil="true" />
                </crm:salesInvoiceLine>
                <crm:salesInvoiceLine sdata:uuid="00000000-0000-0000-0000-000000000000">
                    <crm:originatorDocumentLine xsi:nil="true" />
                    <crm:active>true</crm:active>
                    <crm:reference />
                    <crm:reference2 />
                    <crm:status xsi:nil="true" />
                    <crm:type>Commentary</crm:type>
                    <crm:number>5</crm:number>
                    <crm:commodity xsi:nil="true" />
                    <crm:text>3</crm:text>
                    <crm:deliveryTerms xsi:nil="true" />
                    <crm:deliveryDate xsi:nil="true" />
                    <crm:carrierTradingAccount xsi:nil="true" />
                    <crm:carrierNetPrice xsi:nil="true" />
                    <crm:carrierTaxPrice xsi:nil="true" />
                    <crm:carrierTotalPrice xsi:nil="true" />
                    <crm:carrierSalesInvoiceLine xsi:nil="true" />
                    <crm:carrierTaxCodes xsi:nil="true" />
                    <crm:carrierReference xsi:nil="true" />
                    <crm:unitOfMeasure xsi:nil="true" />
                    <crm:quantity>1</crm:quantity>
                    <crm:initialPrice>0.00</crm:initialPrice>
                    <crm:pricelist xsi:nil="true" />
                    <crm:settlementDiscountType xsi:nil="true" />
                    <crm:settlementDiscountAmount xsi:nil="true" />
                    <crm:settlementDiscountPercent xsi:nil="true" />
                    <crm:settlementDiscountTerms xsi:nil="true" />
                    <crm:invoiceLineDiscountType xsi:nil="true" />
                    <crm:invoiceLineDiscountAmount>0.00</crm:invoiceLineDiscountAmount>
                    <crm:invoiceLineDiscountPercent>0.00</crm:invoiceLineDiscountPercent>
                    <crm:invoiceLineSubtotalDiscountType xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountAmount xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountPercent xsi:nil="true" />
                    <crm:actualPrice>0.00</crm:actualPrice>
                    <crm:netTotal>0.00</crm:netTotal>
                    <crm:chargesTotal xsi:nil="true" />
                    <crm:discountTotal>0.00</crm:discountTotal>
                    <crm:fOBPoint xsi:nil="true" />
                    <crm:taxCodes xsi:nil="true" />
                    <crm:priceTax xsi:nil="true" />
                    <crm:taxTotal>0.00</crm:taxTotal>
                    <crm:grossTotal>0.00</crm:grossTotal>
                    <crm:costTotal xsi:nil="true" />
                    <crm:profitTotal xsi:nil="true" />
                    <crm:project xsi:nil="true" />
                    <crm:salesOrderDeliveryLines xsi:nil="true" />
                    <crm:receipts xsi:nil="true" />
                    <crm:financialAccounts xsi:nil="true" />
                    <crm:notes xsi:nil="true" />
                </crm:salesInvoiceLine>
                <crm:salesInvoiceLine sdata:uuid="00000000-0000-0000-0000-000000000000">
                    <crm:originatorDocumentLine xsi:nil="true" />
                    <crm:active>true</crm:active>
                    <crm:reference />
                    <crm:reference2 />
                    <crm:status xsi:nil="true" />
                    <crm:type>Stock Item</crm:type>
                    <crm:number>6</crm:number>
                    <crm:commodity sdata:uuid="07f4eac9-eccf-4714-ad9e-44402ddf4487" />
                    <crm:text>Labour Charge</crm:text>
                    <crm:deliveryTerms xsi:nil="true" />
                    <crm:deliveryDate xsi:nil="true" />
                    <crm:carrierTradingAccount xsi:nil="true" />
                    <crm:carrierNetPrice xsi:nil="true" />
                    <crm:carrierTaxPrice xsi:nil="true" />
                    <crm:carrierTotalPrice xsi:nil="true" />
                    <crm:carrierSalesInvoiceLine xsi:nil="true" />
                    <crm:carrierTaxCodes xsi:nil="true" />
                    <crm:carrierReference xsi:nil="true" />
                    <crm:unitOfMeasure xsi:nil="true" />
                    <crm:quantity>1</crm:quantity>
                    <crm:initialPrice>11.00</crm:initialPrice>
                    <crm:pricelist xsi:nil="true" />
                    <crm:settlementDiscountType xsi:nil="true" />
                    <crm:settlementDiscountAmount xsi:nil="true" />
                    <crm:settlementDiscountPercent xsi:nil="true" />
                    <crm:settlementDiscountTerms xsi:nil="true" />
                    <crm:invoiceLineDiscountType xsi:nil="true" />
                    <crm:invoiceLineDiscountAmount>0.00</crm:invoiceLineDiscountAmount>
                    <crm:invoiceLineDiscountPercent>0.00</crm:invoiceLineDiscountPercent>
                    <crm:invoiceLineSubtotalDiscountType xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountAmount xsi:nil="true" />
                    <crm:invoiceLineSubtotalDiscountPercent xsi:nil="true" />
                    <crm:actualPrice>11.00</crm:actualPrice>
                    <crm:netTotal>11.00</crm:netTotal>
                    <crm:chargesTotal xsi:nil="true" />
                    <crm:discountTotal>0.00</crm:discountTotal>
                    <crm:fOBPoint xsi:nil="true" />
                    <crm:taxCodes xsi:nil="true" />
                    <crm:priceTax xsi:nil="true" />
                    <crm:taxTotal>2.20</crm:taxTotal>
                    <crm:grossTotal>13.20</crm:grossTotal>
                    <crm:costTotal xsi:nil="true" />
                    <crm:profitTotal xsi:nil="true" />
                    <crm:project xsi:nil="true" />
                    <crm:salesOrderDeliveryLines xsi:nil="true" />
                    <crm:receipts xsi:nil="true" />
                    <crm:financialAccounts xsi:nil="true" />
                    <crm:notes xsi:nil="true" />
                </crm:salesInvoiceLine>
            </crm:salesInvoiceLines>
            <crm:lineCount>6</crm:lineCount>
            <crm:originatorDocument xsi:nil="true" />
            <crm:salesOrderDeliveries xsi:nil="true" />
            <crm:receipts xsi:nil="true" />
            <crm:contract xsi:nil="true" />
            <crm:settlementDiscountType xsi:nil="true" />
            <crm:settlementDiscountAmount>0.00</crm:settlementDiscountAmount>
            <crm:settlementDiscountPercent>0.00</crm:settlementDiscountPercent>
            <crm:settlementDiscountTerms>30.00</crm:settlementDiscountTerms>
            <crm:settlementDiscountIncludedInTotal>true</crm:settlementDiscountIncludedInTotal>
            <crm:invoiceDiscountType xsi:nil="true" />
            <crm:invoiceDiscountAmount>0.00</crm:invoiceDiscountAmount>
            <crm:invoiceDiscountPercent>0.00</crm:invoiceDiscountPercent>
            <crm:invoiceAdditionalDiscount1Type xsi:nil="true" />
            <crm:invoiceAdditionalDiscount1Amount xsi:nil="true" />
            <crm:invoiceAdditionalDiscount1Percent xsi:nil="true" />
            <crm:invoiceAdditionalDiscount2 xsi:nil="true" />
            <crm:invoiceAdditionalDiscount2Amount xsi:nil="true" />
            <crm:invoiceAdditionalDiscount2Percent xsi:nil="true" />
            <crm:netTotal xsi:nil="true" />
            <crm:discountTotal xsi:nil="true" />
            <crm:chargesTotal xsi:nil="true" />
            <crm:taxTotal xsi:nil="true" />
            <crm:grossTotal xsi:nil="true" />
            <crm:costTotal xsi:nil="true" />
            <crm:profitTotal xsi:nil="true" />
            <crm:text1 />
            <crm:text2 />
            <crm:projects xsi:nil="true" />
            <crm:financialAccounts xsi:nil="true" />
            <crm:interactions xsi:nil="true" />
            <crm:user>
            </crm:user>
            <crm:notes xsi:nil="true" />
            <crm:CustomerId xsi:nil="true" />
        </crm:salesInvoice>
    </sdata:payload>
</entry>

Now i know there has been an open ticket about posting descriptions to service items for about 2 years now and the only work around before was to add in commentary lines (like above), is this still the case? I've spent multiple days fetching sdata endpoints and can't find the comment1, comment2, or description fields at all so i'm assuming so.

Are there any other work arounds that may be better than this now?

We often need to have the invoice item store the ticket description which can be up to 300 characters long hence the request for the description field

Regards, Jamie

mellowms avatar Aug 21 '18 14:08 mellowms

Unfortunately not. We have had the same issue and so have written our own sData type provider due to Sage no longer supporting Sage 50 UK SData.

The only issue that has recently been fixed is the incorrect setting of nominal codes for stock item lines if a comment line has been posted before it. It would be worth checking the nominal codes of your line 6 to see if the nominal code is correct.

asterix187 avatar Nov 30 '18 15:11 asterix187