v1.5.9 Added and fixed preview, the only problem is that images on event, guide category and guide resource id is not display on the different pages

This commit is contained in:
neerholt
2021-04-10 01:43:05 +02:00
parent abe4a9dda9
commit dd7acc1d24
19 changed files with 530 additions and 262 deletions
+5
View File
@@ -26,6 +26,7 @@ class Helpers
return $html;
}
public static function sendNewsNotification(News $news, Collection $users){
$headers = 'Content-Transfer-Encoding: 8bit'. "\r\n".
'Content-Type: text/html; charset="UTF-8"';
@@ -40,6 +41,10 @@ class Helpers
$msg = "Hej " . $user->name_first . " ". $user->name_last . ".\n\nDer er kommet en ny nyhed i skolehjems appen! ";
//Hello, im here to help the future developer that has this problem,
//you have to open up you installed php version, find and
//open your php.ini and search for [mail function] and enter the
// right information and enable some stuff - Big Smoke
mail($email, $subject, $msg, $headers);
}
}
@@ -292,6 +292,7 @@ class EventController extends Controller
$convertToJsonArray = json_encode($event);
return $convertToJsonArray;
}
}
@@ -275,4 +275,11 @@ class GuideController extends Controller
return Response($output);
}
}
public function previewPages(Request $request){
$event = Guide::find($request->preview);
$convertToJsonArray = json_encode($event);
return $convertToJsonArray;
}
}
@@ -245,4 +245,11 @@ class MenuPlanController extends Controller
}
}
public function previewPages(Request $request){
$event = MenuPlan::find($request->preview);
$convertToJsonArray = json_encode($event);
return $convertToJsonArray;
}
}
@@ -181,4 +181,12 @@ class NewsController extends Controller
return 1;
}
}
public function previewPages(Request $request){
$event = News::find($request->preview);
$convertToJsonArray = json_encode($event);
return $convertToJsonArray;
}
}