Autosave: 20260514-223800
|
Before Width: | Height: | Size: 232 KiB |
|
After Width: | Height: | Size: 191 KiB |
BIN
assets/uploads/vouchers/6a03487b6398f-629.png
Normal file
|
After Width: | Height: | Size: 274 KiB |
BIN
assets/uploads/vouchers/6a035159032d3-602.png
Normal file
|
After Width: | Height: | Size: 301 KiB |
BIN
assets/uploads/vouchers/6a0358c17e1b3-Screenshot_323.png
Normal file
|
After Width: | Height: | Size: 366 KiB |
BIN
assets/uploads/vouchers/6a03715590828-Screenshot_324.png
Normal file
|
After Width: | Height: | Size: 266 KiB |
BIN
assets/uploads/vouchers/6a037664c84a3-Screenshot_325.png
Normal file
|
After Width: | Height: | Size: 464 KiB |
|
After Width: | Height: | Size: 211 KiB |
|
After Width: | Height: | Size: 277 KiB |
BIN
assets/uploads/vouchers/6a0381d926033-919.png
Normal file
|
After Width: | Height: | Size: 327 KiB |
BIN
assets/uploads/vouchers/6a03825998c72-6592.png
Normal file
|
After Width: | Height: | Size: 332 KiB |
BIN
assets/uploads/vouchers/6a038394da6eb-785.png
Normal file
|
After Width: | Height: | Size: 323 KiB |
BIN
assets/uploads/vouchers/6a038411aa443-240.png
Normal file
|
After Width: | Height: | Size: 313 KiB |
BIN
assets/uploads/vouchers/6a0385fe32c0c-5148.png
Normal file
|
After Width: | Height: | Size: 303 KiB |
BIN
assets/uploads/vouchers/6a03871e70296-121.png
Normal file
|
After Width: | Height: | Size: 268 KiB |
BIN
assets/uploads/vouchers/6a0387bade73b-4148.png
Normal file
|
After Width: | Height: | Size: 273 KiB |
BIN
assets/uploads/vouchers/6a03886f81ee2-1757.png
Normal file
|
After Width: | Height: | Size: 270 KiB |
BIN
assets/uploads/vouchers/6a03891781396-940.png
Normal file
|
After Width: | Height: | Size: 332 KiB |
BIN
assets/uploads/vouchers/6a038a1ee9f0b-826.png
Normal file
|
After Width: | Height: | Size: 303 KiB |
BIN
assets/uploads/vouchers/6a038d6ab20d9-902.png
Normal file
|
After Width: | Height: | Size: 392 KiB |
BIN
assets/uploads/vouchers/6a038e32d3768-187.png
Normal file
|
After Width: | Height: | Size: 309 KiB |
|
After Width: | Height: | Size: 302 KiB |
|
After Width: | Height: | Size: 39 KiB |
|
After Width: | Height: | Size: 44 KiB |
|
After Width: | Height: | Size: 230 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 38 KiB |
|
After Width: | Height: | Size: 37 KiB |
|
After Width: | Height: | Size: 256 KiB |
|
After Width: | Height: | Size: 48 KiB |
|
After Width: | Height: | Size: 49 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 38 KiB |
|
After Width: | Height: | Size: 54 KiB |
|
After Width: | Height: | Size: 39 KiB |
BIN
assets/uploads/vouchers/6a03a4146ed68-Screenshot_50.png
Normal file
|
After Width: | Height: | Size: 135 KiB |
|
After Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 217 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
After Width: | Height: | Size: 51 KiB |
BIN
assets/uploads/vouchers/6a03b10834b8e-895.png
Normal file
|
After Width: | Height: | Size: 425 KiB |
BIN
assets/uploads/vouchers/6a03b1fdd4ea4-100.png
Normal file
|
After Width: | Height: | Size: 357 KiB |
BIN
assets/uploads/vouchers/6a03b363a9e24-093.png
Normal file
|
After Width: | Height: | Size: 322 KiB |
BIN
assets/uploads/vouchers/6a03b98a561bb-980.png
Normal file
|
After Width: | Height: | Size: 325 KiB |
|
After Width: | Height: | Size: 258 KiB |
BIN
assets/uploads/vouchers/6a04af72e1af3-696.png
Normal file
|
After Width: | Height: | Size: 291 KiB |
BIN
assets/uploads/vouchers/6a04afcac53e4-696.png
Normal file
|
After Width: | Height: | Size: 291 KiB |
BIN
assets/uploads/vouchers/6a04b7c083103-1131.png
Normal file
|
After Width: | Height: | Size: 343 KiB |
|
After Width: | Height: | Size: 253 KiB |
BIN
assets/uploads/vouchers/6a04d44694ac2-4547.png
Normal file
|
After Width: | Height: | Size: 288 KiB |
BIN
assets/uploads/vouchers/6a04dfb40f2e5-567.png
Normal file
|
After Width: | Height: | Size: 350 KiB |
|
After Width: | Height: | Size: 198 KiB |
|
After Width: | Height: | Size: 214 KiB |
|
After Width: | Height: | Size: 245 KiB |
|
After Width: | Height: | Size: 165 KiB |
|
After Width: | Height: | Size: 244 KiB |
BIN
assets/uploads/vouchers/6a05df540864b-Screenshot_327.png
Normal file
|
After Width: | Height: | Size: 269 KiB |
|
After Width: | Height: | Size: 373 KiB |
BIN
assets/uploads/vouchers/6a05e374d97bb-717.png
Normal file
|
After Width: | Height: | Size: 272 KiB |
BIN
assets/uploads/vouchers/6a05ee598ed89-Screenshot_328.png
Normal file
|
After Width: | Height: | Size: 240 KiB |
BIN
assets/uploads/vouchers/6a05f1247ff4a-Screenshot_329.png
Normal file
|
After Width: | Height: | Size: 227 KiB |
BIN
assets/uploads/vouchers/6a05f685069e9-Screenshot_330.png
Normal file
|
After Width: | Height: | Size: 236 KiB |
BIN
assets/uploads/vouchers/6a05f72c28a59-Screenshot_331.png
Normal file
|
After Width: | Height: | Size: 240 KiB |
BIN
assets/uploads/vouchers/6a05f8ba545ec-Screenshot_327.png
Normal file
|
After Width: | Height: | Size: 269 KiB |
BIN
assets/uploads/vouchers/6a05fca04396a-231.png
Normal file
|
After Width: | Height: | Size: 410 KiB |
BIN
assets/uploads/vouchers/6a06024ea1597-477.png
Normal file
|
After Width: | Height: | Size: 417 KiB |
BIN
assets/uploads/vouchers/6a060595b4609-Screenshot_333.png
Normal file
|
After Width: | Height: | Size: 240 KiB |
BIN
assets/uploads/vouchers/6a0606294624c-Screenshot_327.png
Normal file
|
After Width: | Height: | Size: 269 KiB |
BIN
assets/uploads/vouchers/6a0606965a61d-Screenshot_335.png
Normal file
|
After Width: | Height: | Size: 248 KiB |
BIN
assets/uploads/vouchers/6a0607207cb2d-Screenshot_337.png
Normal file
|
After Width: | Height: | Size: 335 KiB |
BIN
assets/uploads/vouchers/6a060a995bfc1-Screenshot_338.png
Normal file
|
After Width: | Height: | Size: 229 KiB |
BIN
assets/uploads/vouchers/6a060b1621c7c-Screenshot_339.png
Normal file
|
After Width: | Height: | Size: 251 KiB |
BIN
assets/uploads/vouchers/6a060d88559d3-235.png
Normal file
|
After Width: | Height: | Size: 531 KiB |
|
After Width: | Height: | Size: 262 KiB |
|
After Width: | Height: | Size: 372 KiB |
|
After Width: | Height: | Size: 281 KiB |
BIN
assets/uploads/vouchers/6a063f80144a4-146.png
Normal file
|
After Width: | Height: | Size: 289 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 44 KiB |
|
After Width: | Height: | Size: 40 KiB |
|
After Width: | Height: | Size: 44 KiB |
|
After Width: | Height: | Size: 45 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
After Width: | Height: | Size: 45 KiB |
|
After Width: | Height: | Size: 64 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 46 KiB |
BIN
assets/uploads/vouchers/6a064ac147143-Screenshot_340.png
Normal file
|
After Width: | Height: | Size: 256 KiB |
|
After Width: | Height: | Size: 47 KiB |
|
After Width: | Height: | Size: 121 KiB |
|
After Width: | Height: | Size: 39 KiB |
|
After Width: | Height: | Size: 56 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 39 KiB |
@ -188,7 +188,22 @@ try {
|
||||
<?php endif; ?>
|
||||
<td><?php echo htmlspecialchars($pedido['codigo_rastreo'] ?? 'N/A'); ?></td>
|
||||
<td><?php echo htmlspecialchars($pedido['codigo_tracking'] ?? 'N/A'); ?></td>
|
||||
<td><?php echo htmlspecialchars($pedido['clave'] ?? 'N/A'); ?></td>
|
||||
<td>
|
||||
<?php
|
||||
$show_clave = true;
|
||||
if ($user_role === 'Asesor') {
|
||||
$estado_actual = strtoupper(trim($pedido['estado']));
|
||||
if ($estado_actual !== 'COMPLETADO' && $estado_actual !== 'COMPLETADO ✅') {
|
||||
$show_clave = false;
|
||||
}
|
||||
}
|
||||
if ($show_clave) {
|
||||
echo htmlspecialchars($pedido['clave'] ?? 'N/A');
|
||||
} else {
|
||||
echo '<i class="fas fa-eye-slash text-muted" title="Suba el número de operación y seleccione el banco para ver la clave"></i> <span class="text-muted" style="font-size: 0.8rem;">Oculto</span>';
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
<td><span class="badge" style="<?php echo getStatusStyle($pedido['estado']); ?>"><?php echo htmlspecialchars($pedido['estado']); ?></span></td>
|
||||
<?php if ($user_role !== 'Asesor'): ?><td><?php echo htmlspecialchars($pedido['asesor_nombre'] ?? 'N/A'); ?></td><?php endif; ?>
|
||||
<td><?php echo htmlspecialchars($pedido['created_at']); ?></td>
|
||||
|
||||
@ -43,6 +43,7 @@ try {
|
||||
$output = '<html><head><meta charset="utf-8">
|
||||
<style>
|
||||
.text { mso-number-format:"\@"; }
|
||||
.preserve-space { white-space: pre; }
|
||||
</style>
|
||||
</head><body>';
|
||||
$output .= '<table border="1">';
|
||||
@ -87,7 +88,7 @@ try {
|
||||
$output .= '<td></td>'; // Telf Contacto vacío
|
||||
$output .= '<td></td>'; // NRO GRR vacío
|
||||
$output .= '<td>AV MEXICO CO</td>'; // ORIGEN fijo
|
||||
$output .= '<td>' . $destino . '</td>'; // Destino
|
||||
$output .= '<td class="preserve-space">' . $destino . '</td>'; // Destino
|
||||
$output .= '</tr>';
|
||||
}
|
||||
|
||||
|
||||
@ -169,7 +169,7 @@ include 'layout_header.php';
|
||||
<th>Estado</th>
|
||||
<?php if ($user_role !== 'Asesor'): ?><th>Asesor</th><?php endif; ?>
|
||||
<th>Fecha Creación</th>
|
||||
<th>Voucher Restante</th>
|
||||
<th style="background-color: #bee5eb; color: #084298;">Mes</th>
|
||||
<th>Acciones</th>
|
||||
</tr>
|
||||
</thead>
|
||||
@ -205,12 +205,12 @@ include 'layout_header.php';
|
||||
<td><span class="badge" style="<?php echo getStatusStyle($pedido['estado']); ?>"><?php echo ($pedido['estado'] == 'Gestion') ? 'GESTIONES ⚙️' : htmlspecialchars($pedido['estado']); ?></span></td>
|
||||
<?php if ($user_role !== 'Asesor'): ?><td><?php echo htmlspecialchars($pedido['asesor_nombre'] ?? 'N/A'); ?></td><?php endif; ?>
|
||||
<td><?php echo htmlspecialchars($pedido['created_at']); ?></td>
|
||||
<td>
|
||||
<?php if (!empty($pedido['voucher_restante_path'])): ?>
|
||||
<a href="<?php echo htmlspecialchars($pedido['voucher_restante_path']); ?>" target="_blank">Ver</a>
|
||||
<?php else: ?>
|
||||
N/A
|
||||
<?php endif; ?>
|
||||
<td style="background-color: #e7f3ff; font-weight: bold; color: #084298; text-align: center;">
|
||||
<?php
|
||||
$date = new DateTime($pedido['created_at']);
|
||||
$monthNum = (int)$date->format('m');
|
||||
echo htmlspecialchars($months[$monthNum] ?? 'N/A');
|
||||
?>
|
||||
</td>
|
||||
<td>
|
||||
<a href="pedido_form.php?id=<?php echo $pedido['id']; ?>" class="btn btn-sm btn-warning">Editar</a>
|
||||
@ -240,7 +240,7 @@ $(document).ready(function() {
|
||||
"language": {
|
||||
"url": "//cdn.datatables.net/plug-ins/1.10.25/i18n/Spanish.json"
|
||||
},
|
||||
"order": [[ 0, "desc" ]],
|
||||
"order": [[ <?php echo ($user_role !== 'Asesor') ? 16 : 15; ?>, "desc" ]],
|
||||
"paging": false,
|
||||
"lengthChange": false,
|
||||
"info": false
|
||||
|
||||
@ -50,8 +50,8 @@ if (isset($_GET['id'])) {
|
||||
die('Acceso denegado. No tienes permiso para editar este pedido.');
|
||||
}
|
||||
} else {
|
||||
// Security check: Only Administradors, Logistica and asesores can create new pedidos
|
||||
if ($user_role !== 'Administrador' && $user_role !== 'Logistica' && $user_role !== 'Asesor') {
|
||||
// Security check: Only Administradors, Logistica, Control Logistico and asesores can create new pedidos
|
||||
if ($user_role !== 'Administrador' && $user_role !== 'Logistica' && $user_role !== 'Control Logistico' && $user_role !== 'Asesor') {
|
||||
die('Acceso denegado. No tienes permiso para crear nuevos pedidos.');
|
||||
}
|
||||
}
|
||||
@ -300,7 +300,7 @@ include 'layout_header.php';
|
||||
<?php foreach ($estados as $estado_option): ?>
|
||||
<option value="<?php echo $estado_option; ?>" <?php echo ($pedido['estado'] == $estado_option) ? 'selected' : ''; ?>><?php echo $estado_option; ?></option>
|
||||
<?php endforeach; ?>
|
||||
<?php if (isset($_SESSION['user_role']) && in_array($_SESSION['user_role'], ['superadmin', 'Administrador', 'admin'])): ?>
|
||||
<?php if (isset($_SESSION['user_role']) && in_array($_SESSION['user_role'], ['superadmin', 'Administrador', 'admin', 'Control Logistico'])): ?>
|
||||
<option value="Gestion" <?php echo ($pedido['estado'] == 'Gestion') ? 'selected' : ''; ?>>GESTIONES ⚙️</option>
|
||||
<?php endif; ?>
|
||||
</select>
|
||||
|
||||