1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
<?php
/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/
Route::get('/', function () {
return view('welcome');
})->name('song.list');
Route::post('/new/song', 'SongController@post')->name('song.postnew')/*->middleware('can:create,App\Song')*/;
Route::get('/playlist/{playlist}', 'PlaylistController@show')->name('playlist.show');
Route::post('/playlist/{playlist}/{song}', 'PlaylistController@post')->name('playlist.post');
Route::get('/s/{song}', 'SongController@show')->name('song.show');
Route::get('/s/{song}/suggested/{from}', 'SongController@suggested')->name('song.suggested');
Route::post('/s/{song}', 'SongController@update')->name('song.update')->middleware('can:update,song');
Route::get('/s/{song}/edit', 'SongController@edit')->name('song.edit')->middleware('can:update,song');
Route::get('/song/{song}', 'SongController@oldShow')->name('song.oldShow');
Auth::routes();
Route::get('/home', 'HomeController@index')->name('home');
|