Tul xxx Tul
User / IP
:
216.73.216.217
Host / Server
:
45.84.207.204 / aircan.me
System
:
Linux lt-bnk-web1726.main-hosting.eu 5.14.0-611.36.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Mar 3 11:23:52 EST 2026 x86_64
Command
|
Upload
|
Create
Mass Deface
|
Jumping
|
Symlink
|
Reverse Shell
Ping
|
Port Scan
|
DNS Lookup
|
Whois
|
Header
|
cURL
:
/
home
/
u931257429
/
domains
/
aircan.me
/
public_html
/
app
/
views
/
ventas
/
Viewing: create.php
<?php $error = $error ?? null; $clientes = $clientes ?? []; $servicios = $servicios ?? []; $sistemas = $sistemas ?? []; $tiposPago = $tiposPago ?? []; ?> <?php if ($error): ?> <div class="alert alert-danger alert-dismissible fade show d-flex align-items-center" role="alert" style="border: none; border-radius: 10px; border-left: 4px solid #ef476f;"> <i class="bi bi-exclamation-circle-fill me-2"></i> <?= htmlspecialchars($error) ?> <button type="button" class="btn-close" data-bs-dismiss="alert"></button> </div> <?php endif; ?> <!-- Botón regresar --> <div class="mb-3"> <a href="<?= BASE_URL ?>/ventas" class="btn btn-sm btn-outline-secondary" style="border-radius: 6px;"> <i class="bi bi-arrow-left me-1"></i>Volver a Ventas </a> </div> <div class="row"> <div class="col-12"> <div class="card-custom animate-fade-in" style="margin-bottom: 60px;"> <div class="card-header-custom"> <h5><i class="bi bi-cart-plus me-2"></i>Registrar Nueva Venta</h5> </div> <div class="card-body-custom" style="padding: 30px;"> <form method="POST" action="<?= BASE_URL ?>/ventas/store" id="ventaForm"> <!-- Cliente --> <div class="mb-4"> <label class="form-label" style="font-weight: 600; font-size: 0.9rem;"> <i class="bi bi-person me-1"></i>Cliente </label> <select name="cliente_id" class="form-select" style="border-radius: 8px; font-size: 0.9rem;"> <option value="">— Seleccionar cliente —</option> <?php foreach ($clientes as $cli): ?> <option value="<?= $cli['id'] ?>"> <?= htmlspecialchars($cli['nombre'] . ' ' . $cli['apellido']) ?> <?= !empty($cli['email']) ? '(' . htmlspecialchars($cli['email']) . ')' : '' ?> </option> <?php endforeach; ?> </select> </div> <!-- Servicio --> <div class="mb-4"> <label class="form-label" style="font-weight: 600; font-size: 0.9rem;"> <i class="bi bi-gear me-1"></i>Servicio <span class="text-muted fw-normal">(opcional)</span> </label> <select name="servicio_id" class="form-select" style="border-radius: 8px; font-size: 0.9rem;"> <option value="">— Seleccionar servicio —</option> <?php foreach ($servicios as $srv): ?> <option value="<?= $srv['id'] ?>"> <?= htmlspecialchars($srv['nombre']) ?> — $<?= number_format(floatval($srv['precio']), 2) ?> </option> <?php endforeach; ?> </select> </div> <!-- Sistema --> <div class="mb-4"> <label class="form-label" style="font-weight: 600; font-size: 0.9rem;"> <i class="bi bi-laptop me-1"></i>Sistema <span class="text-muted fw-normal">(opcional)</span> </label> <select name="sistema_id" class="form-select" style="border-radius: 8px; font-size: 0.9rem;"> <option value="">— Seleccionar sistema —</option> <?php foreach ($sistemas as $sis): ?> <option value="<?= $sis['id'] ?>"> <?= htmlspecialchars($sis['nombre']) ?> — $<?= number_format(floatval($sis['precio']), 2) ?> </option> <?php endforeach; ?> </select> </div> <!-- Descripción --> <div class="mb-4"> <label class="form-label" style="font-weight: 600; font-size: 0.9rem;"> <i class="bi bi-card-text me-1"></i>Descripción </label> <textarea name="descripcion" class="form-control" rows="3" placeholder="Detalle de la venta..." style="border-radius: 8px; font-size: 0.9rem; resize: vertical;"></textarea> </div> <!-- Monto y método de pago --> <div class="row g-3 mb-4"> <div class="col-md-6"> <label class="form-label" style="font-weight: 600; font-size: 0.9rem;"> <i class="bi bi-currency-dollar me-1"></i>Monto <span class="text-danger">*</span> </label> <div class="input-group"> <span class="input-group-text" style="border-radius: 8px 0 0 8px; background: var(--bg-body); border-color: var(--border-color);">$</span> <input type="number" name="monto" class="form-control" step="0.01" min="0.01" placeholder="0.00" required style="border-radius: 0 8px 8px 0; font-size: 0.9rem;"> </div> </div> <div class="col-md-6"> <label class="form-label" style="font-weight: 600; font-size: 0.9rem;"> <i class="bi bi-wallet2 me-1"></i>Método de Pago <span class="text-danger">*</span> </label> <select name="metodo_pago" class="form-select" required style="border-radius: 8px; font-size: 0.9rem;"> <option value="">— Seleccionar método —</option> <?php foreach ($tiposPago as $tp): ?> <option value="<?= htmlspecialchars($tp['slug']) ?>"> <?= htmlspecialchars($tp['nombre']) ?> </option> <?php endforeach; ?> </select> </div> </div> <!-- Botones --> <div class="d-flex justify-content-end gap-2 pt-2" style="border-top: 1px solid var(--border-color); padding-top: 20px;"> <a href="<?= BASE_URL ?>/ventas" class="btn btn-sm btn-secondary" style="border-radius: 6px; padding: 8px 20px;"> Cancelar </a> <button type="submit" class="btn btn-sm btn-primary-custom" style="padding: 8px 24px;"> <i class="bi bi-check-lg me-1"></i>Registrar Venta </button> </div> </form> </div> </div> </div> </div> <script> document.addEventListener('DOMContentLoaded', function() { const clienteSelect = document.getElementById('clienteSelect'); const leadSelect = document.getElementById('leadSelect'); const btns = document.querySelectorAll('.buyer-type-btn'); // Si hay lead preseleccionado, activar pestaña lead <?php if ($preselectedLead): ?> switchBuyerType('lead'); <?php endif; ?> btns.forEach(function(btn) { btn.addEventListener('click', function() { switchBuyerType(this.dataset.type); }); }); function switchBuyerType(type) { btns.forEach(b => { b.classList.remove('active'); b.style.background = ''; b.style.color = ''; b.style.border = '1px solid var(--border-color)'; }); const activeBtn = document.querySelector('.buyer-type-btn[data-type="' + type + '"]'); activeBtn.classList.add('active'); activeBtn.style.background = 'var(--primary)'; activeBtn.style.color = '#fff'; activeBtn.style.border = '1px solid var(--primary)'; if (type === 'cliente') { clienteSelect.style.display = ''; leadSelect.style.display = 'none'; leadSelect.querySelector('select').value = ''; } else { clienteSelect.style.display = 'none'; leadSelect.style.display = ''; clienteSelect.querySelector('select').value = ''; } } // Inicializar estilos btns.forEach(b => { if (!b.classList.contains('active')) { b.style.border = '1px solid var(--border-color)'; b.style.background = ''; b.style.color = ''; } else { b.style.background = 'var(--primary)'; b.style.color = '#fff'; b.style.border = '1px solid var(--primary)'; } }); }); </script>
Coded With 💗 by
0x6ick