Loading app/Http/Controllers/DiveSessionCreation.php +3 −0 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ class DiveSessionCreation extends Controller public static function add($request) { $dv = new DivingSession(); $dv->DS_CODE = 'DS'.sizeof(DivingSession::all())+1; $dv->US_ID = $request->pilot; $dv->DL_ID = $request->location; Loading @@ -27,6 +28,8 @@ public static function add($request) $dv->DS_MAX_DEPTH = DivingLocation::find($request->location)->DL_DEPTH; $dv->DS_ACTIVE = 1; $dv->DS_MAX_DIVERS = $request->max; $dv->DS_MIN_DIVERS = $request->min; if(intval($dv->DS_MAX_DIVERS) > Boat::find($request->boat)->BO_NUMBER_OF_SEATS) { return "Le nombre de plongeurs est supérieur au nombre de places du bateau"; Loading resources/views/create_dive.blade.php +6 −0 Original line number Diff line number Diff line Loading @@ -106,8 +106,14 @@ class="fa-solid fa-xmark"></i></button></form> <label for="maxInput">Maximum :</label> </div> <div class="divideFlexBig Column"> @if (isset($precedent)) <input required type="number" name="min" id="minInput" min="0" placeholder="0" style="width: 20%;-moz-appearance: textfield;text-align: center;" value="{{ $precedent->DS_MIN_DIVERS }}"> @else <input required type="number" name="min" id="minInput" min="0" placeholder="0" style="width: 20%;-moz-appearance: textfield;text-align: center;"> @endif @if (isset($precedent)) <input required type="number" name="max" id="maxInput" min="0" placeholder="0" style="width: 20%;-moz-appearance: textfield;text-align: center;" Loading resources/views/update_dive.blade.php +1 −0 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ { <p>{{$msg}}</p> } @endif <h2>Lieu</h2> <hr style="height: 3px;background-color: black;margin-bottom: 15px;margin-top: 5px; width : 40%"> <div class="aligne"> Loading Loading
app/Http/Controllers/DiveSessionCreation.php +3 −0 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ class DiveSessionCreation extends Controller public static function add($request) { $dv = new DivingSession(); $dv->DS_CODE = 'DS'.sizeof(DivingSession::all())+1; $dv->US_ID = $request->pilot; $dv->DL_ID = $request->location; Loading @@ -27,6 +28,8 @@ public static function add($request) $dv->DS_MAX_DEPTH = DivingLocation::find($request->location)->DL_DEPTH; $dv->DS_ACTIVE = 1; $dv->DS_MAX_DIVERS = $request->max; $dv->DS_MIN_DIVERS = $request->min; if(intval($dv->DS_MAX_DIVERS) > Boat::find($request->boat)->BO_NUMBER_OF_SEATS) { return "Le nombre de plongeurs est supérieur au nombre de places du bateau"; Loading
resources/views/create_dive.blade.php +6 −0 Original line number Diff line number Diff line Loading @@ -106,8 +106,14 @@ class="fa-solid fa-xmark"></i></button></form> <label for="maxInput">Maximum :</label> </div> <div class="divideFlexBig Column"> @if (isset($precedent)) <input required type="number" name="min" id="minInput" min="0" placeholder="0" style="width: 20%;-moz-appearance: textfield;text-align: center;" value="{{ $precedent->DS_MIN_DIVERS }}"> @else <input required type="number" name="min" id="minInput" min="0" placeholder="0" style="width: 20%;-moz-appearance: textfield;text-align: center;"> @endif @if (isset($precedent)) <input required type="number" name="max" id="maxInput" min="0" placeholder="0" style="width: 20%;-moz-appearance: textfield;text-align: center;" Loading
resources/views/update_dive.blade.php +1 −0 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ { <p>{{$msg}}</p> } @endif <h2>Lieu</h2> <hr style="height: 3px;background-color: black;margin-bottom: 15px;margin-top: 5px; width : 40%"> <div class="aligne"> Loading