1
0

InvoiceDialog: add balance & expired checks on invoices, add a few ln invoice fields to show

This commit is contained in:
Sander van Grieken
2022-06-29 00:14:18 +02:00
parent c79651f981
commit 71cd996379
2 changed files with 93 additions and 10 deletions

View File

@@ -47,7 +47,6 @@ Dialog {
RowLayout {
Layout.fillWidth: true
Image {
//Layout.rowSpan: 2
Layout.preferredWidth: constants.iconSizeSmall
Layout.preferredHeight: constants.iconSizeSmall
source: invoice.invoiceType == Invoice.LightningInvoice
@@ -117,6 +116,45 @@ Dialog {
wrapMode: Text.Wrap
}
Label {
visible: invoice.invoiceType == Invoice.LightningInvoice
text: qsTr('Remote Pubkey')
}
Label {
visible: invoice.invoiceType == Invoice.LightningInvoice
Layout.fillWidth: true
text: invoice.lnprops.pubkey
font.family: FixedFont
wrapMode: Text.Wrap
}
Label {
visible: invoice.invoiceType == Invoice.LightningInvoice
text: qsTr('Route via (t)')
}
Label {
visible: invoice.invoiceType == Invoice.LightningInvoice
Layout.fillWidth: true
text: invoice.lnprops.t
font.family: FixedFont
wrapMode: Text.Wrap
}
Label {
visible: invoice.invoiceType == Invoice.LightningInvoice
text: qsTr('Route via (r)')
}
Label {
visible: invoice.invoiceType == Invoice.LightningInvoice
Layout.fillWidth: true
text: invoice.lnprops.r
font.family: FixedFont
wrapMode: Text.Wrap
}
Label {
text: qsTr('Status')
}
@@ -134,6 +172,13 @@ Dialog {
Item { Layout.preferredHeight: constants.paddingLarge; Layout.preferredWidth: 1 }
InfoTextArea {
Layout.columnSpan: 2
Layout.alignment: Qt.AlignHCenter
visible: invoice.userinfo
text: invoice.userinfo
}
RowLayout {
Layout.columnSpan: 2
Layout.alignment: Qt.AlignHCenter
@@ -178,7 +223,6 @@ Dialog {
}
Item { Layout.fillHeight: true; Layout.preferredWidth: 1 }
}
Component.onCompleted: {