146 lines
8.6 KiB
PHP
Executable File
146 lines
8.6 KiB
PHP
Executable File
<?php
|
|
$total = count($prestataires);
|
|
$idReseau = $this->nettoyer($reseau['id']);
|
|
$libelleActuel = $this->nettoyer($reseau['libelle']);
|
|
$codeReseau = $this->nettoyer($reseau['codeReseau']);
|
|
?>
|
|
|
|
<div class="page-content animate__animated animate__fadeIn">
|
|
|
|
<div class="header-section mb-1">
|
|
<div class="d-flex align-items-center justify-content-between bg-white p-3 shadow border-start border-warning border-4" style="border-radius: var(--radius-md);">
|
|
<div class="d-flex align-items-center">
|
|
<div class="icon-shape bg-warning-light text-warning rounded-circle me-3" style="width: 45px; height: 45px; display: flex; align-items: center; justify-content: center;">
|
|
<i class="fas fa-edit fs-4"></i>
|
|
</div>
|
|
<div>
|
|
<h4 id="titre-page" class="mb-0 fw-bold text-uppercase fs-5 text-warning"><?= _("Modifier Réseau Soins") ?></h4>
|
|
<p class="text-muted small mb-0 d-none d-md-block"><?= _("Code :") ?> <span class="badge bg-light text-dark border"><?= $codeReseau ?></span> — <?= $libelleActuel ?></p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="d-flex gap-2">
|
|
<button type="button" class="btn btn-light rounded-pill px-4 fw-bold text-muted border shadow-sm btn-sm" onclick="retour_liste_reseaus();">
|
|
<i class="fas fa-times me-1"></i> <?= _("Annuler") ?>
|
|
</button>
|
|
<button type="button" id="btn_enreg" class="btn btn-warning rounded-pill px-4 fw-bold shadow-sm btn-sm text-light" onclick="enregistrer_modif_reseaus();">
|
|
<i class="fas fa-save me-1"></i> <?= _("Enregistrer les modifications") ?>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<form id="form_edit_reseau">
|
|
<input type="hidden" id="idReseau" name="idReseau" value="<?= $idReseau ?>">
|
|
|
|
<div class="row g-4 mb-1">
|
|
<div class="col-lg-5">
|
|
<div class="card border-0 shadow-sm h-100 bg-light">
|
|
<div class="card-header bg-transparent py-3 border-bottom border-primary-light">
|
|
<h6 class="mb-0 fw-bold text-muted text-uppercase"><i class="fas fa-history me-2"></i><?= _("Configuration Actuelle") ?></h6>
|
|
</div>
|
|
<div class="card-body p-4">
|
|
<div class="mb-3">
|
|
<label class="form-label small fw-bold text-muted"><?= _("Code Réseau") ?></label>
|
|
<input class="form-control border-0 bg-white" type="text" value="<?= $codeReseau ?>" readonly>
|
|
</div>
|
|
<div class="mb-0">
|
|
<label class="form-label small fw-bold text-muted"><?= _("Libellé") ?></label>
|
|
<input class="form-control border-0 bg-white majuscule fw-bold" type="text" value="<?= $libelleActuel ?>" readonly>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-lg-7">
|
|
<div class="card border-0 shadow-sm h-100 border-start border-warning border-4">
|
|
<div class="card-header bg-white py-3 border-bottom border-primary-light">
|
|
<h6 class="mb-0 fw-bold text-primary text-uppercase"><i class="fas fa-pen-fancy me-2"></i><?= _("Mise à jour du libellé") ?></h6>
|
|
</div>
|
|
<div class="card-body p-4">
|
|
<div class="row g-3">
|
|
<div class="col-md-4">
|
|
<label class="form-label small fw-bold text-muted text-uppercase"><?= _("Code") ?></label>
|
|
<input class="form-control bg-light border-2 fw-bold" type="text" id="codeReseau" name="codeReseau" value="<?= $codeReseau ?>" readonly>
|
|
</div>
|
|
<div class="col-md-8">
|
|
<label class="form-label small fw-bold text-muted text-uppercase"><?= _("Nouveau Libellé") ?> <span class="text-danger">*</span></label>
|
|
<div class="input-group">
|
|
<span class="input-group-text bg-white border-2 border-end-0 text-warning"><i class="fas fa-signature"></i></span>
|
|
<input class="form-control border-2 border-start-0 shadow-none majuscule fw-bold"
|
|
type="text" id="libelle" name="libelle"
|
|
value="<?= $libelleActuel ?>" required autofocus>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
|
|
<div class="card border-0 shadow-sm">
|
|
<div class="card-header bg-white py-3 d-flex justify-content-between align-items-center border-bottom border-primary-light">
|
|
<h6 class="mb-0 fw-bold text-primary text-uppercase small">
|
|
<i class="fas fa-hospital-user me-2"></i><?= _("Prestataires du Réseau") ?>
|
|
</h6>
|
|
<span class="badge bg-primary-ghost text-primary rounded-pill px-3 py-2">
|
|
<i class="fas fa-list-ol me-1"></i> <?= $total ?> <?= _("Lignes") ?>
|
|
</span>
|
|
</div>
|
|
<div class="card-body p-0">
|
|
<div class="table-responsive">
|
|
<table class="table table-hover align-middle mb-0 datatable-reseau-pres" style="width:100%; font-size: 9pt;">
|
|
<thead class="bg-light">
|
|
<tr>
|
|
<th class="py-3 ps-3 text-center" width="5%"><?= _("No") ?></th>
|
|
<th class="py-3 text-center" width="12%"><?= _("Code") ?></th>
|
|
<th class="py-3"><?= _("Nom du Prestataire") ?></th>
|
|
<th class="py-3 text-center" width="15%"><?= _("Type") ?></th>
|
|
<th class="py-3 text-center" width="15%"><?= _("Catégorie") ?></th>
|
|
<th class="py-3 pe-3"><?= _("Ville / Localité") ?></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<?php $i = 0; foreach ($prestataires as $v): ?>
|
|
<tr>
|
|
<td class="text-center text-muted small"><?= ++$i; ?></td>
|
|
<td class="text-center fw-bold text-primary"><?= $this->nettoyer($v['codePrestataire']) ?></td>
|
|
<td class="fw-bold"><?= $this->nettoyer($v['libelle']) ?></td>
|
|
<td class="text-center">
|
|
<span class="badge bg-light text-dark border fw-normal"><?= $this->nettoyer($v['typeprestataire']) ?></span>
|
|
</td>
|
|
<td class="text-center">
|
|
<?php $cat = $this->nettoyer($v['categoriePresataire']); ?>
|
|
<span class="badge rounded-pill <?= $cat == 'C' ? 'bg-info-light text-info' : 'bg-primary-ghost text-primary' ?>">
|
|
<?= $cat == 'C' ? _("Centre") : _("Prestataire") ?>
|
|
</span>
|
|
</td>
|
|
<td class="pe-3"><?= $this->nettoyer($v['localite']) ?></td>
|
|
</tr>
|
|
<?php endforeach; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<style>
|
|
.header-section.sticky-top { background-color: rgba(255, 255, 255, 0.95); backdrop-filter: blur(10px); }
|
|
.bg-warning-light { background-color: rgba(255, 193, 7, 0.15) !important; }
|
|
.bg-info-light { background-color: rgba(13, 202, 240, 0.1) !important; }
|
|
.border-primary-light { border-color: rgba(33, 46, 83, 0.1) !important; }
|
|
.majuscule { text-transform: uppercase; }
|
|
.form-control:focus { border-color: #ffc107 !important; box-shadow: 0 0 0 0.25rem rgba(255, 193, 7, 0.1) !important; }
|
|
.table-hover tbody tr:hover { background-color: rgba(33, 46, 83, 0.02); }
|
|
</style>
|
|
|
|
<script>
|
|
var checkDTResPres = setInterval(function() {
|
|
if (typeof initSmartTable === 'function') {
|
|
initSmartTable('.datatable-reseau-pres', 'Liste_Prestataires_Reseau', false);
|
|
clearInterval(checkDTResPres);
|
|
}
|
|
}, 100);
|
|
</script>
|