feat: update to lnbits 1.0.0 (#66)

---------

Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
Co-authored-by: Tiago Vasconcelos <talvasconcelos@gmail.com>
This commit is contained in:
dni ⚡ 2024-10-25 12:02:37 +02:00 committed by GitHub
commit c7623e4c5a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
15 changed files with 1372 additions and 1278 deletions

View file

@ -1,7 +1,5 @@
/* globals Quasar, Vue, _, VueQrcode, windowMixin, LNbits, LOCALE */
Vue.component(VueQrcode.name, VueQrcode)
const locationPath = [
window.location.protocol,
'//',
@ -11,19 +9,17 @@ const locationPath = [
const mapPayLink = obj => {
obj._data = _.clone(obj)
obj.date = Quasar.utils.date.formatDate(
new Date(obj.time * 1000),
'YYYY-MM-DD HH:mm'
)
obj.date = LNbits.utils.formatDate(obj.time)
obj.amount = new Intl.NumberFormat(LOCALE).format(obj.amount)
obj.print_url = [locationPath, 'print/', obj.id].join('')
obj.pay_url = [locationPath, 'link/', obj.id].join('')
return obj
}
new Vue({
window.app = Vue.createApp({
el: '#vue',
mixins: [windowMixin],
mixins: [window.windowMixin],
computed: {
endpoint: function () {
return `/lnurlp/api/v1/settings?usr=${this.g.user.id}`
@ -240,7 +236,7 @@ new Vue({
}
},
created() {
if (this.g.user.wallets.length) {
if (this.g.user.wallets?.length) {
var getPayLinks = this.getPayLinks
getPayLinks()
this.checker = setInterval(() => {