mirror of
https://github.com/krateng/maloja.git
synced 2025-04-19 01:57:37 +03:00
Add albums to the native API chart function
This commit is contained in:
parent
ec77ee6091
commit
4933932586
@ -314,7 +314,23 @@ def get_charts_tracks_external(**keys):
|
||||
"list":result
|
||||
}
|
||||
|
||||
@api.get("charts/albums")
|
||||
@catch_exceptions
|
||||
@add_common_args_to_docstring(filterkeys=True,limitkeys=True)
|
||||
def get_charts_albums_external(**keys):
|
||||
"""Returns album charts
|
||||
|
||||
:return: list (List)
|
||||
:rtype: Dictionary"""
|
||||
k_filter, k_time, _, _, _ = uri_to_internal(keys,forceArtist=True)
|
||||
ckeys = {**k_filter, **k_time}
|
||||
|
||||
result = database.get_charts_albums(**ckeys)
|
||||
|
||||
return {
|
||||
"status":"ok",
|
||||
"list":result
|
||||
}
|
||||
|
||||
|
||||
@api.get("pulse")
|
||||
|
Loading…
x
Reference in New Issue
Block a user