1
0

Convert date of a most listened song to client's local time.

This commit is contained in:
Alexander Andreev 2023-03-13 02:11:33 +04:00
parent bdf778cc67
commit 184561ab29
Signed by: Arav
GPG Key ID: D22A817D95815393

View File

@ -1,6 +1,7 @@
:go:func Index(mainSite string, songsNum int, status *radio.IcecastStatus, songs *[]radio.Song) :go:func Index(mainSite string, songsNum int, status *radio.IcecastStatus, songs *[]radio.Song, r *http.Request)
:go:import "dwelling-radio/internal/radio" :go:import "dwelling-radio/internal/radio"
:go:import "dwelling-radio/pkg/utils"
doctype html doctype html
html(lang='en') html(lang='en')
@ -57,7 +58,7 @@ html(lang='en')
td= song.Song td= song.Song
- ml := radio.MostListened() - ml := radio.MostListened()
if ml.Song != "" if ml.Song != ""
p Most listened song was "#{ml.Song}" on #{ml.DateString()} with #[b #{ml.Listeners}] listeners. p.right Most listened song was "#{ml.Song}" on #{utils.ToClientTimezone(ml.Date, r).Format(radio.MostListenedDateFormat)} with #[b #{ml.Listeners}] listeners.
section section
h2 Privacy statements h2 Privacy statements
p Logs are collected and include access date and time, IP-address, User-Agent, referer URL, request. This website makes use of JavaScript to update a radio status and last #{songsNum} songs list. p Logs are collected and include access date and time, IP-address, User-Agent, referer URL, request. This website makes use of JavaScript to update a radio status and last #{songsNum} songs list.