Loading app/Http/Controllers/DivingNumberController.php +11 −0 Original line number Diff line number Diff line Loading @@ -48,6 +48,17 @@ public function index(): View 'datesA' => $dateDivesAfter]); } public static function getDivingNumber($userId): int { $usersCount = DivingNumberModel::join('CAR_REGISTRATION', 'CAR_USER.us_id', '=', 'CAR_REGISTRATION.us_id') ->join('CAR_DIVING_SESSION', 'CAR_REGISTRATION.ds_code', '=', 'CAR_DIVING_SESSION.ds_code') ->where('CAR_USER.us_id', $userId) ->whereYear('CAR_DIVING_SESSION.ds_date', '=', now()->year) ->count(); $usersCount = 99 - $usersCount ; return $usersCount; } public function allIndex(Request $request): View { Loading public/js/Palanque/manualPalanque.js +6 −0 Original line number Diff line number Diff line Loading @@ -178,6 +178,12 @@ function removePalanqueZone(nbZone) { }); } /** * To-Do * * 1. Faire fonctionner la suppression des palanquées en gérant l'ID de ces dernières qui est inconsistent */ async function getDiver(ds_code) { let response = await fetch(`/api/dives/${ds_code}/divers`); let data = await response.json().then((data) => proccessDiverData(data)); Loading resources/views/components/header.blade.php +1 −0 Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ </x-button> </a> @else <p class="text-white mr-4">{{ App\Http\Controllers\DivingNumberController::getDivingNumber(session('user')->US_ID) }} / 99</p> <button type="button" class="flex text-sm bg-blue-500 rounded-full md:me-0 focus:ring-4 focus:ring-blue-700" id="user-menu-button" aria-expanded="false" data-dropdown-toggle="user-dropdown" Loading Loading
app/Http/Controllers/DivingNumberController.php +11 −0 Original line number Diff line number Diff line Loading @@ -48,6 +48,17 @@ public function index(): View 'datesA' => $dateDivesAfter]); } public static function getDivingNumber($userId): int { $usersCount = DivingNumberModel::join('CAR_REGISTRATION', 'CAR_USER.us_id', '=', 'CAR_REGISTRATION.us_id') ->join('CAR_DIVING_SESSION', 'CAR_REGISTRATION.ds_code', '=', 'CAR_DIVING_SESSION.ds_code') ->where('CAR_USER.us_id', $userId) ->whereYear('CAR_DIVING_SESSION.ds_date', '=', now()->year) ->count(); $usersCount = 99 - $usersCount ; return $usersCount; } public function allIndex(Request $request): View { Loading
public/js/Palanque/manualPalanque.js +6 −0 Original line number Diff line number Diff line Loading @@ -178,6 +178,12 @@ function removePalanqueZone(nbZone) { }); } /** * To-Do * * 1. Faire fonctionner la suppression des palanquées en gérant l'ID de ces dernières qui est inconsistent */ async function getDiver(ds_code) { let response = await fetch(`/api/dives/${ds_code}/divers`); let data = await response.json().then((data) => proccessDiverData(data)); Loading
resources/views/components/header.blade.php +1 −0 Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ </x-button> </a> @else <p class="text-white mr-4">{{ App\Http\Controllers\DivingNumberController::getDivingNumber(session('user')->US_ID) }} / 99</p> <button type="button" class="flex text-sm bg-blue-500 rounded-full md:me-0 focus:ring-4 focus:ring-blue-700" id="user-menu-button" aria-expanded="false" data-dropdown-toggle="user-dropdown" Loading