From 2ecf785ca35aba33604cd47e0de60994194158c3 Mon Sep 17 00:00:00 2001 From: Djery-Tom Date: Tue, 23 Jun 2020 09:29:48 +0100 Subject: [PATCH] + Update countries list fields --- app/Http/Controllers/HelperController.php | 6 +++++- resources/lang/en/messages.php | 8 +++++--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/app/Http/Controllers/HelperController.php b/app/Http/Controllers/HelperController.php index a06867e..0621300 100755 --- a/app/Http/Controllers/HelperController.php +++ b/app/Http/Controllers/HelperController.php @@ -21,7 +21,7 @@ class HelperController extends Controller public function countries() { - $countries = DB::select('SELECT id , name , code_dial FROM countries_currencies WHERE id IN ( + $countries = DB::select('SELECT id , name , code_dial , code_country FROM countries_currencies WHERE id IN ( SELECT distinct c.id FROM networks n INNER JOIN countries_currencies c ON n.country_id=c.id INNER JOIN configWallet cw ON cw.id_network = n.id WHERE status = 1 );'); return $this->successResponse($countries); @@ -31,6 +31,10 @@ class HelperController extends Controller { $networks = DB::select('SELECT n.id , n.name , c.type FROM networks n INNER JOIN configWallet c ON c.id_network = n.id WHERE n.id IN ( SELECT distinct id_network FROM paying_networks ) AND status = 1 AND country_id = :id;',['id'=>$id_country]); + foreach ($networks as$network){ + if($network->type == 'ilink') + $network->type = 'ilink-world'; + } return $this->successResponse($networks); } diff --git a/resources/lang/en/messages.php b/resources/lang/en/messages.php index a6000bb..87c1ee9 100755 --- a/resources/lang/en/messages.php +++ b/resources/lang/en/messages.php @@ -49,9 +49,11 @@ Transaction information: Transaction information: - Transaction ID : :id_transaction - Amount of the transaction : :amount + - Country of departure: :init_country - Net amount of the country of departure : :net_init + - Country of destination: :final_country - Net amount of the destination country : :net_final - - Fees : :fees - - Tax : :tax - - Recipient wallet code : :code', + - Fees + Tax : :fees + - Number of the sending wallet: :sender_code + - Number of the recipient wallet: :receiver_code', ];