kilbot / WooCommerce-POS

:bangbang: All development now at https://github.com/wcpos.
http://wcpos.com
GNU General Public License v3.0
353 stars 125 forks source link

[WCPOS-Pro] [Products List] Wrong price formatting for Variations when decimal separator set as comma "," #162

Open thomasmery opened 7 years ago

thomasmery commented 7 years ago

This is visible in the woocommerce-pos-pro Products screen when WC decimal separator is a comma ",".

image

[ in Admin ] image

[ in POS Products List Variation drawer ] image

This seems to be happening because

This does not happen when prices are of type number because the formatting function skips the cleaning process

// Return the value as-is if it's already a number:
if (typeof value === "number") return value;

To fix, either: