InvoicePlane 1.5.4 released

A new release of the InvoicePlane application is available: v1.5.4
You can download the latest version from the InvoicePlane website.

Update Guide | Changelog


This is a small release with a couple of fixes for the latest versions of InvoicePlane.

If you want to know more about InvoicePlane 1.5 please visit the original topic.

Special thanks to @musa for his bug fixes and improvements! Also thanks to cjsewell, Tobias Hüske and @YeyDev for their help.


:beetle: Known bugs in version 1.5.4

  • Import not working properly (IP-510)
3 Likes

@Kovah just trying to look at the changelog but I’m getting an error page, no further information is displayed.

1 Like

It would be great to add a Changelog file to the github repo.

Thank you for your updates… but still I’m getting the same issue in cron, how do I test the cron files for recurred invoices?

I’m following https://wiki.invoiceplane.com/en/1.5/help/setup_cron it alwats giving a blank page, so I don’t know if it works or there are errors.

Suggest: Is it possible to show “No invoices generate” when executing the wget -O - http://yoursite.com/invoices/cron/recur/your-cron-key via shell because the output posted into buffer >/dev/null 2>&1 when executing via cron, with this changes the user can prove that the cron is set as well.

Regards

Changelog is available again

Cron should output a blank page. Check your invoices to see if recurring ones were generated correctly. Please post any further questions to this topic: Errors with recurring invoices

I have updated to 1.5.4 without any errors, but keep getting these error (the boxes are actually square brackets…)

Fatal error: Cannot use for reading in /usr/share/invoiceplane/application/modules/custom_fields/models/Mdl_custom_fields.php on line 257

A PHP Error was encountered
Severity: Compile Error
Message: Cannot use for reading
Filename: models/Mdl_custom_fields.php
Line Number: 257
Backtrace:

OS is Debian Jessie / 8.9

What’s wrong here ?

Thanks for the new version, in case it is of use to others this is how one upgrade went… and there is a problem with PayPal Express that I don’t know how to fix at the end…

I did a fresh install and it worked without a problem, I then imported a database from a 1.4.x site and copied the /uploads and re-ran the installed to update the database and everything seemed fine until I tried to send a email when I got:

An Error Was Encountered

Unable to load the requested class: Zugferdxml

So I turned off that option in settings and then when trying to send an email I got:

An Error Was Encountered

Unable to load the requested file: invoice_templates/pdf/.php

Looking in application/views/invoice_templates/pdf on the old server there was a custom template, so I copied that over and tried again and I got:

An Error Was Encountered

The action you have requested is not allowed.

So I went through the settings and selected the default templates rather than the customised one I was using with 1.4.x and that solved this issue.

I then re-entered the PayPay Express settings and this has thrown up the only issue I can’t see how to solve — there are now form fields for card payments.

These fields are not needed and shouldn’t be there — if you complete them and then click “Pay Now” you get the same page at PayPal as you get when you don’t complete them — a page asking for you to login or enter your card details.

Any suggestions how to remove these form fields?

See this thread for more information about the credit card form for PayPal: Guest Payment showing a Credit Card form

1 Like

That’s perfect, thanks!

Hej @peterbeck,

have the exact same issue, updated directly from 1.5.3, our OS is Debian Jessie 8.9 as well. In the browser (chrome) we get a “ERROR 324 (net::ERR_EMPTY_RESPONSE)”.

The Invoiceplane Debug-Log says:

“Compile Error --> Cannot use for reading Mdl_custom_fields.php 257”

The Apache-Log says:

[Mon Sep 04 12:59:57.909855 2017] [:error] [pid 16324] [client ***:63726] PHP Fatal error: Cannot use “” for reading in ***/invoiceplane/application/modules/custom_fields/models/Mdl_custom_fields.php on line 257

[Mon Sep 04 12:59:58.718734 2017] [core:notice] [pid 12776] AH00052: child pid 16324 exit signal Segmentation fault (11)

Thanks for any fix or advise!

With InvoicePlane 1.4.x you didn’t need to select a payment method for an invoice, you could just leave it at the default (bank transfer in this case) and the clients invoice URL had a working link to the payment method (in this case PayPal) so they had that option available.

With 1.5.4 it appears that unless you set the payment method on an invoice specifically to PayPal the client doesn’t get a working “Pay Now” link? And there doesn’t seem to be a way to set the default payment method?

For the InvoicePlane site in question almost everybody pays using bank transfers but some use PayPal and a tiny few use cheques and cash, if I could set the default to PayPal then all the clients would have this option, is that possible?

Or am I misunderstanding something here?

If you select “Select the Payment Method” for the Payment Method form field then everything is OK, if you leave it at the default, which in this case is “Bank Transfer” and then go to the client URL and follow the “Pay Now” link you get a error page with:

A PHP Error was encountered

Severity: Notice

Message: Undefined index:

Filename: controllers/Payment_handler.php

Line Number: 166

Backtrace:

File: /var/www/invoiceplane/application/modules/guest/controllers/Payment_handler.php
Line: 166
Function: _error_handler

File: /var/www/invoiceplane/application/modules/guest/controllers/Payment_handler.php
Line: 46
Function: initialize_gateway

File: /var/www/invoiceplane/index.php
Line: 327
Function: require_once

An uncaught Exception was encountered

Type: Omnipay\Common\Exception\RuntimeException

Message: Class ‘\Omnipay\Gateway’ not found

Filename: /var/www/invoiceplane/vendor/omnipay/common/src/Omnipay/Common/GatewayFactory.php

Line Number: 105

Backtrace:

File: /var/www/invoiceplane/vendor/omnipay/common/src/Omnipay/Omnipay.php
Line: 103
Function: call_user_func_array

File: /var/www/invoiceplane/application/modules/guest/controllers/Payment_handler.php
Line: 192
Function: __callStatic

File: /var/www/invoiceplane/application/modules/guest/controllers/Payment_handler.php
Line: 46
Function: initialize_gateway

File: /var/www/invoiceplane/index.php
Line: 327
Function: require_once

Any suggestions for what I could do here other than remembering to always manually set the Payment Method to either PayPal or “Select the Payment Method” (in this case it defaults to the first one, Bank Transfer)?

The error Cannot use [] for reading is related to PHP < 7.0.
IP is fully working without an problems while using PHP 7.0 or 7.1 but throws the error while running PHP 5.6.

The bug will be fixed within the next release. To hitfix this, open the file application/modules/custom_fields/models/Mdl_custom_fields.php and replace line 257 with the following line:

array_push($field->$field_id_fieldlabel, $custom_value->custom_values_value);

Fore reference: ticket is https://development.invoiceplane.com/browse/IP-574

This issue was already solved in pull request #538. PLEASE DO NOT OPEN NEW PULL REQUESTS!

I cannot reproduce any of your errors and the system is working fine with how it should work. There are two possible cases:

  1. An invoice has no payment method set. The payment method should only be set if you want to enforce the particular method to the customer. If not, leave it blank.
    If the invoice has no payment method set, the customer can use any enabled payment gateway.
  2. An invoice has a payment method set. This payment method will be enforced. The customer can only use payment gateways that are associated with the method, which can be done in the settings.

The main problem is that new invoices don’t default to “Select the Payment Method”, this is what I have in the database:

MariaDB [invoiceplane]> select * from ip_payment_methods;
+-------------------+---------------------+
| payment_method_id | payment_method_name |
+-------------------+---------------------+
|                 1 | Bank Transfer       |
|                 2 | Cheque              |
|                 3 | Cash                |
|                 4 | PayPal              |
+-------------------+---------------------+
4 rows in set (0.00 sec)

And this is the HTML that is generated when you create a new invoice:

<select name="payment_method" id="payment_method" class="form-control input-sm simple-select">
  <option value="0">Select the Payment Method</option>
  <option selected="selected" value="1">Bank Transfer</option>
  <option value="2">Cheque</option>
  <option value="3">Cash</option>
  <option value="4">PayPal</option>
</select>

I’d like the selected="selected" attribute to appear on either “Select the Payment Method” or “PayPal”, if the behaviour I’m seeing isn’t reproducible then perhaps it is down to me having some legacy data in the database? Any idea how the selected="selected" attribute is being set?

Maybe you should just disable the “Default Payment Method” invoice setting in the system settings. :slight_smile:

Do’h, missed that! Thanks :grinning:

OK - this seems to be working for now – THX for your work and the fast hotfix! :slight_smile:

Hi Kovah, Many thanks for this new version. My upgrade from 1.5.3 to 1.5.4 ran flawless. :smile:
I also tested the custom-fields in the e-mail template and it also works great now!