2022-06-29 19:46:41 -04:00
|
|
|
|
using Bit.Core.Entities;
|
2020-01-20 08:53:09 -05:00
|
|
|
|
using Bit.Core.Enums;
|
2020-01-06 14:27:16 -05:00
|
|
|
|
|
2022-08-29 15:53:48 -04:00
|
|
|
|
namespace Bit.Core.Repositories
|
2020-01-06 14:27:16 -05:00
|
|
|
|
{
|
2022-08-29 15:53:48 -04:00
|
|
|
|
public interface IPolicyRepository : IRepository<Policy, Guid>
|
|
|
|
|
|
{
|
|
|
|
|
|
Task<Policy> GetByOrganizationIdTypeAsync(Guid organizationId, PolicyType type);
|
|
|
|
|
|
Task<ICollection<Policy>> GetManyByOrganizationIdAsync(Guid organizationId);
|
|
|
|
|
|
Task<ICollection<Policy>> GetManyByUserIdAsync(Guid userId);
|
|
|
|
|
|
Task<ICollection<Policy>> GetManyByTypeApplicableToUserIdAsync(Guid userId, PolicyType policyType,
|
|
|
|
|
|
OrganizationUserStatusType minStatus = OrganizationUserStatusType.Accepted);
|
|
|
|
|
|
Task<int> GetCountByTypeApplicableToUserIdAsync(Guid userId, PolicyType policyType,
|
|
|
|
|
|
OrganizationUserStatusType minStatus = OrganizationUserStatusType.Accepted);
|
|
|
|
|
|
}
|
2020-01-06 14:27:16 -05:00
|
|
|
|
}
|