diff --git a/application/controllers/Hyperviseur_dash.php b/application/controllers/Hyperviseur_dash.php index 630caaff..7635c282 100755 --- a/application/controllers/Hyperviseur_dash.php +++ b/application/controllers/Hyperviseur_dash.php @@ -1,5 +1,7 @@ input->get('show')) { $this->show_config_infos($this->input->get('show')); }else { + $context = new CustomContext(2); $data["commission"] = ""; $data["principal"] = ""; @@ -413,7 +416,7 @@ class Hyperviseur_dash extends CI_Controller array_push($data['transactions'], $trans); } } - $data["totalCommissionBanque"] = Money::of(round($totalCommissionBanque,0), $this->session->userdata('currency_code'), new AutoContext() )->formatTo('fr_FR'); + $data["totalCommissionBanque"] = Money::of(round($totalCommissionBanque,2), $this->session->userdata('currency_code'), $context )->formatTo('fr_FR'); } @@ -425,8 +428,8 @@ class Hyperviseur_dash extends CI_Controller } $row = $res->first_row(); - $data["commission"] = Money::of(round($row->balance_com,0), $this->session->userdata('currency_code'),new AutoContext())->formatTo('fr_FR'); - $data["principal"] = Money::of(round($row->balance_princ,0), $this->session->userdata('currency_code'),new AutoContext())->formatTo('fr_FR'); + $data["commission"] = Money::of(round($row->balance_com,2), $this->session->userdata('currency_code'),$context)->formatTo('fr_FR'); + $data["principal"] = Money::of(round($row->balance_princ,2), $this->session->userdata('currency_code'),$context)->formatTo('fr_FR'); $data['wallet_id'] = $row->wallet_id; $data['curreny_code'] = $this->session->userdata('currency_code'); diff --git a/application/models/User_model.php b/application/models/User_model.php index 5a8876bd..f3d723fa 100755 --- a/application/models/User_model.php +++ b/application/models/User_model.php @@ -2499,7 +2499,7 @@ class User_model extends CI_Model public function getPayingNetworksByConfigWallet($id_config){ $query = $this->db->query("SELECT n.name , n.id , cw.type , c.name as country ,c.currency_code, pw.taux_partage as rate , pw.balance_com FROM networks n INNER JOIN countries_currencies c ON n.country_id=c.id - INNER JOIN configWallet cw ON cw.id_network = n.id INNER JOIN paying_networks pw ON pw.id_network = n.id WHERE n.id IN ( SELECT id_network FROM paying_networks pw WHERE id_configWallet = $id_config )"); + INNER JOIN configWallet cw ON cw.id_network = n.id INNER JOIN paying_networks pw ON pw.id_network = n.id WHERE pw.id_configWallet = $id_config "); if($query->num_rows()>0){ return $query; }else{ diff --git a/application/views/gestion_wallet_autre.php b/application/views/gestion_wallet_autre.php index 3b172d20..45fc165e 100755 --- a/application/views/gestion_wallet_autre.php +++ b/application/views/gestion_wallet_autre.php @@ -8,8 +8,10 @@
-

code : 'XAF',new AutoContext())->formatTo('fr_FR'); ?>

+

code : 'XAF',$context)->formatTo('fr_FR'); ?>

lang->line('Solde Commission') ?>

diff --git a/application/views/gestion_wallet_ilink.php b/application/views/gestion_wallet_ilink.php index e4edf97d..96af15d3 100755 --- a/application/views/gestion_wallet_ilink.php +++ b/application/views/gestion_wallet_ilink.php @@ -8,8 +8,9 @@ - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) " . $walletHyper->first_row()->lastname . " - " . Money::of(round($walletHyper->first_row()->balance_princ, 0),$currency ? $currency->code : 'XAF',new AutoContext())->formatTo('fr_FR'). " - " .Money::of(round($walletHyper->first_row()->balance_com, 0), $currency ? $currency->code : 'XAF',new AutoContext())->formatTo('fr_FR'). " - " .Money::of(round($totalCommissionBanque,0), $currency ? $currency->code : 'XAF',new AutoContext())->formatTo('fr_FR') . ""; + " . Money::of(round($walletHyper->first_row()->balance_princ, 2),$currency ? $currency->code : 'XAF',$context)->formatTo('fr_FR'). " + " .Money::of(round($walletHyper->first_row()->balance_com, 2), $currency ? $currency->code : 'XAF',$context)->formatTo('fr_FR'). " + " .Money::of(round($totalCommissionBanque,2), $currency ? $currency->code : 'XAF',$context)->formatTo('fr_FR') . ""; echo "" . $depots->num_rows() . " " . $retraits->num_rows() . " diff --git a/application/views/gestion_wallet_ilink_hyp.php b/application/views/gestion_wallet_ilink_hyp.php index e48de399..85c6949e 100755 --- a/application/views/gestion_wallet_ilink_hyp.php +++ b/application/views/gestion_wallet_ilink_hyp.php @@ -93,8 +93,9 @@ - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) - Min (FCFA) - Max (FCFA) + Min + Max Taux (%) ".$row->lastname." - ".Money::of(round($princ,0), $this->session->userdata('currency_code'),new AutoContext())->formatTo('fr_FR')." - ".Money::of(round($com,0), $this->session->userdata('currency_code'),new AutoContext())->formatTo('fr_FR').""; + ".Money::of(round($princ,2), $this->session->userdata('currency_code'),$context)->formatTo('fr_FR')." + ".Money::of(round($com,2), $this->session->userdata('currency_code'),$context)->formatTo('fr_FR').""; $nb_depots = 0; $nb_retraits = 0; $commission_banque = 0; @@ -1030,7 +1031,7 @@ use Brick\Money\Money; $commission_banque+= $retrait->commission_banque; } } - echo "".Money::of(round($commission_banque,0), $this->session->userdata('currency_code'),new AutoContext())->formatTo('fr_FR')." + echo "".Money::of(round($commission_banque,2), $this->session->userdata('currency_code'),$context)->formatTo('fr_FR')." ".$nb_depots." ".$nb_retraits." "; @@ -1071,8 +1072,8 @@ use Brick\Money\Money; - - + + @@ -1112,8 +1113,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1153,8 +1154,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1194,8 +1195,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1255,8 +1256,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1296,8 +1297,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1337,8 +1338,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1378,8 +1379,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1425,8 +1426,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + @@ -1466,8 +1467,8 @@ use Brick\Money\Money;
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- - + + diff --git a/application/views/gestion_wallet_ilink_paying_network_account.php b/application/views/gestion_wallet_ilink_paying_network_account.php index 65a9f2da..2281091e 100755 --- a/application/views/gestion_wallet_ilink_paying_network_account.php +++ b/application/views/gestion_wallet_ilink_paying_network_account.php @@ -12,8 +12,9 @@
@@ -155,7 +156,7 @@ use Brick\Money\Money; }else{ $net = $row->montant_retrait ; } - $moneyNetInit = Money::of(round($net,0), $row->init_currency,new AutoContext()); + $moneyNetInit = Money::of(round($net,2), $row->init_currency,$context); $moneyNetFinal = $converter->convert($moneyNetInit, $row->final_currency ? $row->final_currency : 'XAF', RoundingMode::DOWN); echo "
@@ -164,12 +165,12 @@ use Brick\Money\Money; - - - - - - + + + + + + ";
Min (FCFA)Max (FCFA)MinMax lang->line('rate') ; ?> (%) Actions
- balance_com, 0),$row->currency_code ? $row->currency_code : 'XAF',new AutoContext())->formatTo('fr_FR')?> + balance_com,2 ),$row->currency_code ? $row->currency_code : 'XAF',$context)->formatTo('fr_FR')?>
$row->id".join(" ", str_split($row->numero_carte, 4))." ".$moneyNetInit->formatTo('fr_FR')." ".$moneyNetFinal->formatTo('fr_FR')."".Money::of(round($row->frais,0), $row->init_currency,new AutoContext())->formatTo('fr_FR')."".Money::of(round($row->taxe, 0),$row->init_currency,new AutoContext())->formatTo('fr_FR')."".Money::of(round($row->commission_banque ? $row->commission_banque : 0, 0),$row->init_currency,new AutoContext())->formatTo('fr_FR')."".Money::of(round($row->commission_hyp ? $row->commission_hyp : 0, 0),$row->init_currency,new AutoContext())->formatTo('fr_FR')."".Money::of(round($row->commission_sup ? $row->commission_sup : 0 , 0),$row->init_currency,new AutoContext())->formatTo('fr_FR')."".Money::of(round($row->commission_ag ? $row->commission_ag : 0, 0),$row->init_currency,new AutoContext())->formatTo('fr_FR')."".Money::of(round($row->frais,2), $row->init_currency,$context)->formatTo('fr_FR')."".Money::of(round($row->taxe, 2),$row->init_currency,$context)->formatTo('fr_FR')."".Money::of(round($row->commission_banque ? $row->commission_banque : 0, 2),$row->init_currency,$context)->formatTo('fr_FR')."".Money::of(round($row->commission_hyp ? $row->commission_hyp : 0, 2),$row->init_currency,$context)->formatTo('fr_FR')."".Money::of(round($row->commission_sup ? $row->commission_sup : 0 , 2),$row->init_currency,$context)->formatTo('fr_FR')."".Money::of(round($row->commission_ag ? $row->commission_ag : 0, 2),$row->init_currency,$context)->formatTo('fr_FR')." ".$row->agent." ".$row->user." ".toLocateDate($row->date,$this->session->userdata('timezone'))."