2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- DataTables -->
|
|
|
|
|
<link rel="stylesheet"
|
2022-04-18 11:39:19 +00:00
|
|
|
|
href="<?= base_url('bower_components/datatables.net-bs/css/dataTables.bootstrap.min.css') ?>">
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.css"/>
|
|
|
|
|
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/buttons/1.6.2/css/buttons.dataTables.min.css">
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<link rel="stylesheet" href="<?= base_url('bower_components/toastr/toastr.css') ?>">
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<div class="content-wrapper">
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
use Brick\Money\Context\AutoContext;
|
|
|
|
|
use Brick\Money\CurrencyConverter;
|
2020-09-28 15:44:45 +00:00
|
|
|
|
use Brick\Money\ExchangeRateProvider\BaseCurrencyProvider;
|
2020-08-27 09:37:45 +00:00
|
|
|
|
use Brick\Money\ExchangeRateProvider\PDOProvider;
|
|
|
|
|
use Brick\Money\ExchangeRateProvider\PDOProviderConfiguration;
|
|
|
|
|
use Brick\Money\Money;
|
|
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
<!-- Content Header (Page header) -->
|
|
|
|
|
<section class="content-header">
|
|
|
|
|
|
|
|
|
|
<h1>
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<?= isset($category) ? 'Nano credit' : $this->lang->line('nano_credit_management');
|
2020-08-27 09:37:45 +00:00
|
|
|
|
echo ' ' . $network . ' - ' . $country
|
2020-08-31 16:34:03 +00:00
|
|
|
|
. ' :: ' . $this->lang->line('nano_credit_history'); ?>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- <input type="button" class="btn btn-primary pull-right" id="Bactiver"-->
|
|
|
|
|
<!-- value="Activer/Désactiver le(s) réseau(x)" />-->
|
|
|
|
|
</h1>
|
|
|
|
|
<?php
|
2021-10-14 14:33:02 +00:00
|
|
|
|
|
2020-08-27 09:37:45 +00:00
|
|
|
|
|
|
|
|
|
if ($alert == "ok") {
|
|
|
|
|
|
|
|
|
|
if (!$success == "ok") {
|
|
|
|
|
?>
|
|
|
|
|
<div class='alert alert-danger alert-dismissible col-xs-6'>
|
|
|
|
|
<button type='button' class='close' data-dismiss='alert' aria-hidden='true'>×</button>
|
|
|
|
|
<h4><i class='icon fa fa-ban'></i> Erreur!</h4>
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<?= $message; ?>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
} else {
|
|
|
|
|
?>
|
|
|
|
|
<div class="alert alert-success alert-dismissible col-xs-6">
|
|
|
|
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
|
|
|
|
<h4><i class="icon fa fa-check"></i> Success!</h4>
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<?= $message; ?>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
// set to whatever your rates are relative to
|
|
|
|
|
$baseCurrency = 'USD';
|
|
|
|
|
|
|
|
|
|
// use your own credentials, or re-use your existing PDO connection
|
|
|
|
|
$pdo = new PDO('mysql:host=' . $this->db->hostname . ';dbname=' . $this->db->database, $this->db->username, $this->db->password);
|
|
|
|
|
|
|
|
|
|
$configuration = new PDOProviderConfiguration();
|
|
|
|
|
|
|
|
|
|
$configuration->tableName = 'exchange_rate';
|
|
|
|
|
$configuration->exchangeRateColumnName = 'exchange_rate';
|
|
|
|
|
$configuration->targetCurrencyColumnName = 'target_currency';
|
|
|
|
|
$configuration->sourceCurrencyCode = $baseCurrency;
|
|
|
|
|
|
|
|
|
|
// this provider loads exchange rates from your database
|
|
|
|
|
$provider = new PDOProvider($pdo, $configuration);
|
|
|
|
|
|
|
|
|
|
// this provider calculates exchange rates relative to the base currency
|
|
|
|
|
$provider = new BaseCurrencyProvider($provider, $baseCurrency);
|
|
|
|
|
|
|
|
|
|
// this currency converter can now handle any currency pair
|
|
|
|
|
$converter = new CurrencyConverter($provider);
|
|
|
|
|
$context = new AutoContext();
|
|
|
|
|
?>
|
|
|
|
|
</section>
|
|
|
|
|
<section class="content">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-md-4 col-sm-6 col-xs-12">
|
|
|
|
|
<div class="info-box">
|
|
|
|
|
<span class="info-box-icon bg-aqua"><i class="ion ion-android-time"></i></span>
|
|
|
|
|
<div class="info-box-content">
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<span class="info-box-text"><?= $this->lang->line('Période') ?> </span>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<span class="info-box-number">
|
|
|
|
|
<input id="picker"
|
|
|
|
|
style="background: #fff; cursor: pointer; padding: 1px 1px; border: 1px solid #ccc; width: 100%"
|
2022-04-18 11:39:19 +00:00
|
|
|
|
data-category="<?= isset($category) ? $category : null ?>"
|
2020-08-27 09:37:45 +00:00
|
|
|
|
type="text" name="daterange"
|
2022-04-18 11:39:19 +00:00
|
|
|
|
data-lang="<?= $this->session->userdata('site_lang') ?>"
|
|
|
|
|
value="<?= ($startDate != null & $endDate != null) ? $startDate . ' - ' . $endDate : '' ?>"/>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
|
|
|
|
|
</span>
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<span> Format : <?= $this->session->userdata('site_lang') === 'french' ? 'Jour - Mois - Année ' : 'Year - Month - Day' ?> </span>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-xs-12">
|
|
|
|
|
<div class="box">
|
|
|
|
|
<div class="box-header">
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<h3 class="box-title"><?= $this->lang->line('export_nano_credit_demands_history') ?></h3>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
</div>
|
|
|
|
|
<div class="box-body" style="overflow-x:auto;">
|
|
|
|
|
<?php
|
|
|
|
|
if ($transactions){
|
|
|
|
|
$numrows = $transactions->num_rows();
|
|
|
|
|
$num = 0;
|
|
|
|
|
if ($numrows > 0) {
|
|
|
|
|
$fmt = new NumberFormatter('fr_FR', NumberFormatter::DECIMAL);
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
|
|
<table id="transactions" class="table table-bordered table-striped">
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th align='center'>ID</th>
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<th align='center'><?= $this->lang->line('state') ?></th>
|
|
|
|
|
<th align='center'><?= $this->lang->line('caution_type') ?></th>
|
|
|
|
|
<th align='center'><?= $this->lang->line('duration') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('refunded_amount') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('remains_to_be_reimbursed') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('interest') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('tax') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('agent_name') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('issuer_id') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('cash_withdrawal') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('validation_date') ?></th>
|
|
|
|
|
<th><?= $this->lang->line('repayment_date') ?></th>
|
|
|
|
|
<th align='center'><?= $this->lang->line('created_date') ?></th>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
foreach ($transactions->result() as $row) {
|
|
|
|
|
$num++;
|
|
|
|
|
if ($row->user_phone) {
|
|
|
|
|
$emetteur = $row->user_phone . ' | ' . $row->user;
|
|
|
|
|
} else {
|
|
|
|
|
$emetteur = ($row->nom_emetteur ? $row->nom_emetteur : '') . (' ' . $row->prenom_emetteur ? $row->prenom_emetteur : '');
|
|
|
|
|
}
|
|
|
|
|
$moneyNet = Money::of(round($row->montant, 2), $currency_code, $context);
|
|
|
|
|
if ($row->type_caution == 'individuel')
|
2020-11-20 16:26:51 +00:00
|
|
|
|
$retrait = $this->lang->line($row->retrait_cash ? 'Oui' : 'Non');
|
2020-08-27 09:37:45 +00:00
|
|
|
|
else
|
|
|
|
|
$retrait = "";
|
|
|
|
|
echo "<tr>
|
|
|
|
|
<td align='center' >$row->id_demande</td>
|
2020-11-20 16:26:51 +00:00
|
|
|
|
<td>" . $this->lang->line($row->etat) . "</td>
|
|
|
|
|
<td>" . $this->lang->line($row->type_caution) . "</td>
|
2021-11-04 17:01:59 +00:00
|
|
|
|
<td>" . mb_strtoupper($row->duree_mois,'UTF-8') . "</td>
|
2020-09-28 15:44:45 +00:00
|
|
|
|
<td>" . Money::of(round($row->montant_rembourse, 2), $currency_code, $context)->formatTo('fr_FR') . "</td>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<td>" . $moneyNet->formatTo('fr_FR') . "</td>
|
2020-08-31 16:34:03 +00:00
|
|
|
|
<td>" . Money::of(round($row->interet, 2), $currency_code, $context)->formatTo('fr_FR') . "</td>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<td>" . Money::of(round($row->taxe, 2), $currency_code, $context)->formatTo('fr_FR') . "</td>
|
|
|
|
|
<td>" . $row->agent . "</td>
|
|
|
|
|
<td>" . $emetteur . "</td>
|
|
|
|
|
<td>" . $retrait . "</td>
|
2020-11-13 16:39:13 +00:00
|
|
|
|
<td>" . $row->date_validation . "</td>
|
|
|
|
|
<td>" . $row->date_remboursement . "</td>
|
|
|
|
|
<td>" . $row->date_creation . "</td>";
|
2020-08-27 09:37:45 +00:00
|
|
|
|
?>
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
}
|
|
|
|
|
?>
|
|
|
|
|
</tbody>
|
|
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
} else {
|
|
|
|
|
echo $this->lang->line('Aucune demande');
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
echo $this->lang->line('Aucune demande');
|
|
|
|
|
}
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<!-- jQuery 3 -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('bower_components/jquery/dist/jquery.min.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- Bootstrap 3.3.7 -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('bower_components/bootstrap/dist/js/bootstrap.min.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- DataTables -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('bower_components/datatables.net/js/jquery.dataTables.min.js') ?>"></script>
|
|
|
|
|
<script src="<?= base_url('bower_components/datatables.net-bs/js/dataTables.bootstrap.min.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- SlimScroll -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('bower_components/jquery-slimscroll/jquery.slimscroll.min.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- FastClick -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('bower_components/fastclick/lib/fastclick.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- AdminLTE App -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('dist/js/adminlte.min.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
<!-- AdminLTE for demo purposes -->
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('dist/js/demo.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
|
|
|
|
|
<script type="text/javascript" src="https://cdn.jsdelivr.net/momentjs/latest/moment-with-locales.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.datatables.net/plug-ins/1.10.19/sorting/datetime-moment.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.datatables.net/plug-ins/1.10.20/dataRender/datetime.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.datatables.net/buttons/1.6.2/js/dataTables.buttons.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/pdfmake.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/vfs_fonts.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.datatables.net/buttons/1.6.2/js/buttons.html5.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.datatables.net/buttons/1.6.2/js/buttons.print.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="https://cdn.datatables.net/buttons/1.6.2/js/buttons.colVis.min.js"></script>
|
2022-04-18 11:39:19 +00:00
|
|
|
|
<script src="<?= base_url('dist/js/sweetalert2.js') ?>"></script>
|
|
|
|
|
<script src="<?= base_url('bower_components/toastr/toastr.js') ?>"></script>
|
2020-08-27 09:37:45 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
$(function () {
|
|
|
|
|
const lang = $('#picker').data('lang');
|
|
|
|
|
const format = lang === 'french' ? 'fr' : 'en';
|
|
|
|
|
moment.updateLocale(moment.locale(format), {invalidDate: ""}); // Blank text when is invalid date
|
|
|
|
|
var table = $('#transactions').DataTable({
|
2020-09-28 15:44:45 +00:00
|
|
|
|
"aaSorting": [[13, "desc"]],
|
2020-08-27 09:37:45 +00:00
|
|
|
|
"columnDefs": [{
|
2020-09-28 15:44:45 +00:00
|
|
|
|
targets: [11, 12, 13],
|
2020-08-27 09:37:45 +00:00
|
|
|
|
render: $.fn.dataTable.render.moment('YYYY-MM-DD HH:mm:ss', 'D MMMM YYYY HH:mm:ss', format)
|
|
|
|
|
}],
|
|
|
|
|
dom: 'Bfrtip',
|
|
|
|
|
"buttons": [
|
|
|
|
|
'pageLength',
|
|
|
|
|
{
|
|
|
|
|
extend: 'excelHtml5',
|
2020-10-03 11:14:16 +00:00
|
|
|
|
title: "<?= $this->lang->line('nano_credit_history') ?>",
|
2020-08-27 09:37:45 +00:00
|
|
|
|
customizeData: function (data) {
|
|
|
|
|
for (var i = 0; i < data.body.length; i++) {
|
|
|
|
|
for (var j = 0; j < data.body[i].length; j++) {
|
|
|
|
|
// data.body[i][j] = '\u200C' + data.body[i][j];
|
2020-10-03 11:14:16 +00:00
|
|
|
|
if ([4, 5, 6, 7].includes(j)) {
|
2020-08-27 09:37:45 +00:00
|
|
|
|
// Get the value and strip the non numeric characters
|
|
|
|
|
// var value = $(this).text();
|
|
|
|
|
value = data.body[i][j].replace(',', ".")
|
|
|
|
|
data.body[i][j] = Number(value.replace(/[^0-9\.-]+/g, ""));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
trim: false
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
extend: 'csvHtml5',
|
2020-10-03 11:14:16 +00:00
|
|
|
|
title: "<?= $this->lang->line('nano_credit_history') ?>",
|
2020-08-27 09:37:45 +00:00
|
|
|
|
trim: false
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
extend: 'pdfHtml5',
|
|
|
|
|
orientation: 'landscape',
|
|
|
|
|
pageSize: 'LEGAL',
|
2020-10-03 11:14:16 +00:00
|
|
|
|
title: "<?= $this->lang->line('nano_credit_history') ?>",
|
2020-08-27 09:37:45 +00:00
|
|
|
|
trim: false
|
|
|
|
|
},
|
|
|
|
|
// 'colvis'
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
table.buttons().container()
|
|
|
|
|
.appendTo('#example_wrapper .col-sm-6:eq(0)');
|
|
|
|
|
});
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
var startDate;
|
|
|
|
|
var endDate;
|
|
|
|
|
|
|
|
|
|
$(function () {
|
|
|
|
|
const lang = $('#picker').data('lang');
|
|
|
|
|
const category = $('#picker').data('category');
|
2020-10-03 11:14:16 +00:00
|
|
|
|
const id_network = "<?= $id_network?>";
|
2020-08-27 09:37:45 +00:00
|
|
|
|
$('input[name="daterange"]').daterangepicker({
|
|
|
|
|
opens: 'left',
|
|
|
|
|
autoUpdateInput: false,
|
|
|
|
|
locale: {
|
|
|
|
|
format: lang === 'french' ? 'DD-MM-YYYY' : 'YYYY-MM-DD',
|
|
|
|
|
cancelLabel: 'Clear'
|
|
|
|
|
}
|
|
|
|
|
}, function (start, end, label) {
|
|
|
|
|
const debut = start.format('YYYY-MM-DD');
|
|
|
|
|
const fin = end.format('YYYY-MM-DD');
|
2020-09-28 15:44:45 +00:00
|
|
|
|
if (category){
|
|
|
|
|
if(category == 'super')
|
2022-04-18 11:39:19 +00:00
|
|
|
|
window.location = "<?= current_url()?>" + "?d=" + debut + "&f=" + fin;
|
2020-09-28 15:44:45 +00:00
|
|
|
|
else
|
2022-04-18 11:39:19 +00:00
|
|
|
|
window.location = "<?= current_url()?>" + "?history=nano_credit" + "&d=" + debut + "&f=" + fin;
|
2020-09-28 15:44:45 +00:00
|
|
|
|
|
|
|
|
|
}
|
2020-08-27 09:37:45 +00:00
|
|
|
|
else
|
2022-04-18 11:39:19 +00:00
|
|
|
|
window.location = "<?= current_url()?>" + "?id="+id_network+"&history=nano_credit" + "&d=" + debut + "&f=" + fin;
|
2020-08-27 09:37:45 +00:00
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$('input[name="daterange"]').on('cancel.daterangepicker', function (ev, picker) {
|
|
|
|
|
//do something, like clearing an input
|
|
|
|
|
$('#daterange').val('');
|
2020-09-28 15:44:45 +00:00
|
|
|
|
if (category){
|
|
|
|
|
if(category == 'super')
|
2022-04-18 11:39:19 +00:00
|
|
|
|
window.location = "<?= current_url()?>";
|
2020-09-28 15:44:45 +00:00
|
|
|
|
else
|
2022-04-18 11:39:19 +00:00
|
|
|
|
window.location = "<?= current_url()?>" + "?history=nano_credit";
|
2020-09-28 15:44:45 +00:00
|
|
|
|
}
|
2020-08-27 09:37:45 +00:00
|
|
|
|
else
|
2022-04-18 11:39:19 +00:00
|
|
|
|
window.location = "<?= current_url()?>" + "?id="+id_network+"&history=nano_credit";
|
2020-08-27 09:37:45 +00:00
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
</script>
|
|
|
|
|
<script>
|
|
|
|
|
$(document).on("click", "#cancel", function () {
|
|
|
|
|
const id_transaction = $(this).data('id-transaction');
|
|
|
|
|
$.ajax({
|
2022-04-18 11:39:19 +00:00
|
|
|
|
url: '<?= base_url('Gestion/cancelIlinkTransation')?>',
|
2020-08-27 09:37:45 +00:00
|
|
|
|
type: 'POST',
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
data: {"id_transaction": id_transaction},
|
|
|
|
|
async: true,
|
|
|
|
|
success: function (data) {
|
|
|
|
|
if (data) {
|
|
|
|
|
Swal.fire({
|
|
|
|
|
icon: 'success',
|
2022-04-18 11:39:19 +00:00
|
|
|
|
title: "<?= $this->lang->line('canceled_transaction')?>",
|
|
|
|
|
text: "<?= $this->lang->line('informations_updated')?>",
|
2020-08-27 09:37:45 +00:00
|
|
|
|
timer: 3000
|
|
|
|
|
}).then(() => {
|
|
|
|
|
location.reload();
|
|
|
|
|
});
|
|
|
|
|
// alert("Les informations ont été mises à jour.") ? "" : location.reload();
|
|
|
|
|
} else {
|
2022-04-18 11:39:19 +00:00
|
|
|
|
toastr.error("<?= $this->lang->line('error_message')?>", "<?= $this->lang->line('request_error')?>");
|
2020-08-27 09:37:45 +00:00
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
error: function (resultat, statut, erreur) {
|
|
|
|
|
console.log(resultat + " " + erreur);
|
2022-04-18 11:39:19 +00:00
|
|
|
|
toastr.error("<?= $this->lang->line('error_message')?>", "<?= $this->lang->line('request_error')?>");
|
2020-08-27 09:37:45 +00:00
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
</script>
|