webshopapps / module-matrixrate

WebShopApps MatrixRates for Magento2
Open Software License 3.0
120 stars 64 forks source link

Cannot import exported .csv when from value is -1 #84

Closed JeroenVanLeusden closed 4 years ago

JeroenVanLeusden commented 4 years ago

Note that you cannot use an empty field, a weight/price/quantity value must be specified. E.g.: weight from 0 and weight to 10000.00. You can use an asterisk (*) to denote a weight/price/quantity value from -1 (which includes 0) or a weight/price/quantity to value with no maximum.

Source

Steps to reproduce

Faulty code: https://github.com/webshopapps/module-matrixrate/blob/master/src/Model/ResourceModel/Carrier/Matrixrate.php#L560 \WebShopApps\MatrixRate\Model\ResourceModel\Carrier\Matrixrate_parseDecimalValue() will parse positive numbers only.