| ||||||||||
![]() |
Shopping cart software Solutions for online shops and malls | |||||||||
![]() |
![]() |
|
X-Cart Home | ![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
Product price decimal places | |||
![]() |
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
![]() I have a project that requires pricing on producs to go to 4 decimal places. Example: $ .2911. I have changed the db to allow 4 decimal places for xcart_prices. I also changed the precision rounding to a 4 (I hard coded it for now) in the func_format_number function. Still my wholesale prices list still shows 2 decimal places. Large volume orders, 10000 items is causing the pricing to sway over 5% with this rounding issue. Any help would be appreciated.
return number_format(round((double)$price + 0.00000000001, 4), $precision, $decimal_delim, $thousand_delim);
__________________
4.4.3 Gold |
|||||||
#2
|
|||||||
|
|||||||
![]() Bump.. anything on this?
__________________
4.4.3 Gold |
|||||||
#3
|
|||||||
|
|||||||
![]() Ok, all I need at this point is for the wholesale prices variants module to save the prices entered with 4 decimals. If I enter .1722, it continues to round the number and save (.1700) to the database. I have changed all db references to prices to 12,4. Any help would be appreciated, I cant find out where the prices entered in the admin are being changed!!
__________________
4.4.3 Gold |
|||||||
#4
|
|||||||||
|
|||||||||
![]() You have to look at the php script that processes the product/variants modify page how the numbers are modified
__________________
Steve Stoyanov CFLSystems.com Web Development |
|||||||||
#5
|
|||||||
|
|||||||
![]() I'm sorry but what part of that answer was helpful? I know what needs to be looked at. I was hoping the experts would directly me to what needs to be modified. half the places in xcart use ,2 for rounding hardcoded and the other half pulls the number from the 'num_format' field in the config db.
__________________
4.4.3 Gold |
|||||||
#6
|
|||||||||
|
|||||||||
![]() The answer was aimed to help you were to look for how the data is saved in db. Aparently you are looking for a complete mod what to modify and how to modify it... I suggest to post your question in the professional help section of the forum
__________________
Steve Stoyanov CFLSystems.com Web Development |
|||||||||
|
|||
X-Cart forums © 2001-2020
|