2017-05-08 14:08:44 -04:00
|
|
|
|
using System;
|
|
|
|
|
|
using Bit.Core.Models.Table;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Threading.Tasks;
|
2017-05-09 19:04:01 -04:00
|
|
|
|
using Bit.Core.Models.Data;
|
2017-05-08 14:08:44 -04:00
|
|
|
|
|
|
|
|
|
|
namespace Bit.Core.Repositories
|
|
|
|
|
|
{
|
|
|
|
|
|
public interface IGroupRepository : IRepository<Group, Guid>
|
|
|
|
|
|
{
|
2017-05-11 11:41:13 -04:00
|
|
|
|
Task<Tuple<Group, ICollection<SelectionReadOnly>>> GetByIdWithCollectionsAsync(Guid id);
|
2017-05-08 14:08:44 -04:00
|
|
|
|
Task<ICollection<Group>> GetManyByOrganizationIdAsync(Guid organizationId);
|
2017-05-11 14:52:35 -04:00
|
|
|
|
Task<ICollection<GroupUserDetails>> GetManyUserDetailsByIdAsync(Guid id);
|
2017-05-09 19:04:01 -04:00
|
|
|
|
Task<ICollection<Guid>> GetManyIdsByUserIdAsync(Guid organizationUserId);
|
2017-05-13 14:14:20 -04:00
|
|
|
|
Task<ICollection<GroupUser>> GetManyGroupUsersByOrganizationIdAsync(Guid organizationId);
|
2017-05-11 11:41:13 -04:00
|
|
|
|
Task CreateAsync(Group obj, IEnumerable<SelectionReadOnly> collections);
|
|
|
|
|
|
Task ReplaceAsync(Group obj, IEnumerable<SelectionReadOnly> collections);
|
2017-05-09 19:24:03 -04:00
|
|
|
|
Task DeleteUserAsync(Guid groupId, Guid organizationUserId);
|
2017-05-15 14:41:20 -04:00
|
|
|
|
Task UpdateUsersAsync(Guid groupId, IEnumerable<Guid> organizationUserIds);
|
2017-05-08 14:08:44 -04:00
|
|
|
|
}
|
|
|
|
|
|
}
|