diff options
| author | Zach DeCook <zachdecook@gmail.com> | 2018-12-28 14:59:54 -0500 |
|---|---|---|
| committer | Zach DeCook <zachdecook@gmail.com> | 2018-12-28 15:00:11 -0500 |
| commit | 47208936ee3c18745bbd9a753a9cc566648a5e17 (patch) | |
| tree | 70a5052a2d2f555a688a69aa41736a861ba93c89 /laravel/resources | |
| parent | 159ee785e197ba57600649e53edc01bc3c22bcfd (diff) | |
| download | prosongsa-47208936ee3c18745bbd9a753a9cc566648a5e17.tar.gz | |
* Links: Make them better show song name instead of title
Diffstat (limited to 'laravel/resources')
| -rw-r--r-- | laravel/resources/views/song.blade.php | 18 | ||||
| -rw-r--r-- | laravel/resources/views/welcome.blade.php | 2 |
2 files changed, 14 insertions, 6 deletions
diff --git a/laravel/resources/views/song.blade.php b/laravel/resources/views/song.blade.php index 412e53d..6c34871 100644 --- a/laravel/resources/views/song.blade.php +++ b/laravel/resources/views/song.blade.php @@ -3,19 +3,28 @@ @section('content') + <link type='text/css' rel='stylesheet' href='/css/song.css'/> + <div class='controlArea'> @if( isset( $back ) ) - <a href='{{route('song.show', ['song' => $back])}}'>{{$back->title}}</a> + <a class='back' href='{{route('song.show', ['song' => $back, 'playlist' => $playlist ?? ''])}}'> + {{$back->name}} + </a> @endif @if( $playlist ?? FALSE) - <a href='{{route('playlist.show',['playlist' => $playlist->name])}}'> + <a class='home' href='{{route('playlist.show',['playlist' => $playlist->name])}}'> Back to {{$playlist->name}} </a> @else - <a href='{{route('song.list')}}'>Go home</a> + <a class='home' href='{{route('song.list')}}'> + Go home + </a> @endif @if( isset( $next ) ) - <a href='{{route('song.show', ['song' => $next])}}'>{{$next->title}}</a> + <a class='next' href='{{route('song.show', ['song' => $next, 'playlist' => $playlist ?? ''])}}'> + {{$next->name}} + </a> @endif + </div> <h2>{{$song['title']}}</h2> <h3>{{$song->author}}</h3> @@ -37,7 +46,6 @@ for ($i=-6; $i < 12; $i++) { if (($transp + 24)%12 == $i) $selected = 'selected'; else $selected = ''; - //$dir = ($i >= 0 ? "up" : "down" ); $dir = "transpose"; echo "<option value='$i' $selected>$dir $i semitones</option>"; } diff --git a/laravel/resources/views/welcome.blade.php b/laravel/resources/views/welcome.blade.php index 3f95380..b8b2627 100644 --- a/laravel/resources/views/welcome.blade.php +++ b/laravel/resources/views/welcome.blade.php @@ -10,7 +10,7 @@ @foreach( App\Song::all() as $song ) <li> <a href='{{ route('song.show', ['song' => $song]) }}'> - {{ $song['title'] }} + {{ $song->name }} </a> @endforeach </ul> |
