Browse Source

Estilizado el filtro de ver cuenta

Celestino Rey 1 năm trước cách đây
mục cha
commit
ded1c5cb49
2 tập tin đã thay đổi với 30 bổ sung và 10 xóa
  1. 0 2
      src/templates/dashboard.html
  2. 30 8
      src/templates/ver_cuenta.html

+ 0 - 2
src/templates/dashboard.html

@@ -43,11 +43,9 @@
             <form method="get" class="form-inline mb-3">
                 <div class="row g-2 align-items-end">
                     <div class="col-auto">
-                        {{ form_fecha.mes.label_tab }}
                         {{ form_fecha.mes }}
                     </div>
                     <div class="col-auto">
-                        {{ form_fecha.anio.label_tab }}
                         {{ form_fecha.anio }}
                     </div>
                     <div class="col-auto">

+ 30 - 8
src/templates/ver_cuenta.html

@@ -11,14 +11,24 @@
     </h3>
 
     <div class="board">  
-        <form method="get">
-    <div>
-        {{ form.mes.label_tag }} {{ form.mes }}
-        {{ form.anio.label_tag }} {{ form.anio }}
-        {{ form.categoria.label_tag }} {{ form.categoria }}
-        <button type="submit">Filtrar</button>
-    </div>
-</form>
+        <div class="form-group">
+            <form method="get">
+                <div class="row g-2 align-items-end">
+                    <div class="col-auto">
+                        {{ form.mes }}
+                    </div>
+                    <div class="col-auto">
+                        {{ form.anio }}
+                     </div>
+                    <div class="col-auto">
+                        {{ form.categoria }}
+                    </div>
+                    <div class="col-auto">
+                        <button type="submit" class="btn btn-primary">Filtrar</button>
+                    </div>
+                </div>
+            </form>
+        </div>
   
         <table width="100%">
             <thead>
@@ -28,6 +38,7 @@
                     <th>Destino</th>
                     <th>Monto</th>
                     <th>Descripción</th>
+                    <th></th>
                 </tr>
             </thead>
             <tbody>
@@ -38,6 +49,17 @@
                     <td>{{ mov.cuenta_destino.nombre }}</td>
                     <td style="text-align: right;">{{ mov.monto|floatformat:2 }} €</td>
                     <td>{{ mov.descripcion }}</td>
+                    <td class="edit">
+                        <a href="{% url 'editar_movimiento' mov.id %}">
+                            <i class="bi bi-pencil-square"></i>
+                        </a>                        
+                        <a href="{% url 'eliminar_movimiento' mov.id %}">
+                            <i class="bi bi-trash3"></i>
+                        </a>                        
+                        <a href="{% url 'duplicar_movimiento' mov.id %}">
+                            <i class="bi bi-copy"></i>
+                        </a>
+                    </td> 
                 </tr>
                 {% endfor %}
             </tbody>