Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

manipulate invoice counter #1673

Closed
BeckeBauer opened this issue Apr 29, 2020 · 5 comments · Fixed by #1836
Closed

manipulate invoice counter #1673

BeckeBauer opened this issue Apr 29, 2020 · 5 comments · Fixed by #1836

Comments

@BeckeBauer
Copy link
Contributor

Is there a way to manipulate the invoice counter in a way that it does not start from 1?

Practical application: New user installs Kimai in June; until then, the user has already issued 30 invoices and therefore wants to have the counter start at 31 (or the feature is introduced during the year and in order to use it in the current calendar year, the counter would need to be modified so that it starts with a higher number than 1)

@plutocrat
Copy link

I'm migrating to Kimai (from the dying Hamster app). My invoice number system is already in the hundreds. I'd like this ability, even if its only in the form {c+234} which would add 234 onto the base number. An invoice_base_number_adjustment=234 in some config file would be even better.

@kevinpapst kevinpapst added this to the 1.10 milestone Jun 2, 2020
@plutocrat
Copy link

I also tried manipulating the invoice number in the database but that didn't work, so it seems to get the invoice number you're using count() in the database. Maybe grabbing the last invoice number and adding one might work instead?

@kevinpapst
Copy link
Member

kevinpapst commented Jul 6, 2020

This method calculates the invoice number:
https://github.com/kevinpapst/kimai2/blob/master/src/Invoice/NumberGenerator/ConfigurableNumberGenerator.php#L57

I think there should be another case in this if to support the + character.

@kevinpapst
Copy link
Member

Will be available in 1.10, see #1836

@github-actions
Copy link

github-actions bot commented Oct 9, 2021

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. If you use Kimai on a daily basis, please consider donating to support further development of Kimai.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants