From f64154e351bf0a5b8f3bfb5a19f49ce55509f5b5 Mon Sep 17 00:00:00 2001 From: Tilman Liero Date: Thu, 4 Aug 2016 21:04:58 +0200 Subject: [PATCH] Bugfix for amountToNumber() --- pom.xml | 2 +- src/main/resources/static/app/controllers.js | 2 +- src/main/resources/static/app/import-list.html | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/pom.xml b/pom.xml index 84ae5ac..8cebf74 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ 4.0.0 de.tilman next-transactions - 1.5.8 + 1.5.9 org.springframework.boot diff --git a/src/main/resources/static/app/controllers.js b/src/main/resources/static/app/controllers.js index 59a93bc..4c2fd01 100644 --- a/src/main/resources/static/app/controllers.js +++ b/src/main/resources/static/app/controllers.js @@ -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; } diff --git a/src/main/resources/static/app/import-list.html b/src/main/resources/static/app/import-list.html index 517bbb4..0e49a87 100644 --- a/src/main/resources/static/app/import-list.html +++ b/src/main/resources/static/app/import-list.html @@ -6,8 +6,8 @@ Wertstellung Typ - Text - Betrag + Text + Betrag Kategorie Notiz @@ -20,7 +20,7 @@ {{line[1]}} {{line[2]}} {{line[3]}} - {{line[4]}} € + {{line[4]}} €