Which price value to set on non-stock item.  Topic is solved

Discussions relating to plugin development, and the Jiwa API.

Which price value to set on non-stock item.

Postby pricerc » Thu May 05, 2022 3:37 pm

I've added non-stock item for a surcharge that is dependent on the value of all the other lines on the order.

When I add the line in, I can just set the SellPriceExGST and the cost to the same, and that's fine.

Which value do I update if I want to change the price because the order has changed?

If I just change SellPriceExGST, it applies a discount instead of changing the price?
/Ryan

ERP Consultant,
Advanced ERP Limited, NZ
https://aerp.co.nz
User avatar
pricerc
Senpai
Senpai
 
Posts: 504
Joined: Mon Aug 10, 2009 12:22 pm
Location: Auckland, NZ
Topics Solved: 20

Re: Which price value to set on non-stock item.  Topic is solved

Postby SBarnes » Thu May 05, 2022 5:41 pm

Hi Ryan

The code below is how I set the price on the line and avoid Jiwa trying to apply its prcing

Code: Select all
                            salesorder.SalesOrderLines[(KeyToGetBackHere as string)].FixPrice = true;
                            salesorder.SalesOrderLines[(KeyToGetBackHere as string)].FixSellPrice = true;
                            salesorder.SalesOrderLines[(KeyToGetBackHere as string)].DiscountedPrice = (decimal)DiscountValue;
Regards
Stuart Barnes
SBarnes
Shihan
Shihan
 
Posts: 1619
Joined: Fri Aug 15, 2008 3:27 pm
Topics Solved: 175


Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 19 guests