mirror of
https://github.com/antebudimir/tempus.git
synced 2026-01-01 09:53:33 +00:00
feat: added "Recent songs" and "Random" menu items in Android Auto
This commit is contained in:
parent
14d6128df0
commit
54e988b70e
3 changed files with 103 additions and 0 deletions
|
|
@ -12,6 +12,9 @@ import java.util.List;
|
|||
|
||||
@Dao
|
||||
public interface ChronologyDao {
|
||||
@Query("SELECT * FROM chronology WHERE server == :server GROUP BY id ORDER BY timestamp DESC LIMIT :count")
|
||||
LiveData<List<Chronology>> getLastPlayed(String server, int count);
|
||||
|
||||
@Query("SELECT * FROM chronology WHERE timestamp >= :startDate AND timestamp < :endDate AND server == :server GROUP BY id ORDER BY COUNT(id) DESC LIMIT 9")
|
||||
LiveData<List<Chronology>> getAllFrom(long startDate, long endDate, String server);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue