-
-
Notifications
You must be signed in to change notification settings - Fork 85
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
[Enhancement] Refactor and deprecate Invoice repository class #186
Conversation
ac92058
to
c2be2c0
Compare
250d47a
to
76d3b81
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've extracted your commit with fix to a separate PR #190 to make the build green again 😃
@@ -1,3 +1,11 @@ | |||
### UPGRADE FROM 0.11.0 TO 0.11.1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
### UPGRADE FROM 0.11.0 TO 0.11.1 | |
### UPGRADE FROM 0.11.0 TO 0.12.0 |
1. The custom repository has been removed : | ||
|
||
- removed the repository class `DoctrineInvoiceRepository` and replaced by `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepository` | ||
- removed the related service `sylius_invoicing_plugin.custom_repository.invoice` use `sylius_invoicing_plugin.repository.invoice` instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- removed the related service `sylius_invoicing_plugin.custom_repository.invoice` use `sylius_invoicing_plugin.repository.invoice` instead | |
- removed the related service `sylius_invoicing_plugin.custom_repository.invoice`, use `sylius_invoicing_plugin.repository.invoice` instead |
|
||
- removed the repository class `DoctrineInvoiceRepository` and replaced by `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepository` | ||
- removed the related service `sylius_invoicing_plugin.custom_repository.invoice` use `sylius_invoicing_plugin.repository.invoice` instead | ||
- removed the related interface `InvoiceRepository` use `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepositoryInterface` instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- removed the related interface `InvoiceRepository` use `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepositoryInterface` instead | |
- removed the related interface `Sylius\InvoicingPlugin\Repository\InvoiceRepository`, use `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepositoryInterface` instead |
|
||
1. The custom repository has been removed : | ||
|
||
- removed the repository class `DoctrineInvoiceRepository` and replaced by `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepository` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- removed the repository class `DoctrineInvoiceRepository` and replaced by `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepository` | |
- removed the repository class `Sylius\InvoicingPlugin\Repository\DoctrineInvoiceRepository` and replaced by `Sylius\InvoicingPlugin\Doctrine\ORM\InvoiceRepository` |
Thanks, Francis! 🎉 |
The actual
Sylius\InvoicingPlugin\Repository\DoctrineInvoiceRepository
has been deprecated and a new class has been defined in thesrc/Doctrine/ORM
folder with a name following the entity name.The corresponding interface has been also deprecated and the new one is owning the only required method.
I propose this PR because the actual repository was not correctly used : it was an override of
sylius_invoicing_plugin.custom_repository.invoice
instead of a default value in the resource plugin configuration.