save label invoice string

This commit is contained in:
thomasv 2012-11-29 16:40:05 +01:00
parent a7a60ceaeb
commit a01819fa0a
1 changed files with 3 additions and 2 deletions

View File

@ -531,7 +531,7 @@ class ElectrumWindow(QMainWindow):
return
try:
amount = int( Decimal( unicode(text)) * 100000000 )
amount = int( Decimal(text) * 100000000 )
item.setText(3,format_satoshis(amount,False, self.wallet.num_zeros))
except:
amount = self.wallet.requested_amounts.get(address)
@ -544,8 +544,9 @@ class ElectrumWindow(QMainWindow):
self.wallet.requested_amounts[address] = amount
label = self.wallet.labels.get(address)
if not label:
if label is None:
label = 'invoice %04d'%(index+1)
self.wallet.labels[address] = label
self.update_receive_item(self.receive_list.currentItem())
if self.qr_window: