diff --git a/src/main/resources/public/js/getAndAddContracts.js b/src/main/resources/public/js/getAndAddContracts.js index b3466179..172922e9 100644 --- a/src/main/resources/public/js/getAndAddContracts.js +++ b/src/main/resources/public/js/getAndAddContracts.js @@ -157,13 +157,17 @@ var projectContractsCount = -1; + " "; if (invoice.paymentTime == "null" && invoice.transactionId == "null") { status = "Active"; - if (parseFloat(invoice.totalAmount) > 0.0) { + var totalAmount = parseFloat(invoice.totalAmount.substring(0, invoice.totalAmount.length - 1)) + if (totalAmount >= 108.0) { payIcon = "" + "" + ""; } + if(totalAmount === 0.0){ + downloadLink = ""; + } } else { status = "Paid"; } diff --git a/src/main/resources/public/js/wallets.js b/src/main/resources/public/js/wallets.js index baaa0710..3b06a04c 100644 --- a/src/main/resources/public/js/wallets.js +++ b/src/main/resources/public/js/wallets.js @@ -215,9 +215,10 @@ function payInvoice(invoice, contract, payButton) { */ function newInvoiceAsTableRow(invoice) { var status = "Active" - var downloadLink = "" + var totalAmount = parseFloat(invoice.totalAmount.substring(0, invoice.totalAmount.length - 1)) + var downloadLink = totalAmount > 0.0 ? "" + "" - + ""; + + "": ""; return "" + "" + invoice.id + "" + "" + invoice.createdAt.split('T')[0] + "" +