defined fields for Transactionlist in UserSearch in Adminarea, add Localized fields and formatted fields

This commit is contained in:
elweyn 2022-01-19 14:37:49 +01:00 committed by ogerly
parent e558ec2209
commit 018bfa05d6
3 changed files with 38 additions and 3 deletions

View File

@ -1,7 +1,7 @@
<template>
<div class="component-creation-transaction-list">
{{ $t('transactionlist.title') }}
<b-table striped hover :items="items"></b-table>
<b-table striped hover :fields="fields" :items="items"></b-table>
</div>
</template>
<script>
@ -13,6 +13,29 @@ export default {
},
data() {
return {
fields: [
{
key: 'date',
label: this.$t('transactionlist.date'),
formatter: (value, key, item) => {
return this.$moment(value).format(this.$t('transactionlist.formatter'))
},
},
{ key: 'name', label: this.$t('transactionlist.community') },
{ key: 'balance', label: this.$t('transactionlist.amount') },
{ key: 'memo', label: this.$t('transactionlist.memo') },
{
key: 'decay',
label: this.$t('transactionlist.decay'),
formatter: (value, key, item) => {
if (value && value.balance >= 0) {
return value.balance
} else {
return '0'
}
},
},
],
items: [],
}
},

View File

@ -52,7 +52,13 @@
"remove": "Entfernen",
"transaction": "Transaktion",
"transactionlist": {
"title": "Alle geschöpften Transaktionen für den Nutzer"
"title": "Alle geschöpften Transaktionen für den Nutzer",
"amount":"Betrag",
"memo":"Nachricht",
"date":"Datum",
"decay":"Vergänglichkeit",
"community":"Gemeinschaft",
"formatter":"DD.MM.YYYY"
},
"unregistered_emails": "Nur unregistrierte Nutzer",
"unregister_mail": {

View File

@ -52,7 +52,13 @@
"remove": "Remove",
"transaction": "Transaction",
"transactionlist": {
"title": "All creation-transactions for the user"
"title": "All creation-transactions for the user",
"amount":"Amount",
"memo":"Message",
"date":"Date",
"decay":"Decay",
"community":"Community",
"formatter":"MM.DD.YYYY"
},
"unregistered_emails": "Only unregistered users",
"unregister_mail": {