<?php
|
|
|
|
namespace App\Http\Controllers;
|
|
|
|
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
|
|
use Illuminate\Foundation\Bus\DispatchesJobs;
|
|
use Illuminate\Foundation\Validation\ValidatesRequests;
|
|
use Illuminate\Routing\Controller as BaseController;
|
|
|
|
class BucketController extends BaseController
|
|
{
|
|
use AuthorizesRequests, DispatchesJobs, ValidatesRequests;
|
|
|
|
public function get()
|
|
{
|
|
|
|
}
|
|
|
|
/**
|
|
*
|
|
* @return [type] [description]
|
|
*
|
|
*/
|
|
public function create()
|
|
{
|
|
return view('bucket.create');
|
|
}
|
|
|
|
public function store()
|
|
{
|
|
$validated = request()->validate([
|
|
'title' => 'required|max:255',
|
|
'is_public' => 'boolean',
|
|
]);
|
|
|
|
if ($validated) {
|
|
return redirect()
|
|
->route('bucket.get', ['uuid' => 12]);
|
|
} else {
|
|
return back()
|
|
->withInput();
|
|
}
|
|
}
|
|
}
|