mirror of
https://github.com/lnbits/lnbits.git
synced 2025-09-28 21:02:31 +02:00
fix: last_payment on userlist was broken (#2796)
* fix: last_payment on userlist was broken
This commit is contained in:
2
lnbits/static/bundle.min.js
vendored
2
lnbits/static/bundle.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -104,6 +104,9 @@ window.app = Vue.createApp({
|
||||
},
|
||||
|
||||
methods: {
|
||||
formatDate(dateString) {
|
||||
return LNbits.utils.formatDateString(dateString)
|
||||
},
|
||||
async fetchAudit(props) {
|
||||
try {
|
||||
const params = LNbits.utils.prepareFilterQuery(this.auditTable, props)
|
||||
@@ -198,9 +201,6 @@ window.app = Vue.createApp({
|
||||
this.auditDetailsDialog.data = JSON.stringify(details, null, 4)
|
||||
this.auditDetailsDialog.show = true
|
||||
},
|
||||
formatDate: function (value) {
|
||||
return Quasar.date.formatDate(new Date(value), 'YYYY-MM-DD HH:mm')
|
||||
},
|
||||
shortify(value) {
|
||||
valueLength = (value || '').length
|
||||
if (valueLength <= 10) {
|
||||
|
@@ -1,4 +1,5 @@
|
||||
window.LOCALE = 'en'
|
||||
window.dateFormat = 'YYYY-MM-DD HH:mm'
|
||||
window.i18n = new VueI18n.createI18n({
|
||||
locale: window.LOCALE,
|
||||
fallbackLocale: window.LOCALE,
|
||||
@@ -274,11 +275,11 @@ window.LNbits = {
|
||||
fiat_currency: data.fiat_currency
|
||||
}
|
||||
|
||||
obj.date = Quasar.date.formatDate(new Date(obj.time), 'YYYY-MM-DD HH:mm')
|
||||
obj.date = Quasar.date.formatDate(new Date(obj.time), window.dateFormat)
|
||||
obj.dateFrom = moment(obj.date).fromNow()
|
||||
obj.expirydate = Quasar.date.formatDate(
|
||||
new Date(obj.expiry),
|
||||
'YYYY-MM-DD HH:mm'
|
||||
window.dateFormat
|
||||
)
|
||||
obj.expirydateFrom = moment(obj.expirydate).fromNow()
|
||||
obj.msat = obj.amount
|
||||
@@ -322,12 +323,15 @@ window.LNbits = {
|
||||
.join('')
|
||||
return hashHex
|
||||
},
|
||||
formatDate: function (timestamp) {
|
||||
formatDate(timestamp) {
|
||||
return Quasar.date.formatDate(
|
||||
new Date(timestamp * 1000),
|
||||
'YYYY-MM-DD HH:mm'
|
||||
window.dateFormat
|
||||
)
|
||||
},
|
||||
formatDateString(isoDateString) {
|
||||
return Quasar.date.formatDate(new Date(isoDateString), window.dateFormat)
|
||||
},
|
||||
formatCurrency: function (value, currency) {
|
||||
return new Intl.NumberFormat(window.LOCALE, {
|
||||
style: 'currency',
|
||||
|
@@ -248,10 +248,7 @@ window.app.component('lnbits-date', {
|
||||
props: ['ts'],
|
||||
computed: {
|
||||
date: function () {
|
||||
return Quasar.date.formatDate(
|
||||
new Date(this.ts * 1000),
|
||||
'YYYY-MM-DD HH:mm'
|
||||
)
|
||||
return LNbits.utils.formatDate(this.ts)
|
||||
},
|
||||
dateFrom: function () {
|
||||
return moment(this.date).fromNow()
|
||||
|
@@ -172,8 +172,8 @@ window.app = Vue.createApp({
|
||||
},
|
||||
|
||||
methods: {
|
||||
formatDate: function (value) {
|
||||
return LNbits.utils.formatDate(value)
|
||||
formatDate(date) {
|
||||
return LNbits.utils.formatDateString(date)
|
||||
},
|
||||
formatSat: function (value) {
|
||||
return LNbits.utils.formatSat(Math.floor(value / 1000))
|
||||
|
Reference in New Issue
Block a user