-
Notifications
You must be signed in to change notification settings - Fork 3
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
Fix/credit invoice deletion #250
Conversation
I am not really a fan of this implementation... You have added the
If you then make all service functions no longer static, you only have to initialize the service (optionally with a manager) and no longer need to wrap everything. What do you think? This is also one of the reasons why I wished to implement the |
f09c468
to
8ed9d50
Compare
b3caa12
to
1b6becf
Compare
3ed2aa6
to
c9fa5f1
Compare
Description
Fixes a bug where deleting a credit invoice would cause two transfers to be created. Also wraps most InvoiceService methods in a entity manager to make sure that errors are dealt with more gracefully.
Also, I found that the setup where you create a single Invoice for a user who has bought stuff at multiple sellers is super untransparent to the user and to the sellers and to the BAC. I have now made it throw a 501 Not Implemented until I fix the real issue.
The solution will be that we take @CodeNamedRobin his refactor of the InvoiceService which can "preview" and highligh that you are trying to invoice something for multiple sellers. The solution will be to make an invoice per seller, a bit like how bol.com does it.
Following my comment here I have decided to throw a 501 in all "edge" cases that will later be fixed but to make sure no more errors occur.
Related issues/external references
#249
Types of changes