@@ -1383,7 +1383,7 @@ def broadcast_thread():
13831383 return False , _ ("Payment request has expired" )
13841384 status , msg = self .network .broadcast (tx )
13851385 if pr and status is True :
1386- pr . set_paid (tx .txid ())
1386+ self . invoices . set_paid (pr , tx .txid ())
13871387 self .invoices .save ()
13881388 self .payment_request = None
13891389 refund_address = self .wallet .get_receiving_addresses ()[0 ]
@@ -1621,27 +1621,18 @@ def show_pr_details(self, pr):
16211621 grid = QGridLayout ()
16221622 grid .addWidget (QLabel (_ ("Requestor" ) + ':' ), 0 , 0 )
16231623 grid .addWidget (QLabel (pr .get_requestor ()), 0 , 1 )
1624- grid .addWidget (QLabel (_ ("Expires" ) + ':' ), 1 , 0 )
1625- grid .addWidget (QLabel (format_time (pr .get_expiration_date ())), 1 , 1 )
1626- grid .addWidget (QLabel (_ ("Memo" ) + ':' ), 2 , 0 )
1627- grid .addWidget (QLabel (pr .get_memo ()), 2 , 1 )
1628- grid .addWidget (QLabel (_ ("Signature" ) + ':' ), 3 , 0 )
1629- grid .addWidget (QLabel (pr .get_verify_status ()), 3 , 1 )
1630- grid .addWidget (QLabel (_ ("Payment URL" ) + ':' ), 4 , 0 )
1631- grid .addWidget (QLabel (pr .payment_url ), 4 , 1 )
1632- grid .addWidget (QLabel (_ ("Outputs" ) + ':' ), 5 , 0 )
1633- outputs_str = '\n ' .join (map (lambda x : x [1 ] + ' ' + self .format_amount (x [2 ])+ self .base_unit (), pr .get_outputs ()))
1634- grid .addWidget (QLabel (outputs_str ), 5 , 1 )
1635- if pr .tx :
1636- grid .addWidget (QLabel (_ ("Transaction ID" ) + ':' ), 6 , 0 )
1637- l = QLineEdit (pr .tx )
1638- l .setReadOnly (True )
1639- grid .addWidget (l , 6 , 1 )
1624+ grid .addWidget (QLabel (_ ("Amount" ) + ':' ), 1 , 0 )
1625+ outputs_str = '\n ' .join (map (lambda x : self .format_amount (x [2 ])+ self .base_unit () + ' @ ' + x [1 ], pr .get_outputs ()))
1626+ grid .addWidget (QLabel (outputs_str ), 1 , 1 )
1627+ grid .addWidget (QLabel (_ ("Expires" ) + ':' ), 2 , 0 )
1628+ grid .addWidget (QLabel (format_time (pr .get_expiration_date ())), 2 , 1 )
1629+ grid .addWidget (QLabel (_ ("Memo" ) + ':' ), 3 , 0 )
1630+ grid .addWidget (QLabel (pr .get_memo ()), 3 , 1 )
1631+ grid .addWidget (QLabel (_ ("Signature" ) + ':' ), 4 , 0 )
1632+ grid .addWidget (QLabel (pr .get_verify_status ()), 4 , 1 )
16401633 vbox .addLayout (grid )
16411634 vbox .addLayout (Buttons (CloseButton (d )))
16421635 d .exec_ ()
1643- return
1644-
16451636
16461637 def do_pay_invoice (self , key ):
16471638 pr = self .invoices .get (key )
0 commit comments