change artist selection to albumartist
This commit is contained in:
parent
89f6f3a1d0
commit
f171721915
|
@ -153,7 +153,7 @@ def get_artist_albums(artist):
|
|||
Returns a list of all albums produced by the specified `artist`.
|
||||
"""
|
||||
albums = db_execute(
|
||||
"SELECT DISTINCT album FROM tracks WHERE artist = ? ORDER BY date ASC",
|
||||
"SELECT DISTINCT album FROM tracks WHERE albumartist = ? ORDER BY date ASC",
|
||||
(artist,)
|
||||
).fetchall()
|
||||
albums = [row[0] for row in albums]
|
||||
|
@ -165,7 +165,7 @@ def get_album_tracks(artist, album):
|
|||
"""
|
||||
tracks = db_execute(
|
||||
"SELECT discnumber, tracknumber, title FROM tracks "
|
||||
"WHERE artist = ? AND album = ?"
|
||||
"WHERE albumartist = ? AND album = ?"
|
||||
"ORDER BY discnumber ASC, tracknumber ASC",
|
||||
(artist, album)
|
||||
).fetchall()
|
||||
|
@ -178,7 +178,7 @@ def get_track(artist, album, discnumber, tracknumber):
|
|||
"""
|
||||
track = db_execute(
|
||||
"SELECT * FROM tracks "
|
||||
"WHERE artist = ? AND album = ? "
|
||||
"WHERE albumartist = ? AND album = ? "
|
||||
"AND discnumber = ? AND tracknumber = ?",
|
||||
(artist, album, discnumber, tracknumber)
|
||||
).fetchone()
|
||||
|
@ -198,7 +198,7 @@ def get_all_artists():
|
|||
Returns a list of all artist names.
|
||||
"""
|
||||
artists = db_execute(
|
||||
"SELECT DISTINCT albumartist FROM tracks ORDER BY artist ASC"
|
||||
"SELECT DISTINCT albumartist FROM tracks ORDER BY albumartist ASC"
|
||||
)
|
||||
artists = [row[0] for row in artists]
|
||||
return artists
|
||||
|
|
|
@ -69,7 +69,7 @@ function select_track(select) {
|
|||
|
||||
function change_track(track) {
|
||||
let params = {
|
||||
artist: track.artist,
|
||||
artist: track.albumartist,
|
||||
album: track.album,
|
||||
discnumber: track.discnumber,
|
||||
tracknumber: track.tracknumber,
|
||||
|
|
Loading…
Reference in New Issue
Block a user