1
0
mirror of https://github.com/krateng/maloja.git synced 2023-08-10 21:12:55 +03:00
This commit is contained in:
Krateng 2020-01-21 22:00:42 +01:00
parent a2cc27ddd4
commit 218c7eb2fd
3 changed files with 8 additions and 34 deletions

View File

@ -60,6 +60,6 @@ NAME = None
[Misc]
EXPERIMENTAL_FEATURES = no
USE_PYHP = no
FEDERATION = yes
USE_PYHP = no #not recommended at the moment
FEDERATION = yes #does nothing yet
UPDATE_AFTER_CRASH = no #update when server is automatically restarted

View File

@ -63,7 +63,6 @@ if get_settings("SPOTIFY_API_ID") not in [None,"ASK"] and get_settings("SPOTIFY_
def api_request_artist(artist):
for api in apis_artists:
if True:
log("API: " + api["name"] + "; Image request: " + artist,module="external")
try:
artiststring = urllib.parse.quote(artist)
var = artiststring
@ -99,7 +98,6 @@ def api_request_track(track):
artists, title = track
for api in apis_tracks:
if True:
log("API: " + api["name"] + "; Image request: " + "/".join(artists) + " - " + title,module="external")
try:
artiststring = urllib.parse.quote(", ".join(artists))
titlestring = urllib.parse.quote(title)

View File

@ -9,25 +9,13 @@
<pyhp if="pages > 1">
<pyhp if="page > 1">
<a href='?{compose(touri(dict(**unchanged,page=0)))}'>
<span class='stat_selector'>
1
</span>
</a>
|
<a href='?{compose(touri(dict(**unchanged,page=0)))}'><span class='stat_selector'>1</span></a> |
</pyhp>
<pyhp if="page > 2">
... |
</pyhp>
<pyhp if="page > 2"> ... | </pyhp>
<pyhp if="page > 0">
<a href='?{compose(touri(dict(**unchanged,page=page-1)))}'>
<span class='stat_selector'>
<pyhp echo="page" />
</span>
</a>
«
<a href='?{compose(touri(dict(**unchanged,page=page-1)))}'><span class='stat_selector'><pyhp echo="page" /></span></a> «
</pyhp>
<span style='opacity:0.5;' class='stat_selector'>
@ -35,25 +23,13 @@
</span>
<pyhp if="page < pages - 1">
»
<a href='?{compose(touri(dict(**unchanged,page=page+1)))}'>
<span class='stat_selector'>
<pyhp echo="page+2" />
</span>
</a>
» <a href='?{compose(touri(dict(**unchanged,page=page+1)))}'><span class='stat_selector'><pyhp echo="page+2" /></span></a>
</pyhp>
<pyhp if="page < pages - 3">
| ...
</pyhp>
<pyhp if="page < pages - 3"> | ... </pyhp>
<pyhp if="page < pages - 2">
|
<a href='?{compose(touri(dict(**unchanged,page=pages-1)))}'>
<span class='stat_selector'>
<pyhp echo="pages" />
</span>
</a>
| <a href='?{compose(touri(dict(**unchanged,page=pages-1)))}'><span class='stat_selector'><pyhp echo="pages" /></span></a>
</pyhp>
</pyhp>