2 ways works !

This commit is contained in:
poka 2020-11-15 09:22:12 +01:00
parent 7b8c0c82bc
commit 5eda07bd68
2 changed files with 6 additions and 5 deletions

View File

@ -28,7 +28,7 @@ def ProceedPaiement():
comment = str(commentEntry.get())
print("Paiement en cours ... " + recipient)
returnGen = sendGenDoc(recipient, amount, comment)
checkTXDoc(returnGen)
checkTXDoc(returnGen, recipient, amount, comment)
returnSigned = signDoc(returnGen)
sendTXDoc(returnSigned)

9
pay.py
View File

@ -62,7 +62,7 @@ def sendGenDoc(recipient, amount, comment):
# Check document
def checkTXDoc(txDoc):
def checkTXDoc(txDoc, recipient, amount, comment):
docList = txDoc.splitlines()
for i, line in enumerate(docList):
if re.search("Issuers:", line):
@ -121,9 +121,10 @@ def sendTXDoc(signedDoc):
# Execute workflow
if not graphic:
returnGen = sendGenDoc(recipient, amount, comment)
docIsOK = checkTXDoc(returnGen)
returnSigned = signDoc(returnGen)
sendTXDoc(returnSigned)
docIsOK = checkTXDoc(returnGen, recipient, amount, comment)
if docIsOK:
returnSigned = signDoc(returnGen)
sendTXDoc(returnSigned)
#print(sentTX) #For debug