diff --git a/app/Http/Controllers/UserGroupController.php b/app/Http/Controllers/UserGroupController.php index 5817ce8..c90bc34 100755 --- a/app/Http/Controllers/UserGroupController.php +++ b/app/Http/Controllers/UserGroupController.php @@ -644,7 +644,7 @@ ug.date_creation , ug.createur , ug.sponsor1 , ug.sponsor2 , ug.sponsor3, ug.cou } } - private function checkUserIdentification($id_user, $id) + public function checkUserIdentification($id_user, $id) { $identification = Identification::where('id_user', $id_user)->first(); if (isset($identification)) { diff --git a/app/Http/Controllers/WalletController.php b/app/Http/Controllers/WalletController.php index 49f2ac7..ba7a0af 100755 --- a/app/Http/Controllers/WalletController.php +++ b/app/Http/Controllers/WalletController.php @@ -365,13 +365,13 @@ class WalletController extends Controller /** * @OA\Get( - * path="/wallets/users/operators/{type_operator}/{id_wallet_network}", + * path="/wallets/users/operators/{type}/{id_wallet_network}", * summary="Afficher la liste des opérateurs d'un reseau", * tags={"Liste des opérateurs d'un reseau"}, * security={{"api_key":{}}}, * @OA\Parameter( - * parameter="type_operator", - * name="type_operator", + * parameter="type", + * name="type", * description="Type d'operateur", * in="path", * required=true, @@ -411,10 +411,10 @@ class WalletController extends Controller * ) */ - public function getWalletOperators($id_wallet_network, $type_operator) + public function getWalletOperators($type, $id_wallet_network) { $operators = DB::select("SELECT oc.id as id_operator, o.nom as operator_name , oc.adresse as operator_address, c.name as country FROM networks_operators nop INNER JOIN operators_countries oc ON oc.id = nop.id_operator_country INNER JOIN operators o ON o.id = oc.id_operator -INNER JOIN countries c ON oc.id_country = c.id INNER JOIN type_operators top ON o.type = top.code WHERE nop.id_network = :id_network AND o.type = :type_operator ;", ['id_network' => $id_wallet_network, 'type_operator' => $type_operator]); +INNER JOIN countries c ON oc.id_country = c.id INNER JOIN type_operators top ON o.type = top.code WHERE nop.id_network = :id_network AND o.type = :type_operator ;", ['id_network' => $id_wallet_network, 'type_operator' => $type]); return $this->successResponse($operators); }