mirror of
https://github.com/zoriya/Kyoo.git
synced 2026-05-30 19:05:16 -04:00
Updating the search api
This commit is contained in:
@@ -292,6 +292,26 @@ namespace Kyoo.Controllers
|
||||
Expression<Func<Library, object>> sort,
|
||||
Pagination limit = default
|
||||
) => GetLibrariesFromCollection(slug, where, new Sort<Library>(sort), limit);
|
||||
|
||||
Task<ICollection<ShowRole>> GetRolesFromPeople(int showID,
|
||||
Expression<Func<ShowRole, bool>> where = null,
|
||||
Sort<ShowRole> sort = default,
|
||||
Pagination limit = default);
|
||||
Task<ICollection<ShowRole>> GetRolesFromPeople(int showID,
|
||||
[Optional] Expression<Func<ShowRole, bool>> where,
|
||||
Expression<Func<ShowRole, object>> sort,
|
||||
Pagination limit = default
|
||||
) => GetRolesFromPeople(showID, where, new Sort<ShowRole>(sort), limit);
|
||||
|
||||
Task<ICollection<ShowRole>> GetRolesFromPeople(string showSlug,
|
||||
Expression<Func<ShowRole, bool>> where = null,
|
||||
Sort<ShowRole> sort = default,
|
||||
Pagination limit = default);
|
||||
Task<ICollection<ShowRole>> GetRolesFromPeople(string showSlug,
|
||||
[Optional] Expression<Func<ShowRole, bool>> where,
|
||||
Expression<Func<ShowRole, object>> sort,
|
||||
Pagination limit = default
|
||||
) => GetRolesFromPeople(showSlug, where, new Sort<ShowRole>(sort), limit);
|
||||
|
||||
|
||||
// Helpers
|
||||
|
||||
@@ -395,6 +395,26 @@ namespace Kyoo.Controllers
|
||||
Expression<Func<PeopleLink, object>> sort,
|
||||
Pagination limit = default
|
||||
) => GetFromShow(showSlug, where, new Sort<PeopleLink>(sort), limit);
|
||||
|
||||
Task<ICollection<ShowRole>> GetFromPeople(int showID,
|
||||
Expression<Func<ShowRole, bool>> where = null,
|
||||
Sort<ShowRole> sort = default,
|
||||
Pagination limit = default);
|
||||
Task<ICollection<ShowRole>> GetFromPeople(int showID,
|
||||
[Optional] Expression<Func<ShowRole, bool>> where,
|
||||
Expression<Func<ShowRole, object>> sort,
|
||||
Pagination limit = default
|
||||
) => GetFromPeople(showID, where, new Sort<ShowRole>(sort), limit);
|
||||
|
||||
Task<ICollection<ShowRole>> GetFromPeople(string showSlug,
|
||||
Expression<Func<ShowRole, bool>> where = null,
|
||||
Sort<ShowRole> sort = default,
|
||||
Pagination limit = default);
|
||||
Task<ICollection<ShowRole>> GetFromPeople(string showSlug,
|
||||
[Optional] Expression<Func<ShowRole, bool>> where,
|
||||
Expression<Func<ShowRole, object>> sort,
|
||||
Pagination limit = default
|
||||
) => GetFromPeople(showSlug, where, new Sort<ShowRole>(sort), limit);
|
||||
}
|
||||
public interface IProviderRepository : IRepository<ProviderID> {}
|
||||
}
|
||||
@@ -411,6 +411,22 @@ namespace Kyoo.Controllers
|
||||
{
|
||||
return LibraryRepository.GetFromCollection(slug, where, sort, limit);
|
||||
}
|
||||
|
||||
public Task<ICollection<ShowRole>> GetRolesFromPeople(int id,
|
||||
Expression<Func<ShowRole, bool>> where = null,
|
||||
Sort<ShowRole> sort = default,
|
||||
Pagination limit = default)
|
||||
{
|
||||
return PeopleRepository.GetFromPeople(id, where, sort, limit);
|
||||
}
|
||||
|
||||
public Task<ICollection<ShowRole>> GetRolesFromPeople(string slug,
|
||||
Expression<Func<ShowRole, bool>> where = null,
|
||||
Sort<ShowRole> sort = default,
|
||||
Pagination limit = default)
|
||||
{
|
||||
return PeopleRepository.GetFromPeople(slug, where, sort, limit);
|
||||
}
|
||||
|
||||
public Task AddShowLink(int showID, int? libraryID, int? collectionID)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user