Removed the dedicated search view, as it is actually too limiting. Added a search field in the album/artists/tracks views. This makes search now work together with sort mode
This commit is contained in:
@@ -42,6 +42,7 @@ namespace lms::scrobbling
|
||||
db::Listen::StatsFindParameters listenFindParams;
|
||||
listenFindParams.setUser(params.user);
|
||||
listenFindParams.setClusters(params.clusters);
|
||||
listenFindParams.setKeywords(params.keywords);
|
||||
listenFindParams.setRange(params.range);
|
||||
listenFindParams.setMediaLibrary(params.library);
|
||||
listenFindParams.setArtist(params.artist);
|
||||
|
||||
@@ -59,14 +59,16 @@ namespace lms::scrobbling
|
||||
|
||||
struct FindParameters
|
||||
{
|
||||
db::UserId user;
|
||||
std::vector<db::ClusterId> clusters; // if non empty, at least one artist that belongs to these clusters
|
||||
std::optional<db::Range> range;
|
||||
db::MediaLibraryId library; // if set, match this library
|
||||
db::ArtistId artist; // if set, match this artist
|
||||
db::UserId user;
|
||||
std::vector<db::ClusterId> clusters; // if non empty, at least one artist that belongs to these clusters
|
||||
std::vector<std::string_view> keywords; // if non empty, name must match all of these keywords
|
||||
std::optional<db::Range> range;
|
||||
db::MediaLibraryId library; // if set, match this library
|
||||
db::ArtistId artist; // if set, match this artist
|
||||
|
||||
FindParameters& setUser(const db::UserId _user) { user = _user; return *this; }
|
||||
FindParameters& setClusters(std::span<const db::ClusterId> _clusters) { clusters.assign(std::cbegin(_clusters), std::cend(_clusters)); return *this; }
|
||||
FindParameters& setKeywords(const std::vector<std::string_view>& _keywords) { keywords = _keywords; return *this; }
|
||||
FindParameters& setRange(std::optional<db::Range> _range) { range = _range; return *this; }
|
||||
FindParameters& setMediaLibrary(db::MediaLibraryId _library) { library = _library; return *this; }
|
||||
FindParameters& setArtist(db::ArtistId _artist) { artist = _artist; return *this; }
|
||||
|
||||
Reference in New Issue
Block a user