OSCommerce Product Manager for Windows
FS#266 - Net price (taxed) miscalculated if no tax class selected.
Attached to Project:
OSCommerce Product Manager
Opened by Mario A. Valdez-Ramirez (mvaldez) - Thursday, 08 September 2005, 10:38 GMT
Last edited by Mario A. Valdez-Ramirez (mvaldez) - Sunday, 11 September 2005, 05:30 GMT
Opened by Mario A. Valdez-Ramirez (mvaldez) - Thursday, 08 September 2005, 10:38 GMT
Last edited by Mario A. Valdez-Ramirez (mvaldez) - Sunday, 11 September 2005, 05:30 GMT
|
DetailsIn the Product editing window, when adding a new product, if the tax class has not been selected the net price (price with taxes) is miscalculated.
|
This task depends upon
Closed by Mario A. Valdez-Ramirez (mvaldez)
Sunday, 11 September 2005, 05:30 GMT
Reason for closing:
Sunday, 11 September 2005, 05:30 GMT
Reason for closing:
Reviewed:
This only happens if there are no tax classes or tax rates defined. To duplicate this bug, delete all tax rates/classes and then try to create a product. The problem seems to be that the tax rates list is filled with random data.
Pending to check if the problem is in the tax-list loading routines or somewhere else.
The problem seems to be in the FNopm_GetTax function, as the default returned record has all fields empty excepting the the SumRate field. Fixing it.
We have had this kind of error before. The requesting routine does not check for the ID field of any requested record (product, currency, manufacturer, etc) and use it. The ID field is always set to 0 or -1 if there are not any matching record.
One partial solution is to always set all fields to their empty value (zero, empty string, etc). But anyway, the requesting routine has to check always for the ID value.
Pending to audit all similar procedures.
FNopm_GetCategory passed.
FNopm_GetManufacturer passed.
FNopm_GetDescriptionByID did not pass, fixed.
PRopm_GetCategory_Data passed.
FNopm_GetCurrency did not pass, fixed.
FNopm_GetProductByID did not pass, fixed.
Fixed. Closed.