Skip to content

Check invoice balance before rendering QR code in web view#1175

Merged
nielsdrost7 merged 1 commit intoInvoicePlane:developmentfrom
idressos:invoice-web-view-paid-qr-fix
Jan 1, 2025
Merged

Check invoice balance before rendering QR code in web view#1175
nielsdrost7 merged 1 commit intoInvoicePlane:developmentfrom
idressos:invoice-web-view-paid-qr-fix

Conversation

@idressos
Copy link
Copy Markdown
Contributor

Description

In the default invoice web template, if the invoice is paid, a PHP error is rendered in place of the QR code.
This happens because the invoice_qrcode() function expects a balance greater than or equal to 0.01, to use as the transaction amount in the QR data.

Motivation and Context

This PR solves this issue by checking that the invoice balance is > 0 before rendering the QR code element
(similar to the default invoice PDF templates, where in the default paid template, there is no QR section).

Pull Request Checklist

  • My code follows the code formatting guidelines.
  • I have an issue ID for this pull request.
  • I selected the corresponding branch.
  • I have rebased my changes on top of the corresponding branch.

Issue Type (Please check one or more)

  • Bugfix
  • Improvement of an existing Feature
  • New Feature

@nielsdrost7
Copy link
Copy Markdown
Contributor

Thanks for the PR man!
Merged.

@nielsdrost7 nielsdrost7 merged commit 37b9e7a into InvoicePlane:development Jan 1, 2025
nielsdrost7 added a commit that referenced this pull request Aug 6, 2025
## Version 1.6.3 (final)

### Major Features & E-Invoicing

* [[IP-1268](#1268)] **E-invoicing infrastructure update** by @sudwebdesign
* [[IP-1272](#1272)] **E-invoicing enhancements** by @sudwebdesign
* [[IP-1247](#1247)] Processing e-invoices flow (and some bugfixes) for version 1.6.3 by @nielsdrost7
* [[IP-1282](#1282)] feat: Legacy calculation setup step by @pumpi
* [[IP-1281](#1281)] fix: Client overview shows wrong e-Invoicing state by @pumpi

### Changed / Improvements

* [[IP-1277](#1277)] Replace node-sass with sass by @onny
* [[IP-1261](#1261)] Guest Payment stripe flow & online_payment lang improved by @nielsdrost7
* [[IP-1178](#1178)] Add custom_fields in controllers/Settings by @sudwebdesign
* [[IP-1206](#1206)] Add report: Invoices per client by @mheiduk
* [[IP-1228](#1228)] Improve number_helper & standardize_amount (fix european format) by @sudwebdesign
* [[IP-1229](#1229)] Remove unattended standardize_amount in payments view form by @sudwebdesign
* [[IP-1241](#1241)] Add pagination to invoice and quote templates by @onny
* [[IP-1219](#1219)] Sort invoices by date instead of id by @MrKrisKrisu
* [[IP-1222](#1222)] Sort quotes by date instead of id by @sudwebdesign

### Fixed

* [[IP-1179](#1179)] Fix #fullpage-loader (Spinner) never showed after save by @sudwebdesign
* [[IP-1174](#1174)] Removed '.pdf' from Invoices.php downloads to fix issue by @HeapReaper
* [[IP-1175](#1175)] Check invoice balance before rendering QR code in web view by @idressos
* [[IP-1183](#1183)] Fix summary client delete button go to 404 (link2form) by @sudwebdesign
* [[IP-1185](#1185)] Fix styling in clients table header by @tstoeter
* [[IP-1186](#1186)] Style2class for amounts & balances (th & tr) by @sudwebdesign
* [[IP-1197](#1197)] Send email show blank page (php>=8.2) by @sudwebdesign
* [[IP-1199](#1199)] Add invoice_status case in template_helper by @sudwebdesign
* [[IP-1201](#1201)] Fix SMTP password wrong after saving settings by @sudwebdesign
* [[IP-1204](#1204)] Update template_helper.php to fix email template with custom single choice field by @LOK-Soft
* [[IP-1251](#1251)] fix: amount of the credit transfer cannot be smaller than 0.01 Euro by @mheiduk
* [[IP-1278](#1278)] Fix: Styling issues by @pumpi
* [[IP-1283](#1283)] fix: Client detail view exception by 

**Full Changelog**: v1.6.2...v1.6.3
nielsdrost7 added a commit that referenced this pull request Aug 6, 2025
### What's Changed (since v1.6.2)

#### Major Features & E-Invoicing

* [[IP-1268](#1268)] **E-invoicing infrastructure update** by @sudwebdesign
* [[IP-1272](#1272)] **E-invoicing enhancements** by @sudwebdesign
* [[IP-1247](#1247)] Processing e-invoices flow (and some bugfixes) for version 1.6.3 by @nielsdrost7
* [[IP-1282](#1282)] feat: Legacy calculation setup step by @pumpi
* [[IP-1281](#1281)] fix: Client overview shows wrong e-Invoicing state by @pumpi

#### Changed / Improvements

* [[IP-1277](#1277)] Replace node-sass with sass by @onny
* [[IP-1261](#1261)] Guest Payment stripe flow & online_payment lang improved by @nielsdrost7
* [[IP-1178](#1178)] Add custom_fields in controllers/Settings by @sudwebdesign
* [[IP-1206](#1206)] Add report: Invoices per client by @mheiduk
* [[IP-1228](#1228)] Improve number_helper & standardize_amount (fix european format) by @sudwebdesign
* [[IP-1229](#1229)] Remove unattended standardize_amount in payments view form by @sudwebdesign
* [[IP-1241](#1241)] Add pagination to invoice and quote templates by @onny
* [[IP-1219](#1219)] Sort invoices by date instead of id by @MrKrisKrisu
* [[IP-1222](#1222)] Sort quotes by date instead of id by @sudwebdesign

#### Fixed

* [[IP-1179](#1179)] Fix #fullpage-loader (Spinner) never showed after save by @sudwebdesign
* [[IP-1174](#1174)] Removed '.pdf' from Invoices.php downloads to fix issue by @HeapReaper
* [[IP-1175](#1175)] Check invoice balance before rendering QR code in web view by @idressos
* [[IP-1183](#1183)] Fix summary client delete button go to 404 (link2form) by @sudwebdesign
* [[IP-1185](#1185)] Fix styling in clients table header by @tstoeter
* [[IP-1186](#1186)] Style2class for amounts & balances (th & tr) by @sudwebdesign
* [[IP-1197](#1197)] Send email show blank page (php>=8.2) by @sudwebdesign
* [[IP-1199](#1199)] Add invoice_status case in template_helper by @sudwebdesign
* [[IP-1201](#1201)] Fix SMTP password wrong after saving settings by @sudwebdesign
* [[IP-1204](#1204)] Update template_helper.php to fix email template with custom single choice field by @LOK-Soft
* [[IP-1251](#1251)] fix: amount of the credit transfer cannot be smaller than 0.01 Euro by @mheiduk
* [[IP-1278](#1278)] Fix: Styling issues by @pumpi
* [[IP-1283](#1283)] fix: Client detail view exception by

**Full Changelog**: v1.6.2...v1.6.3
@nielsdrost7
Copy link
Copy Markdown
Contributor

Solved by creating and releasing version 1.6.3

ThierryHFR pushed a commit to ThierryHFR/InvoicePlane that referenced this pull request Dec 21, 2025
* [[IP-1268](InvoicePlane#1268)] **E-invoicing infrastructure update** by @sudwebdesign
* [[IP-1272](InvoicePlane#1272)] **E-invoicing enhancements** by @sudwebdesign
* [[IP-1247](InvoicePlane#1247)] Processing e-invoices flow (and some bugfixes) for version 1.6.3 by @nielsdrost7
* [[IP-1282](InvoicePlane#1282)] feat: Legacy calculation setup step by @pumpi
* [[IP-1281](InvoicePlane#1281)] fix: Client overview shows wrong e-Invoicing state by @pumpi

* [[IP-1277](InvoicePlane#1277)] Replace node-sass with sass by @onny
* [[IP-1261](InvoicePlane#1261)] Guest Payment stripe flow & online_payment lang improved by @nielsdrost7
* [[IP-1178](InvoicePlane#1178)] Add custom_fields in controllers/Settings by @sudwebdesign
* [[IP-1206](InvoicePlane#1206)] Add report: Invoices per client by @mheiduk
* [[IP-1228](InvoicePlane#1228)] Improve number_helper & standardize_amount (fix european format) by @sudwebdesign
* [[IP-1229](InvoicePlane#1229)] Remove unattended standardize_amount in payments view form by @sudwebdesign
* [[IP-1241](InvoicePlane#1241)] Add pagination to invoice and quote templates by @onny
* [[IP-1219](InvoicePlane#1219)] Sort invoices by date instead of id by @MrKrisKrisu
* [[IP-1222](InvoicePlane#1222)] Sort quotes by date instead of id by @sudwebdesign

* [[IP-1179](InvoicePlane#1179)] Fix #fullpage-loader (Spinner) never showed after save by @sudwebdesign
* [[IP-1174](InvoicePlane#1174)] Removed '.pdf' from Invoices.php downloads to fix issue by @HeapReaper
* [[IP-1175](InvoicePlane#1175)] Check invoice balance before rendering QR code in web view by @idressos
* [[IP-1183](InvoicePlane#1183)] Fix summary client delete button go to 404 (link2form) by @sudwebdesign
* [[IP-1185](InvoicePlane#1185)] Fix styling in clients table header by @tstoeter
* [[IP-1186](InvoicePlane#1186)] Style2class for amounts & balances (th & tr) by @sudwebdesign
* [[IP-1197](InvoicePlane#1197)] Send email show blank page (php>=8.2) by @sudwebdesign
* [[IP-1199](InvoicePlane#1199)] Add invoice_status case in template_helper by @sudwebdesign
* [[IP-1201](InvoicePlane#1201)] Fix SMTP password wrong after saving settings by @sudwebdesign
* [[IP-1204](InvoicePlane#1204)] Update template_helper.php to fix email template with custom single choice field by @LOK-Soft
* [[IP-1251](InvoicePlane#1251)] fix: amount of the credit transfer cannot be smaller than 0.01 Euro by @mheiduk
* [[IP-1278](InvoicePlane#1278)] Fix: Styling issues by @pumpi
* [[IP-1283](InvoicePlane#1283)] fix: Client detail view exception by

**Full Changelog**: InvoicePlane/InvoicePlane@v1.6.2...v1.6.3
ThierryHFR pushed a commit to ThierryHFR/InvoicePlane that referenced this pull request Dec 21, 2025
### What's Changed (since v1.6.2)

#### Major Features & E-Invoicing

* [[IP-1268](InvoicePlane#1268)] **E-invoicing infrastructure update** by @sudwebdesign
* [[IP-1272](InvoicePlane#1272)] **E-invoicing enhancements** by @sudwebdesign
* [[IP-1247](InvoicePlane#1247)] Processing e-invoices flow (and some bugfixes) for version 1.6.3 by @nielsdrost7
* [[IP-1282](InvoicePlane#1282)] feat: Legacy calculation setup step by @pumpi
* [[IP-1281](InvoicePlane#1281)] fix: Client overview shows wrong e-Invoicing state by @pumpi

#### Changed / Improvements

* [[IP-1277](InvoicePlane#1277)] Replace node-sass with sass by @onny
* [[IP-1261](InvoicePlane#1261)] Guest Payment stripe flow & online_payment lang improved by @nielsdrost7
* [[IP-1178](InvoicePlane#1178)] Add custom_fields in controllers/Settings by @sudwebdesign
* [[IP-1206](InvoicePlane#1206)] Add report: Invoices per client by @mheiduk
* [[IP-1228](InvoicePlane#1228)] Improve number_helper & standardize_amount (fix european format) by @sudwebdesign
* [[IP-1229](InvoicePlane#1229)] Remove unattended standardize_amount in payments view form by @sudwebdesign
* [[IP-1241](InvoicePlane#1241)] Add pagination to invoice and quote templates by @onny
* [[IP-1219](InvoicePlane#1219)] Sort invoices by date instead of id by @MrKrisKrisu
* [[IP-1222](InvoicePlane#1222)] Sort quotes by date instead of id by @sudwebdesign

#### Fixed

* [[IP-1179](InvoicePlane#1179)] Fix #fullpage-loader (Spinner) never showed after save by @sudwebdesign
* [[IP-1174](InvoicePlane#1174)] Removed '.pdf' from Invoices.php downloads to fix issue by @HeapReaper
* [[IP-1175](InvoicePlane#1175)] Check invoice balance before rendering QR code in web view by @idressos
* [[IP-1183](InvoicePlane#1183)] Fix summary client delete button go to 404 (link2form) by @sudwebdesign
* [[IP-1185](InvoicePlane#1185)] Fix styling in clients table header by @tstoeter
* [[IP-1186](InvoicePlane#1186)] Style2class for amounts & balances (th & tr) by @sudwebdesign
* [[IP-1197](InvoicePlane#1197)] Send email show blank page (php>=8.2) by @sudwebdesign
* [[IP-1199](InvoicePlane#1199)] Add invoice_status case in template_helper by @sudwebdesign
* [[IP-1201](InvoicePlane#1201)] Fix SMTP password wrong after saving settings by @sudwebdesign
* [[IP-1204](InvoicePlane#1204)] Update template_helper.php to fix email template with custom single choice field by @LOK-Soft
* [[IP-1251](InvoicePlane#1251)] fix: amount of the credit transfer cannot be smaller than 0.01 Euro by @mheiduk
* [[IP-1278](InvoicePlane#1278)] Fix: Styling issues by @pumpi
* [[IP-1283](InvoicePlane#1283)] fix: Client detail view exception by

**Full Changelog**: InvoicePlane/InvoicePlane@v1.6.2...v1.6.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants