Generated Numbers issue in new year

I have been using invoice ninja for a few years, and it generally works great. But since the beginning of this year 2024 there seems to be a change where the invoice numbers generate in a different way.

I have several groups with different settings for VAT numbers. Those also have different words added to the end of the invoice numbers, for example: OSS-GOODS. This numbering worked fine for the whole year 2023.

In 2023 the invoices were numbered as follows:
2023-0001
2023-0002-OSS-GOODS
2023-0003
2023-0004-OSS-GOODS
2023-0005-OSS-DIGITAL
etc.

But in 2024 the automatic numbering has changed
2024-0001
2024-0002
2024-0003
2024-0001-OSS-DIGITAL
2024-0001-OSS-GOODS
2024-0002-OSS-GOODS
etc.

I would actually like to go on as in 2023, not sure how to change it.

Hi,

Is it possible the ‘reset counter’ option is enabled on Settings > Generated Numbers?

Hi Hillel, thank you for your reply.

Yes the reset counter is active. I like the invoices to start with 0001 again in the New Year.

However the order in which invoices are generated is very different in 2024 compared to 2023. For example there are three different 0001 invoices in 2024, also after 0003.

Understood, I suggest sending an email to contact@invoiceninja.com.

Hi,

I have explained it 3-4 times to support but they haven’t replied for over a week now.

The issue here is that tax law requires consistency in the way I number invoices. I am still hoping that ninja will work for that. Some explanation of why this issue is happening would really help.

What value do you have set for the pattern?

The main setting is {$year}-{$counter}

Then here are some examples for the groups:
{$year}-{$counter}-OSS-DIGITAL
{$year}-{$counter}-OSS-GOODS

@david do you have any suggestions?

I’ve had a look into this, i believe you want to use the single company counter to increment all the counters whilst using different patterns across groups.

I’ve tested this locally and it appears to be working for me. One thing you may want to try is disabling the counter reset option on your group level settings as this may be impacting.

David, thank you so much for your help! I’ve disabled the counter resets within the groups and all is working well now. :slight_smile:

Being able to solve this saved my books from chaos.