From cf0d2ea48601d19b1a4e709d6c3b745faed5050b Mon Sep 17 00:00:00 2001 From: Moriz Wahl Date: Tue, 4 May 2021 12:59:03 +0200 Subject: [PATCH 1/2] adjust frontend to chaged made in backend (factor 10000) --- frontend/README.md | 4 ++-- frontend/src/views/KontoOverview/GddSend.vue | 1 + frontend/src/views/KontoOverview/GddTable.vue | 2 +- frontend/src/views/Layout/DashboardLayout_gdd.vue | 4 ++-- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/frontend/README.md b/frontend/README.md index 71dfcd39c..d94034c15 100755 --- a/frontend/README.md +++ b/frontend/README.md @@ -176,7 +176,7 @@ Wenn alles okay: "type": "creation|send|receive", "transaction_id": , // db id not id from blockchain "date": "", - "balance": , + "balance": , "memo": "", "pubkey": "" @@ -319,7 +319,7 @@ Wenn alles okay: "type": "creation|send|receive", "transaction_id": , // db id not id from blockchain "date": "", - "balance": , + "balance": , "memo": "", "pubkey": "" diff --git a/frontend/src/views/KontoOverview/GddSend.vue b/frontend/src/views/KontoOverview/GddSend.vue index 64e71ab39..9b0c0892c 100644 --- a/frontend/src/views/KontoOverview/GddSend.vue +++ b/frontend/src/views/KontoOverview/GddSend.vue @@ -255,6 +255,7 @@ export default { const result = await communityAPI.send( this.$store.state.session_id, this.ajaxCreateData.email, + // better to send the user's input here? this.ajaxCreateData.amount * 10000, this.ajaxCreateData.memo, this.ajaxCreateData.target_date, diff --git a/frontend/src/views/KontoOverview/GddTable.vue b/frontend/src/views/KontoOverview/GddTable.vue index e8e1f3cd3..40bb73c4c 100644 --- a/frontend/src/views/KontoOverview/GddTable.vue +++ b/frontend/src/views/KontoOverview/GddTable.vue @@ -22,7 +22,7 @@ style="color: green" >

- {{ $n(item.balance / 10000) }} + {{ $n(item.balance) }} GDD

{{ item.name }}

diff --git a/frontend/src/views/Layout/DashboardLayout_gdd.vue b/frontend/src/views/Layout/DashboardLayout_gdd.vue index 79270493a..d449dc1ac 100755 --- a/frontend/src/views/Layout/DashboardLayout_gdd.vue +++ b/frontend/src/views/Layout/DashboardLayout_gdd.vue @@ -94,7 +94,7 @@ export default { async loadBalance() { const result = await communityAPI.balance(this.$store.state.session_id) if (result.success) { - this.balance = result.result.data.balance / 10000 + this.balance = result.result.data.balance// / 10000 } else { // what to do when loading balance fails? } @@ -102,7 +102,7 @@ export default { async loadGDTBalance() { const result = await communityAPI.transactions(this.$store.state.session_id) if (result.success) { - this.GdtBalance = result.result.data.gdtSum / 10000 + this.GdtBalance = result.result.data.gdtSum// / 10000 } else { // what to do when loading balance fails? } From 5306ff3fc641157b4421b2d65bdc64de776aedc0 Mon Sep 17 00:00:00 2001 From: Moriz Wahl Date: Tue, 4 May 2021 13:31:53 +0200 Subject: [PATCH 2/2] linting --- frontend/src/views/Layout/DashboardLayout_gdd.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/views/Layout/DashboardLayout_gdd.vue b/frontend/src/views/Layout/DashboardLayout_gdd.vue index d449dc1ac..48a486171 100755 --- a/frontend/src/views/Layout/DashboardLayout_gdd.vue +++ b/frontend/src/views/Layout/DashboardLayout_gdd.vue @@ -94,7 +94,7 @@ export default { async loadBalance() { const result = await communityAPI.balance(this.$store.state.session_id) if (result.success) { - this.balance = result.result.data.balance// / 10000 + this.balance = result.result.data.balance // / 10000 } else { // what to do when loading balance fails? } @@ -102,7 +102,7 @@ export default { async loadGDTBalance() { const result = await communityAPI.transactions(this.$store.state.session_id) if (result.success) { - this.GdtBalance = result.result.data.gdtSum// / 10000 + this.GdtBalance = result.result.data.gdtSum // / 10000 } else { // what to do when loading balance fails? }