Merge branch '3.2.0' into 'dev'

Bug Fix

See merge request TheGamecraft/c-cms!37
This commit is contained in:
Mathieu Lagace
2019-08-21 14:54:47 +00:00
3 changed files with 6 additions and 6 deletions

View File

@@ -44,8 +44,8 @@ class EventController extends Controller
$event->type = request('type'); $event->type = request('type');
$event->user_id = \Auth::user()->id; $event->user_id = \Auth::user()->id;
$event->location = request('location'); $event->location = request('location');
if($event->is_mandatory){ if(request('is_mandatory') != null){
$event->is_mandatory = request('is_mandatory'); $event->is_mandatory = 1;
} else { } else {
$event->is_mandatory = 0; $event->is_mandatory = 0;
} }
@@ -124,8 +124,8 @@ class EventController extends Controller
$event->date_begin = request('begin'); $event->date_begin = request('begin');
$event->date_end = request('end'); $event->date_end = request('end');
$event->location = request('location'); $event->location = request('location');
if($event->is_mandatory){ if(request('is_mandatory') != null){
$event->is_mandatory = request('is_mandatory'); $event->is_mandatory = 1;
} else { } else {
$event->is_mandatory = 0; $event->is_mandatory = 0;
} }

View File

@@ -21,7 +21,7 @@
<div class="form-group"> <div class="form-group">
<label for="name">Lieux</label> <label for="name">Lieux</label>
<input type="text" name="location" id="location" class="form-control" placeholder="" aria-describedby="nameHelp" value="{{$activity->location}}" required> <input type="text" name="location" id="location" class="form-control" placeholder="" aria-describedby="nameHelp" value="{{$activity->location}}" required>
<small id="nameHelp" class="text-muted">Veuillez entrer le nom de l'événement</small> <small id="nameHelp" class="text-muted">Veuillez entrer le lieu de l'événement</small>
</div> </div>
</div> </div>
<div class="col-md-3 m-auto"> <div class="col-md-3 m-auto">

View File

@@ -13,7 +13,7 @@
<div class="col-md-6"> <div class="col-md-6">
<div class="btn-group"> <div class="btn-group">
<a class="btn btn-primary" href="/admin/schedule/edit/{{$event->id}}" data-toggle="tooltip" data-placement="bottom" title="Modifier"><i class="material-icons">edit</i></a> <a class="btn btn-primary" href="/admin/schedule/edit/{{$event->id}}" data-toggle="tooltip" data-placement="bottom" title="Modifier"><i class="material-icons">edit</i></a>
<a class="btn btn-primary" href="/admin/schedule/pdf/event/{{$event->id}}" target="_blank" data-toggle="tooltip" data-placement="bottom" title="Imprimer"><i class="material-icons">print</i></a> <a disabled class="btn btn-primary" href="/admin/schedule/pdf/event/{{$event->id}}" target="_blank" data-toggle="tooltip" data-placement="bottom" title="Imprimer"><i class="material-icons">print</i></a>
<button class="btn btn-danger" data-toggle="tooltip" data-placement="bottom" title="Supprimer" onclick="deleteEvent({{$event->id}})"><i class="material-icons">close</i></button> <button class="btn btn-danger" data-toggle="tooltip" data-placement="bottom" title="Supprimer" onclick="deleteEvent({{$event->id}})"><i class="material-icons">close</i></button>
</div> </div>
</div> </div>