Every bill takes number 1 (numero_progresivo_documento)

Post here if you think you have found a bug in hoteldruid or error in its documentation.

Moderator: marco

Post Reply
Posts: 1
Joined: Sun Oct 20, 2019 10:50 am

Every bill takes number 1 (numero_progresivo_documento)

Post by david »

I'm having a strange trouble: every bill created for a new booking, is numbered as 1. This happens since the number 10 bill. So for, example, a new bill, correctly been named as Factura_2019_00014_5.html.gz, have an incorrect bill number inside, as the text "Factura n. [numero_progresivo_documento] del [fecha_inicial_espannol]" will be converted on Factura n. 1 del 20-10-2019.

In conclusion, the bill number is correct on the file name, but incorrect in the text inside it. Any idea? Looking the code, both numbers are taken from the same variable "numero_progressivo_documento", so something is changing it in any part of the code.

I've never had this problem before this year. I run the last version, as it was updated on March.

Posts: 1298
Joined: Tue Jul 05, 2005 6:00 pm
Location: Roma, Italia

Re: Every bill takes number 1 (numero_progresivo_documento)

Post by marco »

thanks for reporting. This should happen only with php 7.2 or above. Will be solved in next version (should be 3.0.1), meanwhile you can open the file includes/funzioni_contratti.php and search for this line:

$num_prog_contr = "";

then replace it with:

$num_prog_contr = array();

Problems installing, configuring, upgrading?
Try the easiest way to use HotelDruid:

Post Reply