diff --git a/skolehjem/app/Http/Controllers/EventController.php b/skolehjem/app/Http/Controllers/EventController.php index 1227237..9ea766d 100644 --- a/skolehjem/app/Http/Controllers/EventController.php +++ b/skolehjem/app/Http/Controllers/EventController.php @@ -172,6 +172,7 @@ class EventController extends Controller */ public function update(Request $request, $id) { + $data = $request->all(); $event = Event::find($id); @@ -182,6 +183,11 @@ class EventController extends Controller return redirect()->route("events.index", ['events' => $event]); }else{ $event->update($data); + + if($request->file("resource")) { + $event->resource_id = ResourceController::store($request)->id; + } + $event->save(); $events = Event::query()->get(); @@ -196,9 +202,6 @@ class EventController extends Controller $news->resource_id = $event->resource_id; $news->content = "
" . $this->closetags(substr($event->description, 0, 300)); - if($request->file("resource")) { - $event->resource_id = ResourceController::store($request)->id; - } NewsController::storeAndGet($news); diff --git a/skolehjem/app/Http/Controllers/GuideController.php b/skolehjem/app/Http/Controllers/GuideController.php index 62f3f79..2366361 100644 --- a/skolehjem/app/Http/Controllers/GuideController.php +++ b/skolehjem/app/Http/Controllers/GuideController.php @@ -126,14 +126,16 @@ class GuideController extends Controller */ public function update(Request $request, Guide $guide) { - $data = $request->validate([ - "name" => "required|max:255", - "guide_articles" => "required", - "guide_category_id" => "required", - ]); + $data = $request->all(); $guidee = Guide::query()->where("id", "=", $guide->id)->first(); $guidee->update($data); + + //If an image has been uploaded, store the file + if($request->file("resource")) { + $guidee->resource_id = ResourceController::store($request)->id; + } + $saved = $guidee->save(); if(!$saved){ @@ -236,26 +238,26 @@ class GuideController extends Controller foreach ($guides as $guide) { $output .= '
', '', '', '', '', ' Der er ingen vejledninger af denne kategori Der er ingen vejledninger af denne kategori There are no guides of this category There are no guides of this category Der er ingen vejledninger af denne kategori Der er ingen vejledninger af denne kategori '.$menuplan->thursday.'', '', '', '
', '
', '', '
', '', '
', '
', '
', '
', '
', '
'. $guide->name .'
'.
+ 'Torsdag:
'.
'" .
" ";
if ($request->option !== 'all') {
diff --git a/skolehjem/public/css/admin.css b/skolehjem/public/css/admin.css
index b164a5c..0330c2b 100644
--- a/skolehjem/public/css/admin.css
+++ b/skolehjem/public/css/admin.css
@@ -131,6 +131,10 @@ input.appinput {
display: flex;
}
+.flex-column {
+ flex-direction: column;
+}
+
.d-none {
display: none !important;
}
@@ -201,8 +205,40 @@ nav {
color: darkgrey;
}
+.position-fixed {
+ position: fixed;
+}
+
+.top-0 {
+ top: 0;
+}
+
+.zindex-100 {
+ z-index: 100;
+}
+
+.border-none {
+ border: none;
+}
+
+.outline-none {
+ outline: none;
+}
+
+.overflow-visible {
+ overflow: visible;
+}
+
+ol {
+ padding-right: 8px;
+}
+
.text-white {
- color: #ffffff;
+ color: #fff;
+}
+
+.text-black {
+ color: #000;
}
.text-center {
@@ -245,6 +281,26 @@ span.toggle__text.sde-blue {
font-size: 5vw;
}
+.justify-content-center {
+ justify-content: center;
+}
+
+.justify-unset {
+ justify-content: unset;
+}
+
+.justify-content-space {
+ justify-content: space-between;
+}
+
+.event-text-shadow {
+ text-shadow: 2px 2px 2px #00788A;
+}
+
+.font-20px {
+ font-size: 20px;
+}
+
.m-auto {
margin: auto;
}
@@ -281,14 +337,46 @@ span.toggle__text.sde-blue {
margin-top: 0;
}
+.pl-0 {
+ padding-left: 0;
+}
+
+.pr-0 {
+ padding-right: 0;
+}
+
+.pb-0 {
+ padding-bottom: 0;
+}
+
+.pt-0 {
+ padding-top: 0;
+}
+
+.m-none {
+ margin: 0;
+}
+
+.p-none {
+ padding: 0;
+}
+
.ml-1 {
margin-left: 0.75rem;
}
+.pl-1 {
+ padding-left: 0.75rem;
+}
+
.mr-1 {
margin-right: 0.75rem;
}
+.pr-1 {
+ padding-right: 0.75rem;
+}
+
.mb-1 {
margin-bottom: 0.75rem;
}
@@ -297,6 +385,10 @@ span.toggle__text.sde-blue {
margin-top: 0.75rem;
}
+.pt-1 {
+ padding-top: 0.75rem;
+}
+
.ml-2 {
margin-left: 3rem;
}
@@ -309,10 +401,18 @@ span.toggle__text.sde-blue {
margin-bottom: 3rem;
}
+.mb-2rem {
+ margin-bottom: 2rem;
+}
+
.mt-2 {
margin-top: 3rem;
}
+.mt-2rem {
+ margin-top: 2rem;
+}
+
.ml-3 {
margin-left: 3rem;
}
@@ -329,6 +429,10 @@ span.toggle__text.sde-blue {
margin-top: 4.75rem;
}
+.ml-4px {
+ margin-left: 4px;
+}
+
* {
font-family: "Titillium Web";
}
@@ -358,7 +462,6 @@ body {
}
a {
- color: #000000;
text-decoration: none;
}
@@ -386,6 +489,18 @@ a {
width: 15%;
}
+.w-1em {
+ width: 1em;
+}
+
+.w-6em {
+ width: 6em;
+}
+
+.w-7em {
+ width: 7em;
+}
+
.h-100 {
height: 100%;
}
@@ -402,6 +517,10 @@ a {
background-color: #00788a;
}
+.bg-white {
+ background-color: white;
+}
+
.block-container {
padding: 0 8px;
}
@@ -430,6 +549,22 @@ a {
margin-left: 8px;
}
+.lh-2 {
+ line-height: 2rem;
+}
+
+.bs-cover {
+ background-size: cover;
+}
+
+.bp-center {
+ background-position: center;
+}
+
+.resize-vertical {
+ resize: vertical;
+}
+
.toggle {
--uiToggleSize: var(--toggleSize, 20px);
--uiToggleIndent: var(--toggleIndent, .4em);
diff --git a/skolehjem/public/css/webapp.css b/skolehjem/public/css/webapp.css
index 490eef5..f06ecf0 100644
--- a/skolehjem/public/css/webapp.css
+++ b/skolehjem/public/css/webapp.css
@@ -131,6 +131,10 @@ input.appinput {
display: flex;
}
+.flex-column {
+ flex-direction: column;
+}
+
.d-none {
display: none !important;
}
@@ -201,8 +205,40 @@ nav {
color: darkgrey;
}
+.position-fixed {
+ position: fixed;
+}
+
+.top-0 {
+ top: 0;
+}
+
+.zindex-100 {
+ z-index: 100;
+}
+
+.border-none {
+ border: none;
+}
+
+.outline-none {
+ outline: none;
+}
+
+.overflow-visible {
+ overflow: visible;
+}
+
+ol {
+ padding-right: 8px;
+}
+
.text-white {
- color: #ffffff;
+ color: #fff;
+}
+
+.text-black {
+ color: #000;
}
.text-center {
@@ -245,6 +281,26 @@ span.toggle__text.sde-blue {
font-size: 5vw;
}
+.justify-content-center {
+ justify-content: center;
+}
+
+.justify-unset {
+ justify-content: unset;
+}
+
+.justify-content-space {
+ justify-content: space-between;
+}
+
+.event-text-shadow {
+ text-shadow: 2px 2px 2px #00788A;
+}
+
+.font-20px {
+ font-size: 20px;
+}
+
.m-auto {
margin: auto;
}
@@ -281,14 +337,46 @@ span.toggle__text.sde-blue {
margin-top: 0;
}
+.pl-0 {
+ padding-left: 0;
+}
+
+.pr-0 {
+ padding-right: 0;
+}
+
+.pb-0 {
+ padding-bottom: 0;
+}
+
+.pt-0 {
+ padding-top: 0;
+}
+
+.m-none {
+ margin: 0;
+}
+
+.p-none {
+ padding: 0;
+}
+
.ml-1 {
margin-left: 0.75rem;
}
+.pl-1 {
+ padding-left: 0.75rem;
+}
+
.mr-1 {
margin-right: 0.75rem;
}
+.pr-1 {
+ padding-right: 0.75rem;
+}
+
.mb-1 {
margin-bottom: 0.75rem;
}
@@ -297,6 +385,10 @@ span.toggle__text.sde-blue {
margin-top: 0.75rem;
}
+.pt-1 {
+ padding-top: 0.75rem;
+}
+
.ml-2 {
margin-left: 3rem;
}
@@ -309,10 +401,18 @@ span.toggle__text.sde-blue {
margin-bottom: 3rem;
}
+.mb-2rem {
+ margin-bottom: 2rem;
+}
+
.mt-2 {
margin-top: 3rem;
}
+.mt-2rem {
+ margin-top: 2rem;
+}
+
.ml-3 {
margin-left: 3rem;
}
@@ -329,6 +429,10 @@ span.toggle__text.sde-blue {
margin-top: 4.75rem;
}
+.ml-4px {
+ margin-left: 4px;
+}
+
* {
font-family: "Titillium Web";
}
@@ -358,7 +462,6 @@ body {
}
a {
- color: #000000;
text-decoration: none;
}
@@ -386,6 +489,18 @@ a {
width: 15%;
}
+.w-1em {
+ width: 1em;
+}
+
+.w-6em {
+ width: 6em;
+}
+
+.w-7em {
+ width: 7em;
+}
+
.h-100 {
height: 100%;
}
@@ -402,6 +517,10 @@ a {
background-color: #00788a;
}
+.bg-white {
+ background-color: white;
+}
+
.block-container {
padding: 0 8px;
}
@@ -430,6 +549,22 @@ a {
margin-left: 8px;
}
+.lh-2 {
+ line-height: 2rem;
+}
+
+.bs-cover {
+ background-size: cover;
+}
+
+.bp-center {
+ background-position: center;
+}
+
+.resize-vertical {
+ resize: vertical;
+}
+
.toggle {
--uiToggleSize: var(--toggleSize, 20px);
--uiToggleIndent: var(--toggleIndent, .4em);
@@ -7125,3 +7260,7 @@ main {
}
}
+iframe {
+ width: 100%;
+}
+
diff --git a/skolehjem/public/css/webappdark.css b/skolehjem/public/css/webappdark.css
index aceed77..6a9bb5c 100644
--- a/skolehjem/public/css/webappdark.css
+++ b/skolehjem/public/css/webappdark.css
@@ -131,6 +131,10 @@ input.appinput {
display: flex;
}
+.flex-column {
+ flex-direction: column;
+}
+
.d-none {
display: none !important;
}
@@ -201,8 +205,40 @@ nav {
color: darkgrey;
}
+.position-fixed {
+ position: fixed;
+}
+
+.top-0 {
+ top: 0;
+}
+
+.zindex-100 {
+ z-index: 100;
+}
+
+.border-none {
+ border: none;
+}
+
+.outline-none {
+ outline: none;
+}
+
+.overflow-visible {
+ overflow: visible;
+}
+
+ol {
+ padding-right: 8px;
+}
+
.text-white {
- color: #ffffff;
+ color: #fff;
+}
+
+.text-black {
+ color: #000;
}
.text-center {
@@ -245,6 +281,26 @@ span.toggle__text.sde-blue {
font-size: 5vw;
}
+.justify-content-center {
+ justify-content: center;
+}
+
+.justify-unset {
+ justify-content: unset;
+}
+
+.justify-content-space {
+ justify-content: space-between;
+}
+
+.event-text-shadow {
+ text-shadow: 2px 2px 2px #00788A;
+}
+
+.font-20px {
+ font-size: 20px;
+}
+
.m-auto {
margin: auto;
}
@@ -281,14 +337,46 @@ span.toggle__text.sde-blue {
margin-top: 0;
}
+.pl-0 {
+ padding-left: 0;
+}
+
+.pr-0 {
+ padding-right: 0;
+}
+
+.pb-0 {
+ padding-bottom: 0;
+}
+
+.pt-0 {
+ padding-top: 0;
+}
+
+.m-none {
+ margin: 0;
+}
+
+.p-none {
+ padding: 0;
+}
+
.ml-1 {
margin-left: 0.75rem;
}
+.pl-1 {
+ padding-left: 0.75rem;
+}
+
.mr-1 {
margin-right: 0.75rem;
}
+.pr-1 {
+ padding-right: 0.75rem;
+}
+
.mb-1 {
margin-bottom: 0.75rem;
}
@@ -297,6 +385,10 @@ span.toggle__text.sde-blue {
margin-top: 0.75rem;
}
+.pt-1 {
+ padding-top: 0.75rem;
+}
+
.ml-2 {
margin-left: 3rem;
}
@@ -309,10 +401,18 @@ span.toggle__text.sde-blue {
margin-bottom: 3rem;
}
+.mb-2rem {
+ margin-bottom: 2rem;
+}
+
.mt-2 {
margin-top: 3rem;
}
+.mt-2rem {
+ margin-top: 2rem;
+}
+
.ml-3 {
margin-left: 3rem;
}
@@ -329,6 +429,10 @@ span.toggle__text.sde-blue {
margin-top: 4.75rem;
}
+.ml-4px {
+ margin-left: 4px;
+}
+
* {
font-family: "Titillium Web";
}
@@ -358,7 +462,6 @@ body {
}
a {
- color: #000000;
text-decoration: none;
}
@@ -386,6 +489,18 @@ a {
width: 15%;
}
+.w-1em {
+ width: 1em;
+}
+
+.w-6em {
+ width: 6em;
+}
+
+.w-7em {
+ width: 7em;
+}
+
.h-100 {
height: 100%;
}
@@ -402,6 +517,10 @@ a {
background-color: #00788a;
}
+.bg-white {
+ background-color: white;
+}
+
.block-container {
padding: 0 8px;
}
@@ -430,6 +549,22 @@ a {
margin-left: 8px;
}
+.lh-2 {
+ line-height: 2rem;
+}
+
+.bs-cover {
+ background-size: cover;
+}
+
+.bp-center {
+ background-position: center;
+}
+
+.resize-vertical {
+ resize: vertical;
+}
+
.toggle {
--uiToggleSize: var(--toggleSize, 20px);
--uiToggleIndent: var(--toggleIndent, .4em);
@@ -7125,6 +7260,10 @@ main {
}
}
+iframe {
+ width: 100%;
+}
+
html,
body {
background-color: #2F3136;
diff --git a/skolehjem/resources/sass/app/general/_displays.scss b/skolehjem/resources/sass/app/general/_displays.scss
index e3d69f9..f92199f 100644
--- a/skolehjem/resources/sass/app/general/_displays.scss
+++ b/skolehjem/resources/sass/app/general/_displays.scss
@@ -2,6 +2,10 @@
display: flex;
}
+.flex-column {
+ flex-direction: column;
+}
+
.d-none {
display: none !important;
}
@@ -28,8 +32,6 @@
cursor: pointer;
}
-
-
nav > .pagination {
display: flex;
list-style: none;
@@ -72,3 +74,31 @@ nav {
.calendar-table__col.disabled > .calendar-table__item {
color: darkgrey;
}
+
+.position-fixed {
+ position: fixed;
+}
+
+.top-0 {
+ top: 0;
+}
+
+.zindex-100 {
+ z-index: 100;
+}
+
+.border-none {
+ border: none;
+}
+
+.outline-none {
+ outline: none;
+}
+
+.overflow-visible {
+ overflow: visible;
+}
+
+ol {
+ padding-right: 8px;
+}
diff --git a/skolehjem/resources/sass/app/general/_margins.scss b/skolehjem/resources/sass/app/general/_margins.scss
index 2dd4e99..b34a182 100644
--- a/skolehjem/resources/sass/app/general/_margins.scss
+++ b/skolehjem/resources/sass/app/general/_margins.scss
@@ -34,14 +34,46 @@
margin-top: 0;
}
+.pl-0 {
+ padding-left: 0;
+}
+
+.pr-0 {
+ padding-right: 0;
+}
+
+.pb-0 {
+ padding-bottom: 0;
+}
+
+.pt-0 {
+ padding-top: 0;
+}
+
+.m-none {
+ margin: 0;
+}
+
+.p-none {
+ padding: 0;
+}
+
.ml-1 {
margin-left: .75rem;
}
+.pl-1 {
+ padding-left: .75rem;
+}
+
.mr-1 {
margin-right: .75rem;
}
+.pr-1 {
+ padding-right: .75rem;
+}
+
.mb-1 {
margin-bottom: .75rem;
}
@@ -50,6 +82,10 @@
margin-top: .75rem;
}
+.pt-1 {
+ padding-top: .75rem;
+}
+
.ml-2 {
margin-left: 3rem;
}
@@ -62,10 +98,18 @@
margin-bottom: 3rem;
}
+.mb-2rem {
+ margin-bottom: 2rem;
+}
+
.mt-2 {
margin-top: 3rem;
}
+.mt-2rem {
+ margin-top: 2rem;
+}
+
.ml-3 {
margin-left: 3rem;
}
@@ -81,3 +125,7 @@
.mt-3 {
margin-top: 4.75rem;
}
+
+.ml-4px {
+ margin-left: 4px;
+}
diff --git a/skolehjem/resources/sass/app/general/_sizes.scss b/skolehjem/resources/sass/app/general/_sizes.scss
index a28ff4e..c345966 100644
--- a/skolehjem/resources/sass/app/general/_sizes.scss
+++ b/skolehjem/resources/sass/app/general/_sizes.scss
@@ -14,7 +14,6 @@ html, body {
}
a {
- color: #000000;
text-decoration: none;
}
@@ -42,6 +41,18 @@ a {
width: 15%;
}
+.w-1em {
+ width: 1em;
+}
+
+.w-6em {
+ width: 6em;
+}
+
+.w-7em {
+ width: 7em;
+}
+
.h-100 {
height: 100%;
}
@@ -58,6 +69,10 @@ a {
background-color: $sde-blue;
}
+.bg-white {
+ background-color: white;
+}
+
.block-container {
padding: 0 8px;
}
@@ -85,3 +100,19 @@ a {
align-self: center;
margin-left: 8px;
}
+
+.lh-2 {
+ line-height: 2rem;
+}
+
+.bs-cover {
+ background-size: cover;
+}
+
+.bp-center {
+ background-position: center;
+}
+
+.resize-vertical {
+ resize: vertical;;
+}
diff --git a/skolehjem/resources/sass/app/general/_texts.scss b/skolehjem/resources/sass/app/general/_texts.scss
index bea82f5..bd6c933 100644
--- a/skolehjem/resources/sass/app/general/_texts.scss
+++ b/skolehjem/resources/sass/app/general/_texts.scss
@@ -1,5 +1,9 @@
.text-white {
- color: #ffffff;
+ color: #fff;
+}
+
+.text-black {
+ color: #000;
}
.text-center {
@@ -41,3 +45,23 @@
span.toggle__text.sde-blue {
font-size: 5vw;
}
+
+.justify-content-center {
+ justify-content: center;
+}
+
+.justify-unset {
+ justify-content: unset;
+}
+
+.justify-content-space {
+ justify-content: space-between;
+}
+
+.event-text-shadow {
+ text-shadow: 2px 2px 2px #00788A;
+}
+
+.font-20px {
+ font-size: 20px;
+}
diff --git a/skolehjem/resources/sass/webapp/_default.scss b/skolehjem/resources/sass/webapp/_default.scss
index 8d6da6a..47f8fc8 100644
--- a/skolehjem/resources/sass/webapp/_default.scss
+++ b/skolehjem/resources/sass/webapp/_default.scss
@@ -554,3 +554,8 @@ $primary-color: $blue;
from {bottom: 30px; opacity: 1;}
to {bottom: 0; opacity: 0;}
}
+
+iframe {
+ width: 100%;
+}
+
diff --git a/skolehjem/resources/views/admin/contacts/index.blade.php b/skolehjem/resources/views/admin/contacts/index.blade.php
index 7d59118..b44bcd9 100644
--- a/skolehjem/resources/views/admin/contacts/index.blade.php
+++ b/skolehjem/resources/views/admin/contacts/index.blade.php
@@ -27,10 +27,10 @@
Navn " .
"Lokation " .
- " " .
- " " .
+ " " .
+ " " .
"E-mail
Tlf
@if(auth()->user()->can('contact.edit'))
-
+
@endif
@if(auth()->user()->can('contact.delete'))
-
+
@endif
diff --git a/skolehjem/resources/views/admin/events/edit.blade.php b/skolehjem/resources/views/admin/events/edit.blade.php
index 981f128..0d30e4f 100644
--- a/skolehjem/resources/views/admin/events/edit.blade.php
+++ b/skolehjem/resources/views/admin/events/edit.blade.php
@@ -24,7 +24,7 @@
Rediger Aktivitet:
-