Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions essenza/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -513,21 +513,20 @@
<a href="{% url 'info-home' %}" class="info-button" title="Información">i</a>
<a href="{% url 'dashboard' %}" class="brand">ESSENZA</a>
<nav class="nav-links" aria-label="Navegación principal">
{% if not user.is_staff and not user.is_superuser %}
{% if user.is_authenticated and user.role == 'admin'%}
<a href="{% url 'stock' %}">Stock</a>
<a href="{% url 'product_list' %}">Productos</a>
<a href="{% url 'order_list_admin' %}">Pedidos</a>
<a href="{% url 'user_list' %}">Usuarios</a>
{% else %}
<a href="{% url 'dashboard' %}">Escaparate</a>
<a href="{% url 'catalog' %}">Catalogo</a>
{% if user.is_authenticated %}
<a href="{% url 'order_history' %}">Mis Pedidos</a>
<a href="{% url 'order_history' %}">Mis Pedidos</a>
{% else %}
<a href="{% url 'order_search' %}">Localiza tu envío</a>
{% endif %}
{% endif %} {% if user.is_staff or user.is_superuser %}
<a href="{% url 'stock' %}">Stock</a>
<a href="{% url 'product_list' %}">Productos</a>
<a href="{% url 'order_list_admin' %}">Pedidos</a>
<!-- LA SIGUIENTE LINEA ES PROVISIONAL -->
<a href="#">Usuarios</a>
<a href="{% url 'order_search' %}">Localiza tu envío</a>
{% endif %}
{% endif %}
</nav>
</div>

Expand Down
6 changes: 3 additions & 3 deletions essenza/templates/order/order_list_admin.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{% load humanize %}
{% load static %}

{% block title %}Mis pedidos · Essenza{% endblock %}
{% block title %}Pedidos · Essenza{% endblock %}

{% block extra_head %}
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
Expand Down Expand Up @@ -284,8 +284,8 @@
<div class="page-container">

<div class="page-header">
<h1>Mis pedidos</h1>
<p>Historial y seguimiento de tus compras</p>
<h1>Pedidos</h1>
<p>Historial de todas las compras</p>
</div>

<!-- BARRA DE FILTROS (BOTONES SEPARADOS) -->
Expand Down
2 changes: 1 addition & 1 deletion essenza/templates/product/stock.html
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ <h1>Stock Essenza</h1>
{% endif %} {% endwith %}
</div>

{% if user.is_staff or user.is_superuser %}
{% if user.is_authenticated and user.role == 'admin' %}
<form
action="{% url 'stock' %}"
method="post"
Expand Down
151 changes: 151 additions & 0 deletions essenza/templates/user/confirm_delete_user_admin.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
{% load static %}
<!DOCTYPE html>
<html lang="es">
<head>
<meta charset="utf-8" />
<title>Eliminar Usuario · Essenza Admin</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style>
/* === ESTILOS GLOBALES (Porque ya no hay base.html) === */
body {
margin: 0;
font-family: "Segoe UI", Arial, sans-serif;
background-color: #faf7f2; /* Color de fondo base */
}

/* === ESTILO DE ALERTA ROJA === */
.danger-wrapper {
--color-principal: #c06b3e;
--color-fondo: #faf7f2;
--color-fondo-tarjeta: #fff;
--color-error: #b00020;
--color-error-hover: #8e0019;
--color-texto-base: #333;

background-color: var(--color-fondo);
min-height: 100dvh; /* Ocupa toda la pantalla */
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
padding: 20px;
box-sizing: border-box;
}

.brand-danger {
color: var(--color-error); /* Marca en rojo */
font-size: 48px;
margin: 0 0 20px 0;
text-align: center;
font-weight: bold;
}

.form-card {
width: min(450px, 90vw);
background: var(--color-fondo-tarjeta);
border: 3px solid var(--color-error); /* Borde Rojo Grueso */
border-radius: 16px;
box-shadow: 0 12px 28px rgba(176, 0, 32, 0.1);
padding: 30px;
box-sizing: border-box;
text-align: center;
}

h2 {
color: var(--color-error);
margin-top: 0;
font-size: 1.5rem;
font-weight: 800;
}

.warning-text {
color: var(--color-texto-base);
font-size: 16px;
line-height: 1.5;
margin: 20px 0;
}

.user-preview {
background: #fff5f5;
border: 1px dashed var(--color-error);
padding: 15px;
border-radius: 8px;
margin: 20px 0;
color: #555;
font-weight: 600;
}
.user-preview span {
display: block;
color: #000;
font-size: 1.1rem;
margin-top: 5px;
}

/* Botón de peligro */
.btn-danger {
width: 100%;
padding: 14px;
border-radius: 10px;
background: var(--color-error);
color: white;
border: none;
cursor: pointer;
transition: background-color 0.3s;
font-weight: 700;
font-size: 1rem;
text-transform: uppercase;
letter-spacing: 0.5px;
}
.btn-danger:hover {
background-color: var(--color-error-hover);
}

.cancel-link {
margin-top: 20px;
display: block;
font-size: 14px;
}
.cancel-link a {
color: #666;
text-decoration: none;
font-weight: 600;
}
.cancel-link a:hover {
text-decoration: underline;
}
</style>
</head>
<body>
<div class="danger-wrapper">

<h1 class="brand-danger">ATENCIÓN</h1>

<div class="form-card">
<h2>Eliminar Usuario</h2>

<p class="warning-text">
Estás a punto de eliminar permanentemente la siguiente cuenta.
<br>
<strong>Esta acción borrará todos sus pedidos y datos asociados.</strong>
</p>

<div class="user-preview">
Usuario:
<span>{{ object.email }}</span>
<small style="font-weight: normal; font-size: 0.8rem;">({{ object.first_name }} {{ object.last_name }})</small>
</div>

<form method="post">
{% csrf_token %}
<button type="submit" class="btn-danger">
CONFIRMAR ELIMINACIÓN
</button>
</form>

<p class="cancel-link">
<a href="{% url 'user_list' %}">Cancelar y volver (No hacer nada)</a>
</p>
</div>
</div>
</body>
</html>
Loading