1
0

qt: do not mutate already saved invoice after editing amount.

Also show empty an string for invoices that do not have an amount,
similar to the requests list.
This commit is contained in:
ThomasV
2023-04-04 10:36:43 +02:00
parent 479f952c9d
commit 8e3a3cefcf
2 changed files with 5 additions and 2 deletions

View File

@@ -585,6 +585,8 @@ class SendTab(QWidget, MessageBoxMixin, Logger):
text = invoice.lightning_invoice if invoice.is_lightning() else invoice.get_address()
self.payto_e._on_input_btn(text)
self.amount_e.setFocus()
# disable save button, because it would create a new invoice
self.save_button.setEnabled(False)
def do_pay_invoice(self, invoice: 'Invoice'):
if not bool(invoice.get_amount_sat()):