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

How do we implement Bulk Update in this design pattern? #55

Closed
akmalhazim opened this issue Oct 21, 2020 · 1 comment
Closed

How do we implement Bulk Update in this design pattern? #55

akmalhazim opened this issue Oct 21, 2020 · 1 comment

Comments

@akmalhazim
Copy link

Hi,
May I know if there's a way for me to use any ORM update method without fetching the models first, right now from what I can see, the current pattern only allows the repository to update a single model. Is there any pattern that allows updating a single model and bulk update in one repository?
image
Thank you

@bxcodec
Copy link
Owner

bxcodec commented Oct 26, 2020

Hi!

Actually, you can just add a bulk update on your contract. The service/Usecase layer is built based on the business need/logic. So if your application business logic needs to have a bulk update, then you just need to define it on the contract.
Also how to define the contract on the Service layer or Repository layer, I recommend reading more about SOLID principles. That's should help you a lot to define the contract functions.

I'm closing this issue as this for a personal question.

@bxcodec bxcodec closed this as completed Oct 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants