+ Fix bug
This commit is contained in:
parent
39981f3d1c
commit
36e42fd176
|
@ -575,6 +575,7 @@ class iLinkTransactionController extends Controller
|
|||
if (!$expiration_date)
|
||||
$expiration_date = new \DateTime();
|
||||
$transaction->expiration_date = $expiration_date;
|
||||
$transaction->final_country = $init_country;
|
||||
|
||||
$frais = floatval($request->montant * $config->taux_com_wallet_ag_carte_cash / 100);
|
||||
$montantRetrait = $transaction->montant - $frais;
|
||||
|
@ -747,6 +748,7 @@ class iLinkTransactionController extends Controller
|
|||
if (!$expiration_date)
|
||||
$expiration_date = new \DateTime();
|
||||
$transaction->expiration_date = $expiration_date;
|
||||
$transaction->final_country = $init_country;
|
||||
|
||||
$frais = $request->montant * $config->taux_com_wallet_ag_envoi_cash_carte / 100;
|
||||
$montantDepot = $transaction->montant - $frais;
|
||||
|
@ -921,6 +923,8 @@ class iLinkTransactionController extends Controller
|
|||
ORDER BY wit.date DESC LIMIT 10;', ['id_wallet' => $id_wallet_agent]);
|
||||
|
||||
foreach ($transactions as $data){
|
||||
$date = $data->date;
|
||||
unset($data->date);
|
||||
$wallet_user = isset($data->id_wallet_user) ? WalletsUser::findOrFail($data->id_wallet_user) : null ;
|
||||
$emetteur = $wallet_user ? $wallet_user->user->lastname.' '.$wallet_user->user->firstname : $data->prenom_emetteur . ' ' . $data->nom_emetteur;
|
||||
$destinataire = in_array($data->type,[12]) ? $emetteur : $data->prenom_destinataire . ' ' . $data->nom_destinataire;
|
||||
|
@ -932,7 +936,8 @@ class iLinkTransactionController extends Controller
|
|||
$data->montant = $this->toMoney($data->montant, $data->init_country);
|
||||
$data->init_country = $this->getCountryName($data->init_country);
|
||||
$data->final_country = $this->getCountryName($data->final_country);
|
||||
$data->reseau_payeur = isset($data->network_destinataire) ? $this->getNetworkName($data->network_destinataire) : null;
|
||||
$data->reseau_payeur = isset($data->network_destinataire) ? $this->getNetworkName($data->network_destinataire).' '.$data->final_country : null;
|
||||
$data->date = $date;
|
||||
unset($data->type, $data->id_wallet_user, $data->network_destinataire,$data->nom_destinataire, $data->prenom_destinataire ,$data->taxe,
|
||||
$data->montant_net_final_country, $data->montant_net,$data->nom_emetteur, $data->prenom_emetteur);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue