Added a show more functionnality
This commit is contained in:
@@ -120,7 +120,7 @@ Artist::getByFilter(Wt::Dbo::Session& session,
|
||||
const std::vector<std::string> keywords,
|
||||
int offset, int size, bool& moreResults)
|
||||
{
|
||||
Wt::Dbo::collection<Artist::pointer> collection = getQuery(session, clusters, keywords).limit(size).offset(offset);
|
||||
Wt::Dbo::collection<Artist::pointer> collection = getQuery(session, clusters, keywords).limit(size + 1).offset(offset);
|
||||
|
||||
auto res = std::vector<pointer>(collection.begin(), collection.end());
|
||||
|
||||
|
||||
@@ -118,7 +118,7 @@ Release::getByFilter(Wt::Dbo::Session& session,
|
||||
const std::vector<std::string> keywords,
|
||||
int offset, int size, bool& moreResults)
|
||||
{
|
||||
Wt::Dbo::collection<pointer> collection = getQuery(session, clusterIds, keywords).limit(size).offset(offset);
|
||||
Wt::Dbo::collection<pointer> collection = getQuery(session, clusterIds, keywords).limit(size + 1).offset(offset);
|
||||
|
||||
auto res = std::vector<pointer>(collection.begin(), collection.end());
|
||||
|
||||
|
||||
@@ -169,7 +169,7 @@ Track::getByFilter(Wt::Dbo::Session& session,
|
||||
const std::vector<std::string> keywords,
|
||||
int offset, int size, bool& moreResults)
|
||||
{
|
||||
Wt::Dbo::collection<pointer> collection = getQuery(session, clusterIds, keywords).limit(size).offset(offset);
|
||||
Wt::Dbo::collection<pointer> collection = getQuery(session, clusterIds, keywords).limit(size + 1).offset(offset);
|
||||
|
||||
auto res = std::vector<pointer>(collection.begin(), collection.end());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user