Merge remote-tracking branch 'origin/master'
# Conflicts: # skolehjem/public/css/admin.css
This commit is contained in:
commit
2aaa8edd1b
|
@ -116,6 +116,9 @@
|
||||||
<path value="$PROJECT_DIR$/skolehjem/vendor/composer" />
|
<path value="$PROJECT_DIR$/skolehjem/vendor/composer" />
|
||||||
<path value="$PROJECT_DIR$/skolehjem/vendor/spatie/laravel-permission" />
|
<path value="$PROJECT_DIR$/skolehjem/vendor/spatie/laravel-permission" />
|
||||||
<path value="$PROJECT_DIR$/skolehjem/vendor/laravel/ui" />
|
<path value="$PROJECT_DIR$/skolehjem/vendor/laravel/ui" />
|
||||||
|
<path value="$PROJECT_DIR$/skolehjem/vendor/jaybizzle/crawler-detect" />
|
||||||
|
<path value="$PROJECT_DIR$/skolehjem/vendor/jenssegers/agent" />
|
||||||
|
<path value="$PROJECT_DIR$/skolehjem/vendor/mobiledetect/mobiledetectlib" />
|
||||||
</include_path>
|
</include_path>
|
||||||
</component>
|
</component>
|
||||||
<component name="PhpProjectSharedConfiguration" php_language_level="7.2" />
|
<component name="PhpProjectSharedConfiguration" php_language_level="7.2" />
|
||||||
|
|
|
@ -28,6 +28,8 @@
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/guzzlehttp/promises" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/guzzlehttp/promises" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/guzzlehttp/psr7" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/guzzlehttp/psr7" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/hamcrest/hamcrest-php" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/hamcrest/hamcrest-php" />
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/jaybizzle/crawler-detect" />
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/jenssegers/agent" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/laminas/laminas-diactoros" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/laminas/laminas-diactoros" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/laminas/laminas-zendframework-bridge" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/laminas/laminas-zendframework-bridge" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/laravel/framework" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/laravel/framework" />
|
||||||
|
@ -39,6 +41,7 @@
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/league/event" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/league/event" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/league/flysystem" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/league/flysystem" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/league/oauth2-server" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/league/oauth2-server" />
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/mobiledetect/mobiledetectlib" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/mockery/mockery" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/mockery/mockery" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/monolog/monolog" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/monolog/monolog" />
|
||||||
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/myclabs/deep-copy" />
|
<excludeFolder url="file://$MODULE_DIR$/skolehjem/vendor/myclabs/deep-copy" />
|
||||||
|
|
|
@ -6,5 +6,12 @@ use Illuminate\Database\Eloquent\Model;
|
||||||
|
|
||||||
class Event extends Model
|
class Event extends Model
|
||||||
{
|
{
|
||||||
//
|
/**
|
||||||
|
* The attributes that are mass assignable.
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
protected $fillable = [
|
||||||
|
"name", "description"
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,5 +6,12 @@ use Illuminate\Database\Eloquent\Model;
|
||||||
|
|
||||||
class ExternalLink extends Model
|
class ExternalLink extends Model
|
||||||
{
|
{
|
||||||
//
|
/**
|
||||||
|
* The attributes that are mass assignable.
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
protected $fillable = [
|
||||||
|
'name', "link"
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,22 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
namespace App\Helpers;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
use Jenssegers\Agent\Agent;
|
||||||
|
|
||||||
|
class Detector
|
||||||
|
{
|
||||||
|
public static function View($viewName, $args) {
|
||||||
|
|
||||||
|
$agent = new Agent();
|
||||||
|
|
||||||
|
if($agent->isMobile()) {
|
||||||
|
return view(config("detector.mobilePath") . "." . $viewName, $args);
|
||||||
|
}
|
||||||
|
return view(config("detector.defaultPath") . "." . $viewName, $args);
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,84 +1,95 @@
|
||||||
<?php
|
<?php
|
||||||
|
//
|
||||||
namespace App\Http\Controllers;
|
//namespace App\Http\Controllers;
|
||||||
|
//
|
||||||
use Illuminate\Http\Request;
|
//use App\CalendarDate;
|
||||||
|
//use Illuminate\Http\Request;
|
||||||
class CalendarDateController extends Controller
|
//
|
||||||
{
|
//class CalendarDateController extends Controller
|
||||||
/**
|
//{
|
||||||
* Display a listing of the resource.
|
// /**
|
||||||
*
|
// * Display a listing of the resource.
|
||||||
* @return \Illuminate\Http\Response
|
// *
|
||||||
*/
|
// * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
public function index()
|
// */
|
||||||
{
|
// public function index(Request $request)
|
||||||
//
|
// {
|
||||||
}
|
// $calendarDates = CalendarDate::query()->paginate($request->input("limit", 20));
|
||||||
|
//
|
||||||
/**
|
// return view("calendar-date.index", [
|
||||||
* Show the form for creating a new resource.
|
// "calendarDates" => $calendarDates
|
||||||
*
|
// ]);
|
||||||
* @return \Illuminate\Http\Response
|
// }
|
||||||
*/
|
//
|
||||||
public function create()
|
// /**
|
||||||
{
|
// * Show the form for creating a new resource.
|
||||||
//
|
// *
|
||||||
}
|
// * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
|
// */
|
||||||
/**
|
// public function create()
|
||||||
* Store a newly created resource in storage.
|
// {
|
||||||
*
|
// return view("calendar-date.create");
|
||||||
* @param \Illuminate\Http\Request $request
|
// }
|
||||||
* @return \Illuminate\Http\Response
|
//
|
||||||
*/
|
// /**
|
||||||
public function store(Request $request)
|
// * Store a newly created resource in storage.
|
||||||
{
|
// *
|
||||||
//
|
// * @param \Illuminate\Http\Request $request
|
||||||
}
|
// * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
|
// */
|
||||||
/**
|
// public function store(Request $request)
|
||||||
* Display the specified resource.
|
// {
|
||||||
*
|
// $fields = $request->validate([
|
||||||
* @param int $id
|
// "" => ""
|
||||||
* @return \Illuminate\Http\Response
|
// ]);
|
||||||
*/
|
//
|
||||||
public function show($id)
|
// $calendarDate = new CalendarDate()
|
||||||
{
|
//
|
||||||
//
|
// return view("calendar-date.store");
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
/**
|
// /**
|
||||||
* Show the form for editing the specified resource.
|
// * Display the specified resource.
|
||||||
*
|
// *
|
||||||
* @param int $id
|
// * @param int $id
|
||||||
* @return \Illuminate\Http\Response
|
// * @return \Illuminate\Http\Response
|
||||||
*/
|
// */
|
||||||
public function edit($id)
|
// public function show($id)
|
||||||
{
|
// {
|
||||||
//
|
// //
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
/**
|
// /**
|
||||||
* Update the specified resource in storage.
|
// * Show the form for editing the specified resource.
|
||||||
*
|
// *
|
||||||
* @param \Illuminate\Http\Request $request
|
// * @param int $id
|
||||||
* @param int $id
|
// * @return \Illuminate\Http\Response
|
||||||
* @return \Illuminate\Http\Response
|
// */
|
||||||
*/
|
// public function edit($id)
|
||||||
public function update(Request $request, $id)
|
// {
|
||||||
{
|
// //
|
||||||
//
|
// }
|
||||||
}
|
//
|
||||||
|
// /**
|
||||||
/**
|
// * Update the specified resource in storage.
|
||||||
* Remove the specified resource from storage.
|
// *
|
||||||
*
|
// * @param \Illuminate\Http\Request $request
|
||||||
* @param int $id
|
// * @param int $id
|
||||||
* @return \Illuminate\Http\Response
|
// * @return \Illuminate\Http\Response
|
||||||
*/
|
// */
|
||||||
public function destroy($id)
|
// public function update(Request $request, $id)
|
||||||
{
|
// {
|
||||||
//
|
// //
|
||||||
}
|
// }
|
||||||
}
|
//
|
||||||
|
// /**
|
||||||
|
// * Remove the specified resource from storage.
|
||||||
|
// *
|
||||||
|
// * @param int $id
|
||||||
|
// * @return \Illuminate\Http\Response
|
||||||
|
// */
|
||||||
|
// public function destroy($id)
|
||||||
|
// {
|
||||||
|
// //
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
namespace App\Http\Controllers;
|
||||||
|
|
||||||
|
use App\Event;
|
||||||
use App\User;
|
use App\User;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
|
|
||||||
|
@ -10,56 +11,65 @@ class EventController extends Controller
|
||||||
/**
|
/**
|
||||||
* Display a listing of the resource..
|
* Display a listing of the resource..
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function index(Request $request)
|
public function index(Request $request)
|
||||||
{
|
{
|
||||||
$users = User::query()->paginate($request->query("limit", 20));
|
$events = Event::query()->paginate($request->input("limit", 20));
|
||||||
|
|
||||||
return view("user.index", [ "users" => $users]);
|
return Response::detect("admin.events.index", [ "events" => $events]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Show the form for creating a new resource.
|
* Show the form for creating a new resource.
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function create()
|
public function create()
|
||||||
{
|
{
|
||||||
return view("user.create");
|
return Response::detect("admin.events.create");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Store a newly created resource in storage.
|
* Store a newly created resource in storage.
|
||||||
*
|
*
|
||||||
* @param \Illuminate\Http\Request $request
|
* @param \Illuminate\Http\Request $request
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function store(Request $request)
|
public function store(Request $request)
|
||||||
{
|
{
|
||||||
//
|
$requestBody = $request->validate([
|
||||||
|
"name" => "required|unique:events|max:255",
|
||||||
|
"description" => "required|max:255"
|
||||||
|
]);
|
||||||
|
|
||||||
|
$event = new Event($requestBody);
|
||||||
|
|
||||||
|
$event->save();
|
||||||
|
|
||||||
|
return Response::detect("admin.events.store");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Display the specified resource.
|
* Display the specified resource.
|
||||||
*
|
*
|
||||||
* @param int $id
|
* @param Event $id
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function show($id)
|
public function show(Event $id)
|
||||||
{
|
{
|
||||||
//
|
return Response::detect("admin.events.show", [ "event" => $id ]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Show the form for editing the specified resource.-
|
* Show the form for editing the specified resource.-
|
||||||
*
|
*
|
||||||
* @param int $id
|
* @param int $id
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function edit($id)
|
public function edit(Event $id)
|
||||||
{
|
{
|
||||||
//
|
return Response::detect("admin.events.edit", [ "event" => $id ]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -67,21 +77,32 @@ class EventController extends Controller
|
||||||
*
|
*
|
||||||
* @param \Illuminate\Http\Request $request
|
* @param \Illuminate\Http\Request $request
|
||||||
* @param int $id
|
* @param int $id
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function update(Request $request, $id)
|
public function update(Request $request, Event $id)
|
||||||
{
|
{
|
||||||
//
|
$requestBody = $request->validate([
|
||||||
|
"name" => "unique:events|max:255",
|
||||||
|
"description" => "max:255"
|
||||||
|
]);
|
||||||
|
|
||||||
|
$id->update($requestBody);
|
||||||
|
$id->save();
|
||||||
|
|
||||||
|
return Response::detect("admin.events.update");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Remove the specified resource from storage.
|
* Remove the specified resource from storage.
|
||||||
*
|
*
|
||||||
* @param int $id
|
* @param Event $id
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
|
* @throws \Exception
|
||||||
*/
|
*/
|
||||||
public function destroy($id)
|
public function destroy(Event $id)
|
||||||
{
|
{
|
||||||
//
|
$id->delete();
|
||||||
|
|
||||||
|
return Response::detect("admin.events.destroy");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
namespace App\Http\Controllers;
|
||||||
|
|
||||||
|
use App\ExternalLink;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
|
|
||||||
class ExternalLinkController extends Controller
|
class ExternalLinkController extends Controller
|
||||||
|
@ -9,32 +10,43 @@ class ExternalLinkController extends Controller
|
||||||
/**
|
/**
|
||||||
* Display a listing of the resource.
|
* Display a listing of the resource.
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Http\Response
|
* @param Request $request
|
||||||
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function index()
|
public function index(Request $request)
|
||||||
{
|
{
|
||||||
//
|
$externalLink = ExternalLink::query()->paginate($request->input("limit", 20));
|
||||||
|
|
||||||
|
return Response::detect("external-links.index", [ "externalLink" => $externalLink ]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Show the form for creating a new resource.
|
* Show the form for creating a new resource.
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function create()
|
public function create()
|
||||||
{
|
{
|
||||||
//
|
return Response::detect("external-links.create");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Store a newly created resource in storage.
|
* Store a newly created resource in storage.
|
||||||
*
|
*
|
||||||
* @param \Illuminate\Http\Request $request
|
* @param \Illuminate\Http\Request $request
|
||||||
* @return \Illuminate\Http\Response
|
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
|
||||||
*/
|
*/
|
||||||
public function store(Request $request)
|
public function store(Request $request)
|
||||||
{
|
{
|
||||||
//
|
$requestBody = $request->validate([
|
||||||
|
"name" => "required|max:255",
|
||||||
|
"link" => "required|max:255"
|
||||||
|
]);
|
||||||
|
|
||||||
|
$externalLink = new ExternalLink($requestBody);
|
||||||
|
$externalLink->save();
|
||||||
|
|
||||||
|
return Response::detect("external-links.store");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -7,6 +7,6 @@ use Illuminate\Http\Request;
|
||||||
class RootController extends Controller
|
class RootController extends Controller
|
||||||
{
|
{
|
||||||
public function index() {
|
public function index() {
|
||||||
return view("index");
|
return Response::detect("index");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,9 +2,12 @@
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
namespace App\Http\Controllers;
|
||||||
|
|
||||||
|
use App\Helpers\Detector;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
|
use Illuminate\Http\Response;
|
||||||
use App\User;
|
use App\User;
|
||||||
use Illuminate\Support\Facades\Auth;
|
use Illuminate\Support\Facades\Auth;
|
||||||
|
use Illuminate\Support\Facades\Log;
|
||||||
|
|
||||||
|
|
||||||
class UserController extends Controller
|
class UserController extends Controller
|
||||||
|
@ -28,9 +31,9 @@ class UserController extends Controller
|
||||||
*/
|
*/
|
||||||
public function index(Request $request)
|
public function index(Request $request)
|
||||||
{
|
{
|
||||||
$users = User::query()->paginate($request->query("page", 1));
|
$users = User::query()->paginate($request->query("page", 20));
|
||||||
|
|
||||||
return view("admin.user.index", [ "users" => $users ]);
|
return Response::detect("users.index", [ "users" => $users ]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -40,7 +43,7 @@ class UserController extends Controller
|
||||||
*/
|
*/
|
||||||
public function create()
|
public function create()
|
||||||
{
|
{
|
||||||
return view("admin.user.create");
|
return Response::detect("admin.users.create");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -51,6 +54,8 @@ class UserController extends Controller
|
||||||
*/
|
*/
|
||||||
public function store(Request $request)
|
public function store(Request $request)
|
||||||
{
|
{
|
||||||
|
Log::debug("STORE FUNCTION");
|
||||||
|
|
||||||
$data = $request->validate([
|
$data = $request->validate([
|
||||||
"name_first" => "required|max:255",
|
"name_first" => "required|max:255",
|
||||||
"name_last" => "required|max:255",
|
"name_last" => "required|max:255",
|
||||||
|
@ -60,10 +65,17 @@ class UserController extends Controller
|
||||||
|
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
Log::debug("FINISHED VALIDATION?");
|
||||||
|
|
||||||
$user = new User($data);
|
$user = new User($data);
|
||||||
|
|
||||||
|
Log::debug("CREATED USER [NOT PERSISTED YET]");
|
||||||
|
|
||||||
$user->save();
|
$user->save();
|
||||||
|
|
||||||
return view("admin.user.store");
|
Log::debug("SAVED USER");
|
||||||
|
|
||||||
|
return view("admin.users.store");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -76,7 +88,7 @@ class UserController extends Controller
|
||||||
{
|
{
|
||||||
$user = User::find($id);
|
$user = User::find($id);
|
||||||
|
|
||||||
return view("admin.user.show", [
|
return Respone::detect("admin.users.show", [
|
||||||
"user" => $user
|
"user" => $user
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -91,7 +103,7 @@ class UserController extends Controller
|
||||||
{
|
{
|
||||||
$user = User::find($id);
|
$user = User::find($id);
|
||||||
|
|
||||||
return view("admin.user.edit", [
|
return Response::detect("admin.users.edit", [
|
||||||
"user" => $user
|
"user" => $user
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -130,7 +142,7 @@ class UserController extends Controller
|
||||||
$user->save();
|
$user->save();
|
||||||
}
|
}
|
||||||
|
|
||||||
return view("admin.user.edit", [
|
return Response::detect("admin.users.edit", [
|
||||||
"user" => $user
|
"user" => $user
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -153,7 +165,7 @@ class UserController extends Controller
|
||||||
$user->delete();
|
$user->delete();
|
||||||
}
|
}
|
||||||
|
|
||||||
return view("admin.user.delete");
|
return view("admin.users.delete");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*******************************************/
|
/*******************************************/
|
||||||
|
@ -161,7 +173,7 @@ class UserController extends Controller
|
||||||
/*******************************************/
|
/*******************************************/
|
||||||
|
|
||||||
public function showLogin() {
|
public function showLogin() {
|
||||||
return view("admin.user.login");
|
return view("admin.users.login");
|
||||||
}
|
}
|
||||||
|
|
||||||
public function login(Request $request) {
|
public function login(Request $request) {
|
||||||
|
@ -169,7 +181,7 @@ class UserController extends Controller
|
||||||
|
|
||||||
if(Auth::attempt($data)) {
|
if(Auth::attempt($data)) {
|
||||||
//TODO: Implement home?
|
//TODO: Implement home?
|
||||||
return view("admin.user.home", [ "user" => Auth::user() ]);
|
return redirect()->route("users.index");
|
||||||
}
|
}
|
||||||
|
|
||||||
return redirect()->back(303);
|
return redirect()->back(303);
|
||||||
|
|
|
@ -18,7 +18,7 @@ class WashingMachineController extends Controller
|
||||||
{
|
{
|
||||||
$machines = WashingMachine::query()->paginate($request->query("page", 1));
|
$machines = WashingMachine::query()->paginate($request->query("page", 1));
|
||||||
|
|
||||||
return view("washing-machine.index", [ "machines" => $machines ]);
|
return Response::detect("admin.washing-machines.index", [ "machines" => $machines ]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -28,7 +28,7 @@ class WashingMachineController extends Controller
|
||||||
*/
|
*/
|
||||||
public function create()
|
public function create()
|
||||||
{
|
{
|
||||||
return view("washing-machine.create");
|
return Response::detect("admin.washing-machines.create");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -46,7 +46,7 @@ class WashingMachineController extends Controller
|
||||||
$machine = new WashingMachine($data);
|
$machine = new WashingMachine($data);
|
||||||
$machine->save();
|
$machine->save();
|
||||||
|
|
||||||
return view("washing-machine.store");
|
return Response::detect("admin.washing-machines.store");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -59,7 +59,7 @@ class WashingMachineController extends Controller
|
||||||
{
|
{
|
||||||
$machine = WashingMachine::find($id);
|
$machine = WashingMachine::find($id);
|
||||||
|
|
||||||
return view("washing-machine.show", [
|
return Response::detect("admin.washing-machines.show", [
|
||||||
"machine" => $machine
|
"machine" => $machine
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -74,7 +74,7 @@ class WashingMachineController extends Controller
|
||||||
{
|
{
|
||||||
$machine = WashingMachine::find($id);
|
$machine = WashingMachine::find($id);
|
||||||
|
|
||||||
return view("washing-machine.edit", [
|
return Response::detect("admin.washing-machines.edit", [
|
||||||
"machine" => $machine
|
"machine" => $machine
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -98,7 +98,7 @@ class WashingMachineController extends Controller
|
||||||
|
|
||||||
$machine->save();
|
$machine->save();
|
||||||
|
|
||||||
return view("washing-machine.edit", [
|
return Response::detect("admin.washing-machines.edit", [
|
||||||
"machine" => $machine
|
"machine" => $machine
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -114,6 +114,6 @@ class WashingMachineController extends Controller
|
||||||
$machine = WashingMachine::find($id);
|
$machine = WashingMachine::find($id);
|
||||||
$machine->delete();
|
$machine->delete();
|
||||||
|
|
||||||
return view("washing-machine.destroy");
|
return Response::detect("admin.washing-machines.destroy");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,7 @@ class WashingReservationController extends Controller
|
||||||
{
|
{
|
||||||
$reservations = WashingReservation::query()->paginate($request->query("page", 1));
|
$reservations = WashingReservation::query()->paginate($request->query("page", 1));
|
||||||
|
|
||||||
return view("washing-reservation.index");
|
return Response::detect("washing-reservation.index");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -27,7 +27,7 @@ class WashingReservationController extends Controller
|
||||||
*/
|
*/
|
||||||
public function create()
|
public function create()
|
||||||
{
|
{
|
||||||
return view("washing-reservation.create");
|
return Response::detect("washing-reservation.create");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -45,7 +45,7 @@ class WashingReservationController extends Controller
|
||||||
$machineReservation = new WashingReservation($data);
|
$machineReservation = new WashingReservation($data);
|
||||||
$machineReservation->save();
|
$machineReservation->save();
|
||||||
|
|
||||||
return view("washing-reservation.store");
|
return Response::detect("washing-reservation.store");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -58,7 +58,7 @@ class WashingReservationController extends Controller
|
||||||
{
|
{
|
||||||
$machineReservation = WashingReservation::find($id);
|
$machineReservation = WashingReservation::find($id);
|
||||||
|
|
||||||
return view("washing-reservation.show", [
|
return Response::detect("washing-reservation.show", [
|
||||||
"machineReservation" => $machineReservation
|
"machineReservation" => $machineReservation
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -71,7 +71,7 @@ class WashingReservationController extends Controller
|
||||||
*/
|
*/
|
||||||
public function edit($id)
|
public function edit($id)
|
||||||
{
|
{
|
||||||
return view("washing-reservation.edit");
|
return Response::detect("washing-reservation.edit");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -93,7 +93,7 @@ class WashingReservationController extends Controller
|
||||||
|
|
||||||
$machineReservation->save();
|
$machineReservation->save();
|
||||||
|
|
||||||
return view("washing-reservation.edit", [
|
return Response::detect("washing-reservation.edit", [
|
||||||
"washingReservation" => $machineReservation
|
"washingReservation" => $machineReservation
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
@ -109,6 +109,6 @@ class WashingReservationController extends Controller
|
||||||
$machineReservation = WashingReservation::find($id);
|
$machineReservation = WashingReservation::find($id);
|
||||||
$machineReservation->delete();
|
$machineReservation->delete();
|
||||||
|
|
||||||
return view("washing-reservation.delete");
|
return Response::detect("washing-reservation.delete");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,35 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Providers;
|
||||||
|
|
||||||
|
use Illuminate\Http\Response;
|
||||||
|
use Illuminate\Support\ServiceProvider;
|
||||||
|
use Jenssegers\Agent\Facades\Agent;
|
||||||
|
|
||||||
|
class DetectorServiceProvider extends ServiceProvider
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Register services.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
public function register()
|
||||||
|
{
|
||||||
|
//
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Bootstrap services.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
public function boot()
|
||||||
|
{
|
||||||
|
Response::macro("detect", function ($view, $args) {
|
||||||
|
if(Agent::isMobile()) {
|
||||||
|
return view(config("detector.mobilePath") . "." . $view, $args);
|
||||||
|
}
|
||||||
|
return view(config("detector.defaultPath") . "." . $view, $args);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
|
@ -6,6 +6,8 @@ use Illuminate\Contracts\Auth\MustVerifyEmail;
|
||||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||||
use Illuminate\Foundation\Auth\User as Authenticatable;
|
use Illuminate\Foundation\Auth\User as Authenticatable;
|
||||||
use Illuminate\Notifications\Notifiable;
|
use Illuminate\Notifications\Notifiable;
|
||||||
|
use Illuminate\Support\Facades\Auth;
|
||||||
|
use Illuminate\Support\Facades\Hash;
|
||||||
use Spatie\Permission\Traits\HasRoles;
|
use Spatie\Permission\Traits\HasRoles;
|
||||||
|
|
||||||
class User extends Authenticatable
|
class User extends Authenticatable
|
||||||
|
@ -39,4 +41,8 @@ class User extends Authenticatable
|
||||||
protected $casts = [
|
protected $casts = [
|
||||||
'email_verified_at' => 'datetime',
|
'email_verified_at' => 'datetime',
|
||||||
];
|
];
|
||||||
|
|
||||||
|
public function setPasswordAttribute($password) {
|
||||||
|
$this->attributes["password"] = Hash::make($password);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
"fideloper/proxy": "^4.2",
|
"fideloper/proxy": "^4.2",
|
||||||
"fruitcake/laravel-cors": "^1.0",
|
"fruitcake/laravel-cors": "^1.0",
|
||||||
"guzzlehttp/guzzle": "^6.3",
|
"guzzlehttp/guzzle": "^6.3",
|
||||||
|
"jenssegers/agent": "^2.6",
|
||||||
"laravel/framework": "^7.0",
|
"laravel/framework": "^7.0",
|
||||||
"laravel/tinker": "^2.0",
|
"laravel/tinker": "^2.0",
|
||||||
"laravel/ui": "^2.0",
|
"laravel/ui": "^2.0",
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -166,7 +166,7 @@ return [
|
||||||
* Package Service Providers...
|
* Package Service Providers...
|
||||||
*/
|
*/
|
||||||
Spatie\Permission\PermissionServiceProvider::class,
|
Spatie\Permission\PermissionServiceProvider::class,
|
||||||
|
Jenssegers\Agent\AgentServiceProvider::class,
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Application Service Providers...
|
* Application Service Providers...
|
||||||
|
@ -177,6 +177,10 @@ return [
|
||||||
App\Providers\EventServiceProvider::class,
|
App\Providers\EventServiceProvider::class,
|
||||||
App\Providers\RouteServiceProvider::class,
|
App\Providers\RouteServiceProvider::class,
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Custom Service Prviders
|
||||||
|
*/
|
||||||
|
App\Providers\DetectorServiceProvider::class,
|
||||||
],
|
],
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -229,6 +233,7 @@ return [
|
||||||
'Validator' => Illuminate\Support\Facades\Validator::class,
|
'Validator' => Illuminate\Support\Facades\Validator::class,
|
||||||
'View' => Illuminate\Support\Facades\View::class,
|
'View' => Illuminate\Support\Facades\View::class,
|
||||||
|
|
||||||
|
'Agent' => Jenssegers\Agent\Facades\Agent::class,
|
||||||
],
|
],
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|
|
@ -0,0 +1,7 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
"defaultPath" => "admin",
|
||||||
|
|
||||||
|
"mobilePath" => "app",
|
||||||
|
];
|
|
@ -537,7 +537,6 @@ main {
|
||||||
|
|
||||||
.tbl > tbody > tr > td > a {
|
.tbl > tbody > tr > td > a {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
display: flex;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.tbl > tbody > tr > td > a > img {
|
.tbl > tbody > tr > td > a > img {
|
||||||
|
|
|
@ -0,0 +1,505 @@
|
||||||
|
@font-face {
|
||||||
|
font-family: "Titillium Web";
|
||||||
|
src: url("/fonts/TitilliumWeb-Regular.ttf");
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: "Titillium Web";
|
||||||
|
src: url("/fonts/TitilliumWeb-SemiBold.ttf");
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: "Titillium Web";
|
||||||
|
src: url("/fonts/TitilliumWeb-Bold.ttf");
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
form {
|
||||||
|
max-width: 100%;
|
||||||
|
padding: 0 0.45rem 0 0.45rem;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn {
|
||||||
|
border: 0;
|
||||||
|
border-radius: 4px;
|
||||||
|
padding: 0.5rem;
|
||||||
|
cursor: pointer;
|
||||||
|
font-weight: 700;
|
||||||
|
font-size: 1.05rem;
|
||||||
|
background-color: white;
|
||||||
|
color: #333333;
|
||||||
|
margin-bottom: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-dark {
|
||||||
|
color: white;
|
||||||
|
background-color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-sde-blue {
|
||||||
|
color: white;
|
||||||
|
background-color: #00788a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-disabled {
|
||||||
|
color: white;
|
||||||
|
background-color: #cccccc;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-inline {
|
||||||
|
display: inline-flex;
|
||||||
|
}
|
||||||
|
|
||||||
|
input {
|
||||||
|
border: grey solid 2px;
|
||||||
|
border-radius: 4px;
|
||||||
|
background-color: transparent;
|
||||||
|
font-size: 1rem;
|
||||||
|
line-height: 2rem;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
input.appinput {
|
||||||
|
border: none;
|
||||||
|
border-bottom: white solid 2px;
|
||||||
|
background-color: transparent;
|
||||||
|
font-size: 1rem;
|
||||||
|
color: white;
|
||||||
|
line-height: 2rem;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.d-flex {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
|
.d-none {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.row {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
}
|
||||||
|
|
||||||
|
.align-items-center {
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cursor-normal {
|
||||||
|
cursor: default;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cursor-pointer {
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.text-white {
|
||||||
|
color: #ffffff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.text-center {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sde-blue {
|
||||||
|
color: #00788a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sde-black-80 {
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sde-black-20 {
|
||||||
|
color: #cccccc;
|
||||||
|
}
|
||||||
|
|
||||||
|
.regular {
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
|
||||||
|
.semi-bold {
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bold {
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__label.sde-blue::before {
|
||||||
|
border-color: #00788a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sde-blue.toggle__text::before {
|
||||||
|
border-color: #00788a;
|
||||||
|
}
|
||||||
|
|
||||||
|
span.toggle__text.sde-blue {
|
||||||
|
font-size: 5vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
.m-auto {
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mr-auto {
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ml-auto {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mt-auto {
|
||||||
|
margin-top: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb-auto {
|
||||||
|
margin-bottom: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ml-0 {
|
||||||
|
margin-left: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mr-0 {
|
||||||
|
margin-right: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb-0 {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mt-0 {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ml-1 {
|
||||||
|
margin-left: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mr-1 {
|
||||||
|
margin-right: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb-1 {
|
||||||
|
margin-bottom: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mt-1 {
|
||||||
|
margin-top: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ml-2 {
|
||||||
|
margin-left: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mr-2 {
|
||||||
|
margin-right: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb-2 {
|
||||||
|
margin-bottom: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mt-2 {
|
||||||
|
margin-top: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ml-3 {
|
||||||
|
margin-left: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mr-3 {
|
||||||
|
margin-right: 4.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb-3 {
|
||||||
|
margin-bottom: 4.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mt-3 {
|
||||||
|
margin-top: 4.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
* {
|
||||||
|
font-family: "Titillium Web";
|
||||||
|
}
|
||||||
|
|
||||||
|
html,
|
||||||
|
body {
|
||||||
|
width: 100%;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
::-moz-placeholder {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
:-ms-input-placeholder {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
::-ms-input-placeholder {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
::placeholder {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: #000000;
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.w-100 {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.w-85 {
|
||||||
|
width: 85%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.w-75 {
|
||||||
|
width: 75%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.w-50 {
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.w-25 {
|
||||||
|
width: 25%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.w-15 {
|
||||||
|
width: 15%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.h-100 {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.h-90 {
|
||||||
|
height: 90%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.h-10 {
|
||||||
|
height: 10%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bg-sde-blue {
|
||||||
|
background-color: #00788a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle {
|
||||||
|
--uiToggleSize: var(--toggleSize, 20px);
|
||||||
|
--uiToggleIndent: var(--toggleIndent, .4em);
|
||||||
|
--uiToggleBorderWidth: var(--toggleBorderWidth, 2px);
|
||||||
|
--uiToggleColor: var(--toggleColor, #000);
|
||||||
|
--uiToggleDisabledColor: var(--toggleDisabledColor, #868e96);
|
||||||
|
--uiToggleBgColor: var(--toggleBgColor, #fff);
|
||||||
|
--uiToggleArrowWidth: var(--toggleArrowWidth, 2px);
|
||||||
|
--uiToggleArrowColor: var(--toggleArrowColor, #fff);
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
display: inline-block;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input {
|
||||||
|
position: absolute;
|
||||||
|
left: -99999px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__label {
|
||||||
|
display: inline-flex;
|
||||||
|
min-height: var(--uiToggleSize);
|
||||||
|
padding-left: calc(var(--uiToggleSize) + var(--uiToggleIndent));
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled) ~ .toggle__label {
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__label::before,
|
||||||
|
.toggle__label::after {
|
||||||
|
content: "";
|
||||||
|
box-sizing: border-box;
|
||||||
|
width: 1em;
|
||||||
|
height: 1em;
|
||||||
|
font-size: var(--uiToggleSize);
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__label:before {
|
||||||
|
border: var(--uiToggleBorderWidth) solid var(--uiToggleColor);
|
||||||
|
z-index: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:disabled ~ .toggle__label::before {
|
||||||
|
border-color: var(--uiToggleDisabledColor);
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:focus ~ .toggle__label::before {
|
||||||
|
box-shadow: 0 0 0 2px var(--uiToggleBgColor), 0 0 0 4px var(--uiToggleColor);
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled):checked:focus ~ .toggle__label::after {
|
||||||
|
box-shadow: 0 0 0 2px var(--uiToggleBgColor), 0 0 0 4px var(--uiToggleColor);
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled) ~ .toggle__label::after {
|
||||||
|
background-color: var(--uiToggleColor);
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled):checked ~ .toggle__label::after {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__text {
|
||||||
|
margin-top: auto;
|
||||||
|
margin-bottom: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__text::before {
|
||||||
|
content: "";
|
||||||
|
box-sizing: border-box;
|
||||||
|
width: 0;
|
||||||
|
height: 0;
|
||||||
|
font-size: var(--uiToggleSize);
|
||||||
|
border-left-width: 0;
|
||||||
|
border-bottom-width: 0;
|
||||||
|
border-left-style: solid;
|
||||||
|
border-bottom-style: solid;
|
||||||
|
border-color: var(--uiToggleArrowColor);
|
||||||
|
position: absolute;
|
||||||
|
top: 0.5428em;
|
||||||
|
left: 0.2em;
|
||||||
|
z-index: 3;
|
||||||
|
transform-origin: left top;
|
||||||
|
transform: rotate(-40deg) skew(10deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled):checked ~ .toggle__label .toggle__text::before {
|
||||||
|
width: 0.5em;
|
||||||
|
height: 0.25em;
|
||||||
|
border-left-width: var(--uiToggleArrowWidth);
|
||||||
|
border-bottom-width: var(--uiToggleArrowWidth);
|
||||||
|
will-change: width, height;
|
||||||
|
transition: width 0.1s ease-out 0.2s, height 0.2s ease-out;
|
||||||
|
margin-top: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:disabled ~ .toggle__label {
|
||||||
|
opacity: 0.24;
|
||||||
|
cursor: not-allowed;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__label::before,
|
||||||
|
.toggle__label::after {
|
||||||
|
border: 2px solid;
|
||||||
|
border-color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled) ~ .toggle__label::before,
|
||||||
|
.toggle__input:not(:disabled) ~ .toggle__label::after {
|
||||||
|
opacity: 1;
|
||||||
|
transform-origin: center center;
|
||||||
|
margin-top: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__text::before {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle__input:not(:disabled):checked ~ .toggle__label .toggle__text::before {
|
||||||
|
opacity: 1;
|
||||||
|
transition: opacity 0.1s ease-out 0.3s, width 0.1s ease-out 0.5s, height 0.2s ease-out 0.3s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle {
|
||||||
|
--toggleColor: transparent;
|
||||||
|
--toggleBgColor: transparent;
|
||||||
|
--toggleSize: 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
main {
|
||||||
|
max-width: 900px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
margin: auto;
|
||||||
|
padding: 0 1.25rem 0 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media only screen and (max-width: 900px) {
|
||||||
|
main {
|
||||||
|
max-width: 460px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
margin: auto;
|
||||||
|
padding: 0 1.25rem 0 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.brand {
|
||||||
|
padding: 0 1rem 0 1rem;
|
||||||
|
margin: 7rem 0 5rem 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
header,
|
||||||
|
#menu {
|
||||||
|
padding: 1.25rem 1.75rem 0 1.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
#menu {
|
||||||
|
padding-top: 4rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
#menu > a {
|
||||||
|
color: white;
|
||||||
|
font-size: 8vw;
|
||||||
|
font-weight: 600;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
#menu > a > img {
|
||||||
|
height: 1em;
|
||||||
|
margin-right: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
font-size: 12vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
font-size: 8vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
p {
|
||||||
|
font-size: 4vw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@ document.addEventListener("DOMContentLoaded", function(){
|
||||||
// Handler when the DOM is fully loaded
|
// Handler when the DOM is fully loaded
|
||||||
var path = window.location.pathname;
|
var path = window.location.pathname;
|
||||||
|
|
||||||
if(path === "/menuplan" || path === "/vagttelefon" || path === "/")
|
if(path === "/menuplans" || path === "/vagttelefon" || path === "/")
|
||||||
{
|
{
|
||||||
document.getElementById ('toggle').addEventListener ('click', toggleMenu, false);
|
document.getElementById ('toggle').addEventListener ('click', toggleMenu, false);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@ document.addEventListener("DOMContentLoaded", function(){
|
||||||
// Handler when the DOM is fully loaded
|
// Handler when the DOM is fully loaded
|
||||||
var path = window.location.pathname;
|
var path = window.location.pathname;
|
||||||
|
|
||||||
if(path === "/menuplan")
|
if(path === "/menuplans")
|
||||||
{
|
{
|
||||||
updateWeek();
|
updateWeek();
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
|
|
||||||
.tbl > tbody > tr > td > a {
|
.tbl > tbody > tr > td > a {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
display: flex;
|
//display: flex;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tbl > tbody > tr > td > a > img {
|
.tbl > tbody > tr > td > a > img {
|
||||||
|
|
|
@ -0,0 +1,41 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Vaskemaskiner - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="" class="text-white">Opret Vaskemaskine</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<h1>Opret Bruger:</h1>
|
||||||
|
<form method="post" action="{{ route("washing-machines.store") }}">
|
||||||
|
@csrf
|
||||||
|
<label for="name_first">Navn:</label>
|
||||||
|
<input type="text" name="name" id="name" max="60" required>
|
||||||
|
<input type="submit" class="btn btn-dark text-white" value="Opret">
|
||||||
|
</form>
|
||||||
|
|
||||||
|
{{-- <table class="tbl">--}}
|
||||||
|
{{-- <tr>--}}
|
||||||
|
{{-- <th>ID</th>--}}
|
||||||
|
{{-- <th>Fornavn</th>--}}
|
||||||
|
{{-- <th>Efternavn</th>--}}
|
||||||
|
{{-- <th>Email</th>--}}
|
||||||
|
{{-- <th>Tlf nr</th>--}}
|
||||||
|
{{-- <th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>--}}
|
||||||
|
{{-- <th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>--}}
|
||||||
|
{{-- </tr>--}}
|
||||||
|
{{-- <tr>--}}
|
||||||
|
{{-- <td>{ID}</td>--}}
|
||||||
|
{{-- <td>{Fornavn}</td>--}}
|
||||||
|
{{-- <td>{Efternavn}</td>--}}
|
||||||
|
{{-- <td>{Email}</td>--}}
|
||||||
|
{{-- <td>{TLF}</td>--}}
|
||||||
|
{{-- <td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>--}}
|
||||||
|
{{-- <td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>--}}
|
||||||
|
{{-- </tr>--}}
|
||||||
|
{{-- </table>--}}
|
||||||
|
@endsection
|
|
@ -0,0 +1,33 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Vaskemaskiner - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="" class="text-white">Vis Vaskemaskiner</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<table class="tbl">
|
||||||
|
<tr>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Fornavn</th>
|
||||||
|
<th>Efternavn</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Tlf nr</th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>{ID}</td>
|
||||||
|
<td>{Fornavn}</td>
|
||||||
|
<td>{Efternavn}</td>
|
||||||
|
<td>{Email}</td>
|
||||||
|
<td>{TLF}</td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
@endsection
|
|
@ -0,0 +1,33 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Events - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="{{ route("events.index") }}" class="text-white">Vis Events</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<table class="tbl">
|
||||||
|
<tr>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Fornavn</th>
|
||||||
|
<th>Efternavn</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Tlf nr</th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>{ID}</td>
|
||||||
|
<td>{Fornavn}</td>
|
||||||
|
<td>{Efternavn}</td>
|
||||||
|
<td>{Email}</td>
|
||||||
|
<td>{TLF}</td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
@endsection
|
|
@ -0,0 +1,33 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Vaskemaskiner - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="" class="text-white">Vis Vaskemaskiner</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<table class="tbl">
|
||||||
|
<tr>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Fornavn</th>
|
||||||
|
<th>Efternavn</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Tlf nr</th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>{ID}</td>
|
||||||
|
<td>{Fornavn}</td>
|
||||||
|
<td>{Efternavn}</td>
|
||||||
|
<td>{Email}</td>
|
||||||
|
<td>{TLF}</td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
@endsection
|
|
@ -0,0 +1,33 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Vaskemaskiner - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="" class="text-white">Vis Vaskemaskiner</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<table class="tbl">
|
||||||
|
<tr>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Fornavn</th>
|
||||||
|
<th>Efternavn</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Tlf nr</th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>{ID}</td>
|
||||||
|
<td>{Fornavn}</td>
|
||||||
|
<td>{Efternavn}</td>
|
||||||
|
<td>{Email}</td>
|
||||||
|
<td>{TLF}</td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
@endsection
|
|
@ -0,0 +1,33 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Vaskemaskiner - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="" class="text-white">Vis Vaskemaskiner</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<table class="tbl">
|
||||||
|
<tr>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Fornavn</th>
|
||||||
|
<th>Efternavn</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Tlf nr</th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>{ID}</td>
|
||||||
|
<td>{Fornavn}</td>
|
||||||
|
<td>{Efternavn}</td>
|
||||||
|
<td>{Email}</td>
|
||||||
|
<td>{TLF}</td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
@endsection
|
|
@ -0,0 +1,33 @@
|
||||||
|
@extends("admin.layout.base")
|
||||||
|
@extends("admin.layout.header")
|
||||||
|
|
||||||
|
@section("title")
|
||||||
|
Vaskemaskiner - Vis
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("path")
|
||||||
|
<a href="" class="text-white">Vis Vaskemaskiner</a> /
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section("content")
|
||||||
|
<table class="tbl">
|
||||||
|
<tr>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Fornavn</th>
|
||||||
|
<th>Efternavn</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Tlf nr</th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>{ID}</td>
|
||||||
|
<td>{Fornavn}</td>
|
||||||
|
<td>{Efternavn}</td>
|
||||||
|
<td>{Email}</td>
|
||||||
|
<td>{TLF}</td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
@endsection
|
|
@ -22,10 +22,10 @@
|
||||||
<div class="segment">
|
<div class="segment">
|
||||||
<h3 class="text-white">Menuplan</h3>
|
<h3 class="text-white">Menuplan</h3>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<a href="" class="text-white"><img src="{{ asset('/images/icons/eye.svg') }}" alt="Read">Vis Menuplan</a>
|
{{-- <a href="{{ route("menu-plans.index") }}" class="text-white"><img src="{{ asset('/images/icons/eye.svg') }}" alt="Read">Vis Menuplan</a>--}}
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<a href="" class="text-white"><img src="{{ asset('/images/icons/plus.svg') }}" alt="Create">Opret Menuplan</a>
|
{{-- <a href="{{ route("menu-plans.create") }}" class="text-white"><img src="{{ asset('/images/icons/plus.svg') }}" alt="Create">Opret Menuplan</a>--}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -4,9 +4,9 @@
|
||||||
|
|
||||||
@auth
|
@auth
|
||||||
<a href="" class="btn btn-dark text-white m-0 ml-auto">User: {{ Auth::user()->name }}</a>
|
<a href="" class="btn btn-dark text-white m-0 ml-auto">User: {{ Auth::user()->name }}</a>
|
||||||
<a href="{{ route('user.logout') }}" class="btn btn-dark text-white m-0 ml-1 mr-1">Log ud</a>
|
<a href="{{ route('users.logout') }}" class="btn btn-dark text-white m-0 ml-1 mr-1">Log ud</a>
|
||||||
@else
|
@else
|
||||||
<a href="{{ route('user.login') }}" class="btn btn-dark text-white m-0 ml-auto mr-1">Log ind</a>
|
<a href="{{ route('users.login') }}" class="btn btn-dark text-white m-0 ml-auto mr-1">Log ind</a>
|
||||||
@endauth
|
@endauth
|
||||||
|
|
||||||
</header>
|
</header>
|
||||||
|
|
|
@ -11,7 +11,8 @@
|
||||||
|
|
||||||
@section("content")
|
@section("content")
|
||||||
<h1>Opret Bruger:</h1>
|
<h1>Opret Bruger:</h1>
|
||||||
<form method="post" action="/users">
|
<form method="post" action="{{ route("users.store") }}">
|
||||||
|
@csrf
|
||||||
<label for="name_first">Fornavn:</label>
|
<label for="name_first">Fornavn:</label>
|
||||||
<input type="text" name="name_first" id="name_first" required>
|
<input type="text" name="name_first" id="name_first" required>
|
||||||
<label for="name_last">Efternavn:</label>
|
<label for="name_last">Efternavn:</label>
|
||||||
|
|
|
@ -6,12 +6,13 @@
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section("path")
|
@section("path")
|
||||||
<a href="{{ route('users.edit', ['id' => user->id]) }}" class="text-white">Rediger Bruger</a> /
|
<a href="{{ route('users.edit', ['id' => $user->id]) }}" class="text-white">Rediger Bruger</a> /
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section("content")
|
@section("content")
|
||||||
<h1>Rediger Bruger:</h1>
|
<h1>Rediger Bruger:</h1>
|
||||||
<form method="post" action="">
|
<form method="post" action="">
|
||||||
|
@csrf
|
||||||
<label for="name_first">Fornavn:</label>
|
<label for="name_first">Fornavn:</label>
|
||||||
<input type="text" name="name_first" id="name_first" value="{Fornavn}" required>
|
<input type="text" name="name_first" id="name_first" value="{Fornavn}" required>
|
||||||
<label for="name_last">Efternavn:</label>
|
<label for="name_last">Efternavn:</label>
|
||||||
|
|
|
@ -20,14 +20,18 @@
|
||||||
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
||||||
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
</tr>
|
</tr>
|
||||||
|
@foreach($users as $user)
|
||||||
<tr>
|
<tr>
|
||||||
<td>{ID}</td>
|
<td>{{ $user->id }}</td>
|
||||||
<td>{Fornavn}</td>
|
<td>{{ $user->name_first }}</td>
|
||||||
<td>{Efternavn}</td>
|
<td>{{ $user->name_last }}</td>
|
||||||
<td>{Email}</td>
|
<td>{{ $user->email }}</td>
|
||||||
<td>{TLF}</td>
|
<td>{{ $user->phone }}</td>
|
||||||
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||||
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@endforeach
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
{{ $users->links() }}
|
||||||
@endsection
|
@endsection
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
<img src="{{URL::asset('/images/logos/Logo-hvid.svg')}}" alt="Syddansk Erhvervsskole">
|
<img src="{{URL::asset('/images/logos/Logo-hvid.svg')}}" alt="Syddansk Erhvervsskole">
|
||||||
</div>
|
</div>
|
||||||
<form action="" method="post">
|
<form action="" method="post">
|
||||||
|
@csrf
|
||||||
<input class="appinput" type="email" name="email" placeholder="Email" required>
|
<input class="appinput" type="email" name="email" placeholder="Email" required>
|
||||||
<input class="appinput" type="password" name="password" placeholder="Password" required>
|
<input class="appinput" type="password" name="password" placeholder="Password" required>
|
||||||
<label class="toggle">
|
<label class="toggle">
|
||||||
|
|
|
@ -6,28 +6,36 @@
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section("path")
|
@section("path")
|
||||||
<a href="" class="text-white">Vis Vaskemaskiner</a> /
|
<a href="" class="text-white">Opret Vaskemaskine</a> /
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section("content")
|
@section("content")
|
||||||
<table class="tbl">
|
<h1>Opret Bruger:</h1>
|
||||||
<tr>
|
<form method="post" action="{{ route("washing-machines.store") }}">
|
||||||
<th>ID</th>
|
@csrf
|
||||||
<th>Fornavn</th>
|
<label for="name_first">Navn:</label>
|
||||||
<th>Efternavn</th>
|
<input type="text" name="name" id="name" max="60" required>
|
||||||
<th>Email</th>
|
<input type="submit" class="btn btn-dark text-white" value="Opret">
|
||||||
<th>Tlf nr</th>
|
</form>
|
||||||
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>
|
|
||||||
<th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
{{-- <table class="tbl">--}}
|
||||||
</tr>
|
{{-- <tr>--}}
|
||||||
<tr>
|
{{-- <th>ID</th>--}}
|
||||||
<td>{ID}</td>
|
{{-- <th>Fornavn</th>--}}
|
||||||
<td>{Fornavn}</td>
|
{{-- <th>Efternavn</th>--}}
|
||||||
<td>{Efternavn}</td>
|
{{-- <th>Email</th>--}}
|
||||||
<td>{Email}</td>
|
{{-- <th>Tlf nr</th>--}}
|
||||||
<td>{TLF}</td>
|
{{-- <th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/pencil.svg') }}" alt="Update"></th>--}}
|
||||||
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
{{-- <th style="width: 1px;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>--}}
|
||||||
<td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>
|
{{-- </tr>--}}
|
||||||
</tr>
|
{{-- <tr>--}}
|
||||||
</table>
|
{{-- <td>{ID}</td>--}}
|
||||||
|
{{-- <td>{Fornavn}</td>--}}
|
||||||
|
{{-- <td>{Efternavn}</td>--}}
|
||||||
|
{{-- <td>{Email}</td>--}}
|
||||||
|
{{-- <td>{TLF}</td>--}}
|
||||||
|
{{-- <td><a href=""><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>--}}
|
||||||
|
{{-- <td><a href=""><img class="w-100" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></a></td>--}}
|
||||||
|
{{-- </tr>--}}
|
||||||
|
{{-- </table>--}}
|
||||||
@endsection
|
@endsection
|
||||||
|
|
|
@ -29,10 +29,10 @@
|
||||||
{{--@extends("admin.users.update")--}}
|
{{--@extends("admin.users.update")--}}
|
||||||
|
|
||||||
{{--Create Menuplan--}}
|
{{--Create Menuplan--}}
|
||||||
{{--@extends("admin.menuplan.create")--}}
|
{{--@extends("admin.menuplans.create")--}}
|
||||||
|
|
||||||
{{--Read Menuplan--}}
|
{{--Read Menuplan--}}
|
||||||
{{--@extends("admin.menuplan.show")--}}
|
{{--@extends("admin.menuplans.show")--}}
|
||||||
|
|
||||||
{{--Update Menuplan--}}
|
{{--Update Menuplan--}}
|
||||||
{{--@extends("admin.menuplan.update")--}}
|
{{--@extends("admin.menuplans.update")--}}
|
||||||
|
|
|
@ -17,16 +17,16 @@ use Illuminate\Support\Facades\Route;
|
||||||
// return view('welcome');
|
// return view('welcome');
|
||||||
//});
|
//});
|
||||||
|
|
||||||
Route::middleware(["auth"])->group(function () {
|
|
||||||
Route::resource("washing-machines", "WashingMachineController");
|
|
||||||
Route::resource("washing-reservations", "WashingReservationController");
|
|
||||||
});
|
|
||||||
|
|
||||||
Route::get("/", "RootController@index")->name("root.index");
|
Route::get("/", "RootController@index")->name("root.index");
|
||||||
|
|
||||||
|
|
||||||
Route::get("/login", "UserController@showLogin")->name("user.show-login");
|
Route::get("/login", "UserController@showLogin")->name("users.show-login");
|
||||||
Route::post("/login", "UserController@login")->name("user.login");
|
Route::post("/login", "UserController@login")->name("users.login");
|
||||||
Route::get("/logout", "UserController@logout")->name("user.logout");
|
Route::get("/logout", "UserController@logout")->name("users.logout");
|
||||||
|
|
||||||
|
|
||||||
|
Route::resource("menu-plans", "");
|
||||||
Route::resource("users", "UserController");
|
Route::resource("users", "UserController");
|
||||||
|
Route::resource("events", "EventController");
|
||||||
|
Route::resource("washing-machines", "WashingMachineController");
|
||||||
|
Route::resource("washing-reservations", "WashingReservationController");
|
||||||
|
|
Loading…
Reference in New Issue