diff --git a/Inventario/__pycache__/forms.cpython-313.pyc b/Inventario/__pycache__/forms.cpython-313.pyc index 6fd3fff..9e6a6bb 100644 Binary files a/Inventario/__pycache__/forms.cpython-313.pyc and b/Inventario/__pycache__/forms.cpython-313.pyc differ diff --git a/Inventario/__pycache__/views.cpython-313.pyc b/Inventario/__pycache__/views.cpython-313.pyc index 46650bf..3e21d35 100644 Binary files a/Inventario/__pycache__/views.cpython-313.pyc and b/Inventario/__pycache__/views.cpython-313.pyc differ diff --git a/Inventario/forms.py b/Inventario/forms.py index 1c0b469..92c19bd 100644 --- a/Inventario/forms.py +++ b/Inventario/forms.py @@ -119,14 +119,11 @@ class VentaForm(forms.ModelForm): empty_label="Selecciona una bodega", widget=forms.Select(attrs={'class': 'btn btn-secondary dropdown-toggle ', 'data-bs-toggle': 'dropdown', 'aria-expanded': 'false'}), label="bodega") - cantidad=forms.DecimalField( - label="cantidad", - max_digits=10, - decimal_places=2, - widget=forms.NumberInput(attrs={'class': 'form-control', 'placeholder': 'Escribe un decimal'})) + class Meta: model = Venta fields = ['bodega', 'articulo', 'cantidad', 'observaciones'] widgets={ + 'cantidad': forms.NumberInput(attrs={'class': 'form-control', 'placeholder': 'Escribe un decimal'}), 'observaciones': forms.Textarea(attrs={'class':'form-control','placeholder':'describa el producto','rows':'5'}), } diff --git a/Inventario/templates/index.html b/Inventario/templates/index.html index 884fb63..f8118c9 100644 --- a/Inventario/templates/index.html +++ b/Inventario/templates/index.html @@ -2,7 +2,169 @@ {% block content %} {% if user.is_authenticated %} +
+ ${{ total_ventas|floatformat:2 }} +
++ {{ total_productos_en_inventario }} +
++ {{ total_articulos_vendidos }} +
++ {{ total_proveedores }} +
+