Sales Order XML Import Overrides Price  Topic is solved

Find general Jiwa support here.

Sales Order XML Import Overrides Price

Postby bretto36 » Wed Jan 11, 2017 10:08 am

Hi All

I currently have an issue where we are passing an Sales Order XML file to be imported. We are specifying the DiscountedPrice as 20.

When the sales order is loaded it's being reduced by 20% due to a Price Scheme discount. What do i need to put into the XML to stop this.

Current XML

<?xml version="1.0"?>
<JiwaDocument xmlns:jiwa="http://www.jiwa.com.au/xml/schemas" Type="SalesOrder">
<SystemSettings xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML">
<ForceInventorySelection>false</ForceInventorySelection>
<SuppressLineRetotalling>false</SuppressLineRetotalling>
</SystemSettings>
<Staff xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML">
<StaffID xmlns="Entities.Staff"><![CDATA[afb02947fa4e47cb96b2]]></StaffID>
</Staff>
<LogicalID xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML"><![CDATA[ZZZZZZZZZZ0000000000]]></LogicalID>
<OrderNo xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML"><![CDATA[Test8]]></OrderNo>
<SOReference xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML"><![CDATA[Automatic Web Order71020 - test8]]></SOReference>
<Debtor xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML">
<AccountNo><![CDATA[1001]]></AccountNo>
</Debtor>
<Cartage1ExGst xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML">15.0000</Cartage1ExGst>
<Lines xmlns="JiwaFinancials.Jiwa.JiwaSales.SalesOrder.XML">
<Line>
<PartNo><![CDATA[ISC-BPR2-W12]]></PartNo>
<Description><![CDATA[BOSCH, Detector, Blue Line GEN2 PIR, Wall mount, 12 x 12m coverage, 2.2 – 2.75m mount height, 9 – 15V DC, 10mA/12V DC]]></Description>
<QuantityOrdered><![CDATA[12]]></QuantityOrdered>
<DiscountedPrice>20.000000</DiscountedPrice>
</Line>
</Lines>
</JiwaDocument>

I have also tried passing in the values of other fields in an attempt to override

<PriceExGst>20.000000</PriceExGst>
<DiscountedPrice>20.000000</DiscountedPrice>
<FixSellPrice>true</FixSellPrice>
<QuotedDiscountedPrice>0</QuotedDiscountedPrice>
<DiscountedPercentage>0.000000</DiscountedPercentage>
<DiscountGiven>0.000000</DiscountGiven>

Any help would be greatly appreciated.
bretto36
I'm new here
I'm new here
 
Posts: 5
Joined: Wed Apr 29, 2015 9:50 am

Re: Sales Order XML Import Overrides Price

Postby Mike.Sheen » Wed Jan 11, 2017 10:29 am

Hi bretto36,

I've taken your sample XML and imported it into Demo data and don't see any issue. I had to alter the partno to match an existing part in the demo data, and I removed the staff section (as your provided staff ID was not present in demo data), but other than that I didn't change anything else and the price came in at the expected $20.00 EX-GST.

The price scheme in demo data for the part I substituted (1170) has a 8.5% discount for the debtor 1001 - but despite this the price was still set to be the price specified in the XML.

This is how the sales order looks after importing:
SalesOrderAfterImport.PNG
Sales Order After Import


Also attached is the modified version of your XML that I used.

So, in summary I'm not seeing the same problem as you report. Can you firstly try importing the attached in a demo database to determine if it's a behaviour difference based on version (I'm using 7.00.175.00).

Mike
Attachments
test.xml
Sample XML file
(1.22 KiB) Downloaded 95 times
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Jiwa Shihan
Jiwa Shihan
 
Posts: 1447
Joined: Tue Feb 12, 2008 10:12 am
Location: North Sydney
Topics Solved: 486

Re: Sales Order XML Import Overrides Price

Postby bretto36 » Wed Jan 11, 2017 11:54 am

Thank you for the quick response. I will chase a demo database to test it on.

Have not had it on any other customers. they are on 7.00.157 so maybe that could be the culprit.
bretto36
I'm new here
I'm new here
 
Posts: 5
Joined: Wed Apr 29, 2015 9:50 am

Re: Sales Order XML Import Overrides Price

Postby bretto36 » Tue Jan 24, 2017 10:14 am

Hi Mike

The customer has upgraded to the current version of Jiwa (the one you tested on) and it's still happening. Is there any sort of setting i can pass through in the XML to get it to not do this. Or is this a setting in Jiwa that i can change for the import?

I've been using the XML Import in the sales order menu to ensure that it's nothing in our code.

I do note on your screenshot the Price Scheme selected is the Default Price Scheme, but when i run the import Price Scheme A is selected.
bretto36
I'm new here
I'm new here
 
Posts: 5
Joined: Wed Apr 29, 2015 9:50 am

Re: Sales Order XML Import Overrides Price

Postby Mike.Sheen » Tue Jan 24, 2017 11:28 am

bretto36 wrote:Hi Mike

Is there any sort of setting i can pass through in the XML to get it to not do this. Or is this a setting in Jiwa that i can change for the import?


No - if the price is supplied in the XML, then that is supposed to be what is used - if no price is supplied, we revert to the normal pricing calculations. This matches my testing on demo data as per my previous post.

bretto36 wrote:I do note on your screenshot the Price Scheme selected is the Default Price Scheme, but when i run the import Price Scheme A is selected.

This likely is not relevant - as mentioned previously whatever pricing is configured, it should be overridden to be price supplied in the XML.

You may have a plugin overriding the default behaviour of the software. Did you test on Demo data as per my previous post with the XML I supplied? If you did and the problem does not occur, then it's not the XML import, but another factor such as a plugin or SQL trigger altering the price.
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Jiwa Shihan
Jiwa Shihan
 
Posts: 1447
Joined: Tue Feb 12, 2008 10:12 am
Location: North Sydney
Topics Solved: 486

Re: Sales Order XML Import Overrides Price

Postby bretto36 » Mon Jan 30, 2017 9:52 am

Hi Mike

Thanks again for your response

I have tried on a default jiwa install. I think i have duplicated the environment as best i could and am not getting the error. So i'm stuck trying to figure out what is overriding the price.

When entering the price manually in a sales order. If i add the product to the order and select one of the prices using the "Up arrow" icon. If i select $25.00 it sets the price at $20.00, If i select the $20 option, it sets it at 16.

I can't find any price scheme/classification price that would be giving a 20% discount all the time. I can't see any plugins that would be doing it either. Is there anything i should be looking for, a method that gets called when someone selects a price in the sales order entry screen?

See screenshots for inventory details. I understand why $20 should be the price given to the customer, But i don't get why if i select $25 or $20 on the sales order entry it gives me a different price.
Attachments
inventory-details.PNG
Inventory Details
sell-price.PNG
Sell Price
price-selection.PNG
Price Selection Box. No matter which item i select the price is never what i selected.
bretto36
I'm new here
I'm new here
 
Posts: 5
Joined: Wed Apr 29, 2015 9:50 am

Re: Sales Order XML Import Overrides Price

Postby bretto36 » Mon Jan 30, 2017 10:01 am

Ok so in my xml if i send back just

<PriceExGst>20.000000</PriceExGst>

it appears to work fine. But if i send back

<DiscountedPrice>20.000000</DiscountedPrice>

It doesn't work correctly.

If i send back both it doesn't work correctly either

Can you think of any issues that would be caused if i changed our default sales order to use PriceExGst instead of DiscountedPrice. (I'm from WebNinja would be changing it for a decent number of customers)
bretto36
I'm new here
I'm new here
 
Posts: 5
Joined: Wed Apr 29, 2015 9:50 am

Re: Sales Order XML Import Overrides Price  Topic is solved

Postby Mike.Sheen » Fri Feb 03, 2017 12:36 pm

Hi Bretto36,

I've tested against 7.00.157.00 now with the sample file I provided earlier and the price comes in at $20.00.

I am suspecting now there are other customisations in the database you are testing with that are affecting the price.

Using PriceExGst might work for your affected database, but not another customer. In my tests, providing PriceExGst in the XML but NOT DiscountedPrice caused the price to not be set correctly.

Did you find the same behaviour using standard Jiwa demo data and my supplied test file?
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Jiwa Shihan
Jiwa Shihan
 
Posts: 1447
Joined: Tue Feb 12, 2008 10:12 am
Location: North Sydney
Topics Solved: 486


Return to Core Product Support

Who is online

Users browsing this forum: No registered users and 1 guest

cron