This commit is contained in:
frederikpyt 2020-08-24 10:17:15 +02:00
commit 9a1b6873d2
12 changed files with 66 additions and 50 deletions

View File

@ -145,8 +145,8 @@ class ContactController extends Controller
"<th>Titel</th>". "<th>Titel</th>".
"<th>E-mail</th>". "<th>E-mail</th>".
"<th>Tlf</th>". "<th>Tlf</th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/pencil.svg\" alt=\"Update\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan-dark.svg')." alt=\"Update\"></th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan.svg')." alt=\"Delete\"></th>".
"</tr>"; "</tr>";

View File

@ -244,9 +244,9 @@ class EventController extends Controller
"<th>Event Navn</th>". "<th>Event Navn</th>".
"<th>Event Ansvarlig</th>". "<th>Event Ansvarlig</th>".
"<th>Event Dato</th>". "<th>Event Dato</th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/eye.svg\" alt=\"Update\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/eye.svg')." alt=\"see\"></th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/pencil.svg\" alt=\"Update\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan-dark.svg')." alt=\"Update\"></th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan.svg')." alt=\"Delete\"></th>".
"</tr>"; "</tr>";
$events = DB::table('events')->orderBY('date' , 'asc')->where('name', 'LIKE',$request->search.'%') $events = DB::table('events')->orderBY('date' , 'asc')->where('name', 'LIKE',$request->search.'%')
->orWhere('date','LIKE', $request->search.'%') ->orWhere('date','LIKE', $request->search.'%')

View File

@ -133,8 +133,9 @@ class FeedbackController extends Controller
public function search(Request $request){ public function search(Request $request){
if($request->ajax()){ if($request->ajax()){
$output = "<tr>". $output = "<tr>".
"<th style='width: 6em;'>Dato</th>".
"<th>Feedback Besked</th>". "<th>Feedback Besked</th>".
"<th>Ris el. Ros</th>". "<th style='width: 5em;'>Ris el. Ros</th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>".
"</tr>"; "</tr>";
@ -149,6 +150,7 @@ class FeedbackController extends Controller
if(count($feedbacks) !== 0){ if(count($feedbacks) !== 0){
foreach ($feedbacks as $key => $feedback){ foreach ($feedbacks as $key => $feedback){
$output.='<tr>'. $output.='<tr>'.
'<td>' . date('d-m-Y', strtotime($feedback->created_at)) . '</td>'.
'<td>' . $feedback->message . '</td>'. '<td>' . $feedback->message . '</td>'.
'<td>' . $feedback->suggestion_form . '</td>'. '<td>' . $feedback->suggestion_form . '</td>'.
'<td><form method="post" action="' .route("feedbacks.destroy", [ "feedback" => $feedback ]). '" class="w-100 nostyle">'. '<td><form method="post" action="' .route("feedbacks.destroy", [ "feedback" => $feedback ]). '" class="w-100 nostyle">'.

View File

@ -174,8 +174,8 @@ class LocationController extends Controller
$output = "<tr>". $output = "<tr>".
"<th>Navn</th>". "<th>Navn</th>".
"<th>Lokation</th>". "<th>Lokation</th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/pencil.svg\" alt=\"Update\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan-dark.svg')." alt=\"Update\"></th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan.svg')." alt=\"Delete\"></th>".
"</tr>"; "</tr>";
if($request->option !== 'all') { if($request->option !== 'all') {

View File

@ -140,8 +140,8 @@ class rolesController extends Controller
$output = "<tr>". $output = "<tr>".
"<th>Navn</th>". "<th>Navn</th>".
"<th>Beskrivelse</th>". "<th>Beskrivelse</th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/pencil.svg\" alt=\"Update\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan-dark.svg')." alt=\"Update\"></th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan.svg')." alt=\"Delete\"></th>".
"</tr>"; "</tr>";
$roles = DB::table('roles')->where('name', 'LIKE',$request->search.'%')->get(); $roles = DB::table('roles')->where('name', 'LIKE',$request->search.'%')->get();

View File

@ -414,8 +414,8 @@ class UserController extends Controller
"<th>Email</th>". "<th>Email</th>".
"<th>Tlf nr</th>". "<th>Tlf nr</th>".
"<th>Rolle(r)</th>". "<th>Rolle(r)</th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/pencil.svg\" alt=\"Update\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan-dark.svg')." alt=\"Update\"></th>".
"<th style=\"width: 1em;\"><img class=\"w-100\" src=\"http://127.0.0.1:8000/images/icons/trashcan.svg\" alt=\"Delete\"></th>". "<th style=\"width: 1em;\"><img class=\"w-100\" src=".asset('/images/icons/trashcan.svg')." alt=\"Delete\"></th>".
"</tr>"; "</tr>";

View File

@ -10,6 +10,9 @@
@endsection @endsection
@section("content") @section("content")
<?php
date_default_timezone_set('Europe/Copenhagen');
?>
<div class="row align-items-center"> <div class="row align-items-center">
<a class="btn btn-inline btn-sde-blue mb-0" href="{{ route('events.create') }}"><img src="{{ asset('/images/icons/plus.svg') }}" alt="Create">Opret Aktivitet</a> <a class="btn btn-inline btn-sde-blue mb-0" href="{{ route('events.create') }}"><img src="{{ asset('/images/icons/plus.svg') }}" alt="Create">Opret Aktivitet</a>
@ -29,20 +32,22 @@
<th style="width: 1em;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th> <th style="width: 1em;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
</tr> </tr>
@foreach($events as $event) @foreach($events as $event)
<tr> @if (date('Y-m-d H:i', strtotime('-1 day')) < date('Y-m-d H:i', strtotime($event->date)))
<td>{{ $event->name }}</td> <tr>
<td>{{ $event->accountable }}</td> <td>{{ $event->name }}</td>
<td>{{ \Illuminate\Support\Facades\Date::createFromTimeStamp(strtotime($event->date))->format('d/m/Y \k\l\. H:i') }}</td> <td>{{ $event->accountable }}</td>
<td><a href="{{ route("events.signups", [ "event" => $event ]) }}"><img class="w-100" src="{{ asset('/images/icons/eye-dark.svg') }}" alt="Show"></a></td> <td>{{ \Illuminate\Support\Facades\Date::createFromTimeStamp(strtotime($event->date))->format('d/m/Y \k\l\. H:i') }}</td>
<td><a href="{{ route("events.edit", [ "event" => $event ]) }}"><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td> <td><a href="{{ route("events.signups", [ "event" => $event ]) }}"><img class="w-100" src="{{ asset('/images/icons/eye-dark.svg') }}" alt="Show"></a></td>
<td><form method="post" action="{{ route("events.destroy", [ "event" => $event ]) }}" class="w-100 nostyle"> <td><a href="{{ route("events.edit", [ "event" => $event ]) }}"><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
@csrf <td><form method="post" action="{{ route("events.destroy", [ "event" => $event ]) }}" class="w-100 nostyle">
@method("delete") @csrf
@method("delete")
<button class="w-100 nostyle" onclick="return confirm('Are you sure you want to delete?');" type="submit"><img class="w-100 cursor-pointer" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></button> <button class="w-100 nostyle" onclick="return confirm('Are you sure you want to delete?');" type="submit"><img class="w-100 cursor-pointer" src="{{ asset('/images/icons/trashcan-dark.svg') }}" alt="Delete"></button>
</form> </form>
</td> </td>
</tr> </tr>
@endif
@endforeach @endforeach
</table> </table>

View File

@ -10,15 +10,7 @@
@endsection @endsection
@section("content") @section("content")
<div class="row align-items-center"> <table class="tbl mt-1">
<form method="post" action="{{ route("events.store") }}">
@csrf
<input type="text" class="form-controller" id="search" name="search" placeholder="//TODO: Søg på navn, efternavn, tlf"></input>
</form>
</div>
<table class="tbl mt-2">
<tr> <tr>
<th>Tilmeldtes Fornavn</th> <th>Tilmeldtes Fornavn</th>
<th>Tilmeldtes Efternavn</th> <th>Tilmeldtes Efternavn</th>

View File

@ -20,6 +20,12 @@
<option name="ris" value="Ris">Ris</option> <option name="ris" value="Ris">Ris</option>
<option name="ros" value="Ros">Ros</option> <option name="ros" value="Ros">Ros</option>
</select> </select>
<!-- Dont delete me sir :(
<input class="checkbox-inline" type="checkbox" name="checkbox" id="ris" value="ris">
<label for="efternavn">Ris</label>
<input class="checkbox-inline" type="checkbox" name="checkbox" id="ros" value="ros">
<label for="efternavn">Ros</label>
-->
</div> </div>

View File

@ -77,80 +77,91 @@
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "users.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "users.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/users-hvid.svg")}}" class="fa"><span style="margin-left: 4px;">Brugere</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route('users.index') }}" class="text-white"><img src="{{asset("/images/icons/users-hvid.svg")}}" class="fa"><span style="margin-left: 4px;">Brugere</span></a></h3> <h3 class="text-white"><a href="{{ route('users.index') }}" class="text-white"><img src="{{asset("/images/icons/users-hvid.svg")}}" class="fa"><span style="margin-left: 4px;">Brugere</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "roles.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "roles.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/role.svg")}}" class="fa"><span style="margin-left: 4px;">Roller</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("roles.index") }}" class="text-white"><img src="{{asset("/images/icons/role.svg")}}" class="fa"><span style="margin-left: 4px;">Roller</span></a></h3> <h3 class="text-white"><a href="{{ route("roles.index") }}" class="text-white"><img src="{{asset("/images/icons/role.svg")}}" class="fa"><span style="margin-left: 4px;">Roller</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "news.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "news.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/news.svg")}}" class="fa"><span style="margin-left: 4px;">Nyheder</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("news.index")}}" class="text-white"><img src="{{asset("/images/icons/news.svg")}}" class="fa"><span style="margin-left: 4px;">Nyheder</span></a></h3> <h3 class="text-white"><a href="{{ route("news.index")}}" class="text-white"><img src="{{asset("/images/icons/news.svg")}}" class="fa"><span style="margin-left: 4px;">Nyheder</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "menu-plans.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "menu-plans.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/Menuplan.svg")}}" class="fa"><span style="margin-left: 4px;">Menuplan</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("menu-plans.index")}}" class="text-white"><img src="{{asset("/images/icons/Menuplan.svg")}}" class="fa"><span style="margin-left: 4px;">Menuplan</span></a></h3> <h3 class="text-white"><a href="{{ route("menu-plans.index")}}" class="text-white"><img src="{{asset("/images/icons/Menuplan.svg")}}" class="fa"><span style="margin-left: 4px;">Menuplan</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "events.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "events.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/Aktiviteter.svg")}}" class="fa"><span style="margin-left: 4px;">Aktiviteter</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("events.index") }}" class="text-white"><img src="{{asset("/images/icons/Aktiviteter.svg")}}" class="fa"><span style="margin-left: 4px;">Aktiviteter</span></a></h3> <h3 class="text-white"><a href="{{ route("events.index") }}" class="text-white"><img src="{{asset("/images/icons/Aktiviteter.svg")}}" class="fa"><span style="margin-left: 4px;">Aktiviteter</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "locations.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "locations.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/location.svg")}}" class="fa"><span style="margin-left: 4px;">Lokationer</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("locations.index") }}" class="text-white"><img src="{{asset("/images/icons/location.svg")}}" class="fa"><span style="margin-left: 4px;">Lokationer</span></a></h3> <h3 class="text-white"><a href="{{ route("locations.index") }}" class="text-white"><img src="{{asset("/images/icons/location.svg")}}" class="fa"><span style="margin-left: 4px;">Lokationer</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "washing-machines.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "washing-machines.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/wash.svg")}}" class="fa"><span style="margin-left: 4px;">Vaskemaskiner</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("washing-machines.index") }}" class="text-white"><img src="{{asset("/images/icons/wash.svg")}}" class="fa"><span style="margin-left: 4px;">Vaskemaskiner</span></a></h3> <h3 class="text-white"><a href="{{ route("washing-machines.index") }}" class="text-white"><img src="{{asset("/images/icons/wash.svg")}}" class="fa"><span style="margin-left: 4px;">Vaskemaskiner</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "washing-reservations.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "washing-reservations.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/wash_res.svg")}}" class="fa"><span style="margin-left: 4px;">Reservationer</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("washing-reservations.index") }}" class="text-white"><img src="{{asset("/images/icons/wash_res.svg")}}" class="fa"><span style="margin-left: 4px;">Reservationer</span></a></h3> <h3 class="text-white"><a href="{{ route("washing-reservations.index") }}" class="text-white"><img src="{{asset("/images/icons/wash_res.svg")}}" class="fa"><span style="margin-left: 4px;">Reservationer</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "contacts.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "contacts.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/phone.svg")}}" class="fa"><span style="margin-left: 4px;">Kontakter</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route("contacts.index") }}" class="text-white"><img src="{{asset("/images/icons/phone.svg")}}" class="fa"><span style="margin-left: 4px;">Kontakter</span></a></h3> <h3 class="text-white"><a href="{{ route("contacts.index") }}" class="text-white"><img src="{{asset("/images/icons/phone.svg")}}" class="fa"><span style="margin-left: 4px;">Kontakter</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "guides.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "guides.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/Vejledninger.svg")}}" class="fa"><span style="margin-left: 4px;">Vejledning</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route('guides.index') }}" class="text-white"><img src="{{asset("/images/icons/Vejledninger.svg")}}" class="fa"><span style="margin-left: 4px;">Vejledning</span></a></h3> <h3 class="text-white"><a href="{{ route('guides.index') }}" class="text-white"><img src="{{asset("/images/icons/Vejledninger.svg")}}" class="fa"><span style="margin-left: 4px;">Vejledning</span></a></h3>
@endif
</div> </div>
@if(\Illuminate\Support\Facades\Request::route()->getName() == "feedbacks.index") @if(\Illuminate\Support\Facades\Request::route()->getName() == "feedbacks.index")
<div class="segment active"> <div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/feedback.svg")}}" class="fa"><span style="margin-left: 4px;">Feedback</span></a></h3>
@else @else
<div class="segment"> <div class="segment">
@endif
<h3 class="text-white"><a href="{{ route('feedbacks.index') }}" class="text-white"><img src="{{asset("/images/icons/feedback.svg")}}" class="fa"><span style="margin-left: 4px;">Feedback</span></a></h3> <h3 class="text-white"><a href="{{ route('feedbacks.index') }}" class="text-white"><img src="{{asset("/images/icons/feedback.svg")}}" class="fa"><span style="margin-left: 4px;">Feedback</span></a></h3>
@endif
</div> </div>
</div> </div>
<div class="w-85" style="background-color: #cccccc;"> <div class="w-85" style="background-color: #cccccc;">

View File

@ -32,7 +32,7 @@
<input class="checkbox-inline" type="checkbox" id="rolle" name="checkbox"value="rolle"> <input class="checkbox-inline" type="checkbox" id="rolle" name="checkbox"value="rolle">
<label for="rolle">Rolle</label> <label for="rolle">Rolle</label>
</div> </div>
<div id="showHideCheckboxs" style="margin-bottom: -36px"> <div id="showHideCheckboxs" style="margin-bottom: -38px">
</div> </div>
<table class="tbl mt-2"> <table class="tbl mt-2">

View File

@ -12,9 +12,9 @@
<p>Denne app er udviklet til Odense erhvervskollegie.</p> <p>Denne app er udviklet til Odense erhvervskollegie.</p>
<h4 class="mb-1 mt-1">{{__("msg.programmedby")}}:</h4> <h4 class="mb-1 mt-1">{{__("msg.programmedby")}}:</h4>
<span style="margin-bottom: 0.2rem;"><span style="float: left;">Anders Rasmussen,</span><span style="float: right;">anders164a@gmail.com</span></span> <span style="margin-bottom: 0.2rem;"><span style="float: left;">Anders Rasmussen,</span><span style="float: right;">anders164a@gmail.com</span></span>
<span style="margin-bottom: 0.2rem;">Frederik Milling Pytlick, frederikpyt@gmail.com</span> <span style="margin-bottom: 0.2rem;">Frederik Milling Pytlick,<span style="float: right;">frederikpyt@gmail.com</span></span>
<span style="margin-bottom: 0.2rem;">Vedran Zelen, vedr0021@gmail.com</span> <span style="margin-bottom: 0.2rem;">Vedran Zelen,<span style="float: right;">vedr0021@gmail.com</span></span>
<span style="margin-bottom: 0.2rem;">Victor Neerholt, victorneerholt@gmail.com</span> <span style="margin-bottom: 0.2rem;">Victor Neerholt,<span style="float: right;">victorneerholt@gmail.com</span></span>
<span style="margin-bottom: 0.2rem;">Sebastian Davaris, seba4928@edu.sde.dk</span> <span style="margin-bottom: 0.2rem;">Sebastian Davaris,<span style="float: right;">seba4928@edu.sde.dk</span></span>
</main> </main>
@endsection @endsection