From c9299b5410a55fa867826e389d16a48479a78504 Mon Sep 17 00:00:00 2001 From: Frankie B Date: Tue, 11 Jun 2024 18:02:01 +0100 Subject: Merge MVC rewrite into master (#21) * Just commit it all * Require auth * crap * Update homepage * Block AI scrapers * Update cache update script * Add dummy file * Remove unnecessary lastfm config var * Use withQueryParameters for LastFM API * Fix embeds * Update example env * Smard --- resources/views/pages/music.blade.php | 66 ----------------------------------- 1 file changed, 66 deletions(-) delete mode 100644 resources/views/pages/music.blade.php (limited to 'resources/views/pages/music.blade.php') diff --git a/resources/views/pages/music.blade.php b/resources/views/pages/music.blade.php deleted file mode 100644 index dba0750..0000000 --- a/resources/views/pages/music.blade.php +++ /dev/null @@ -1,66 +0,0 @@ -@extends('layouts.default') -@section('title', 'Music') -@section('description', '') -@section('content') - @php - - $cfg = app('config')->get('services')['lastfm']; - $api_root = app('config')->get('app')['api_root']; - - $api_alive = true; - - try { - $data = file_get_contents($api_root.'/lastfm/current'); - } catch (Exception $e) { - $api_alive = false; - } - @endphp - @if (!$api_alive) - @include('components.errors.api-error') - @else - - @php - $current_track = json_decode(file_get_contents($api_root . '/lastfm/current')); - $top_tracks = json_decode(file_get_contents($api_root . '/lastfm/top')); - $count = 0; - @endphp - - - - - - - - -
- - - - - - - - - - - @foreach ($top_tracks as $track) - @php $count++ @endphp - @if ($count >= $cfg['toptracks']+1) - @break - @endif - - - - - - - @endforeach -
-

Top {{ $cfg['toptracks'] }} Tracks (Last 7 days)

-
#TrackArtistPlays
{{ $count }}{{ $track->title }}{{ $track->artist }}{{ $track->playcount }}
- @endif -@stop -- cgit v1.2.3-54-g00ecf