Bugfix for amountToNumber()

This commit is contained in:
2016-08-04 21:04:58 +02:00
parent 58fe6217eb
commit f64154e351
3 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
var transactionControllers = angular.module('transactionControllers', ['ngResource']);
function amountToNumber(amount) {
var number = amount.toString().replace(',', '.');
var number = amount.toString().replace('.', '').replace(',', '.');
if (number.charAt(0) !== '+' && number.charAt(0) !== '-') {
number = '-' + number;
}