Loading app/Http/Controllers/DiveSessionCreation.php +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ public static function add($request) $dv->DS_MAX_DEPTH = $request->maxDepth; $dv->DS_ACTIVE = 1; $dv->DS_MAX_DIVERS = $request->max; $dv->DS_LEVEL = $request->level; $dv->DS_LEVEL = 1; $dv->save(); return $dv; } Loading resources/views/create_dive.blade.php +7 −3 Original line number Diff line number Diff line Loading @@ -4,7 +4,7 @@ <div style="display : flex; flex-direction: row"> <div style="width: 50%; margin-right: 50px; height: 100%; display:flex; align-items: center; flex-direction: column"> @if(!isset($precedent)) @if(!isset($previousDives)) <img src="{{ asset('/images/Diver1.png') }}" alt="Diver illustration"> @else <p>Plongées crées</p> Loading @@ -15,11 +15,15 @@ <th>Site</th> <th>Niveau requis</th> </tr> @foreach ($precedent as $dive) @foreach ($previousDives as $dive) <tr> <td>{{ $dive->DS_DATE }}</td> <td>{{ $dive->DS_MAX_DIVERS }}</td> <td>{{ $dive->DL_NAME }}</td> @foreach($locations as $location) @if($location->DL_ID == $dive->DL_ID) <td>{{ $location->DL_NAME }}</td> @endif @endforeach <td>{{ $dive->PRE_CODE }}</td> </tr> @endforeach Loading routes/web.php +1 −1 Original line number Diff line number Diff line Loading @@ -75,7 +75,7 @@ session(['previousDives' => $previousDives]); return view('create_dive', ['locations' => DivingLocation::all(), 'boats' => Boat::all(), 'levels' => Prerogative::all(), 'users' => User::all(), 'precedent' => $pre]); return view('create_dive', ['locations' => DivingLocation::all(), 'boats' => Boat::all(), 'levels' => Prerogative::all(), 'users' => User::all(), 'precedent' => $pre, 'previousDives' => $previousDives]); }); Route::get('/tewst2', function(){ Loading Loading
app/Http/Controllers/DiveSessionCreation.php +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ public static function add($request) $dv->DS_MAX_DEPTH = $request->maxDepth; $dv->DS_ACTIVE = 1; $dv->DS_MAX_DIVERS = $request->max; $dv->DS_LEVEL = $request->level; $dv->DS_LEVEL = 1; $dv->save(); return $dv; } Loading
resources/views/create_dive.blade.php +7 −3 Original line number Diff line number Diff line Loading @@ -4,7 +4,7 @@ <div style="display : flex; flex-direction: row"> <div style="width: 50%; margin-right: 50px; height: 100%; display:flex; align-items: center; flex-direction: column"> @if(!isset($precedent)) @if(!isset($previousDives)) <img src="{{ asset('/images/Diver1.png') }}" alt="Diver illustration"> @else <p>Plongées crées</p> Loading @@ -15,11 +15,15 @@ <th>Site</th> <th>Niveau requis</th> </tr> @foreach ($precedent as $dive) @foreach ($previousDives as $dive) <tr> <td>{{ $dive->DS_DATE }}</td> <td>{{ $dive->DS_MAX_DIVERS }}</td> <td>{{ $dive->DL_NAME }}</td> @foreach($locations as $location) @if($location->DL_ID == $dive->DL_ID) <td>{{ $location->DL_NAME }}</td> @endif @endforeach <td>{{ $dive->PRE_CODE }}</td> </tr> @endforeach Loading
routes/web.php +1 −1 Original line number Diff line number Diff line Loading @@ -75,7 +75,7 @@ session(['previousDives' => $previousDives]); return view('create_dive', ['locations' => DivingLocation::all(), 'boats' => Boat::all(), 'levels' => Prerogative::all(), 'users' => User::all(), 'precedent' => $pre]); return view('create_dive', ['locations' => DivingLocation::all(), 'boats' => Boat::all(), 'levels' => Prerogative::all(), 'users' => User::all(), 'precedent' => $pre, 'previousDives' => $previousDives]); }); Route::get('/tewst2', function(){ Loading