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

Add GetListAsync with predicate to IReadOnlyRepository #8151

Closed
hikalkan opened this issue Mar 21, 2021 · 0 comments · Fixed by #8152
Closed

Add GetListAsync with predicate to IReadOnlyRepository #8151

hikalkan opened this issue Mar 21, 2021 · 0 comments · Fixed by #8152

Comments

@hikalkan
Copy link
Member

Here, a typical code to get a list of entities with a predicate:

var organizationMembershipsQueryable = await _organizationMembershipsRepository.GetQueryableAsync();
var query = organizationMembershipsQueryable.Where(x => x.OrganizationId == @event.OrganizationId);
var organizationMembers = await _asyncExecuter.ToListAsync(query);

It would be good if we have a GetListAsync method like;

var organizationMembers = await _organizationMembershipsRepository.GetListAsync(x => x.OrganizationId == @event.OrganizationId);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants