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

DeploymentsRepository - allow FindBy to filter by tenants #804

Open
wants to merge 10 commits into
base: master
Choose a base branch
from
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ public async Task<ResourceCollection<DeploymentResource>> FindBy(string[] projec
{
return await Client.List<DeploymentResource>(await Repository.Link("Deployments").ConfigureAwait(false), new { skip, take, projects = projects ?? new string[0], environments = environments ?? new string[0] }).ConfigureAwait(false);
}

public async Task<ResourceCollection<DeploymentResource>> FindBy(string[] projects, string[] environments, string[] tenants, int skip = 0, int? take = null)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I imagine this should also be added to the synchronous DeploymentRepository for consistency.

{
return await Client.List<DeploymentResource>(await Repository.Link("Deployments").ConfigureAwait(false), new { skip, take, projects = projects ?? new string[0], environments = environments ?? new string[0], tenants = tenants ?? new string[0] }).ConfigureAwait(false);
}

[Obsolete("This method is not a find all, it still requires paging. So it has been renamed to `FindBy`")]
public Task<ResourceCollection<DeploymentResource>> FindAll(string[] projects, string[] environments, int skip = 0, int? take = null)
Expand Down
Loading