diff --git a/kfet/forms.py b/kfet/forms.py index 0fc02dd3..67103de6 100644 --- a/kfet/forms.py +++ b/kfet/forms.py @@ -463,7 +463,7 @@ class InventoryArticleForm(forms.Form): queryset = Article.objects.all(), widget = forms.HiddenInput(), ) - stock_new = forms.IntegerField(required = False) + stock_new = forms.IntegerField(required=False) def __init__(self, *args, **kwargs): super(InventoryArticleForm, self).__init__(*args, **kwargs) @@ -472,6 +472,7 @@ class InventoryArticleForm(forms.Form): self.stock_old = kwargs['initial']['stock_old'] self.category = kwargs['initial']['category'] self.category_name = kwargs['initial']['category__name'] + self.box_capacity = kwargs['initial']['box_capacity'] # ----- # Order forms diff --git a/kfet/static/kfet/css/index.css b/kfet/static/kfet/css/index.css index 563d3839..5a82b5cf 100644 --- a/kfet/static/kfet/css/index.css +++ b/kfet/static/kfet/css/index.css @@ -32,6 +32,7 @@ textarea { .table { margin-bottom:0; + border-bottom:1px solid #ddd; } .table { @@ -230,6 +231,9 @@ textarea { height:28px; margin:3px 0px; } + .content-center .auth-form { + margin:15px; +} /* * Pages formulaires seuls @@ -549,3 +553,18 @@ thead .tooltip { .help-block { padding-top: 15px; } + +/* Inventaires */ + +.inventory_modified { + background:rgba(236,100,0,0.15); +} + +.stock_diff { + padding-left: 5px; + color:#C8102E; +} + +.inventory_update { + display:none; +} diff --git a/kfet/static/kfet/css/jconfirm-kfet.css b/kfet/static/kfet/css/jconfirm-kfet.css index 0bd53ab7..1aee70f1 100644 --- a/kfet/static/kfet/css/jconfirm-kfet.css +++ b/kfet/static/kfet/css/jconfirm-kfet.css @@ -28,6 +28,7 @@ .jconfirm .jconfirm-box .content { border-bottom:1px solid #ddd; + padding:5px 10px; } .jconfirm .jconfirm-box input { diff --git a/kfet/templates/kfet/inventory_create.html b/kfet/templates/kfet/inventory_create.html index d4f53c3c..d8109f8e 100644 --- a/kfet/templates/kfet/inventory_create.html +++ b/kfet/templates/kfet/inventory_create.html @@ -1,4 +1,11 @@ {% extends 'kfet/base.html' %} +{% load staticfiles %} +{% load widget_tweaks %} + +{% block extra_head %} + + +{% endblock %} {% block title %}Nouvel inventaire{% endblock %} {% block content-header-title %}Nouvel inventaire{% endblock %} @@ -6,38 +13,194 @@ {% block content %} {% include 'kfet/base_messages.html' %} - -
+ + + + + {% endblock %} diff --git a/kfet/templates/kfet/order_create.html b/kfet/templates/kfet/order_create.html index 1bd6d54f..c2d07f76 100644 --- a/kfet/templates/kfet/order_create.html +++ b/kfet/templates/kfet/order_create.html @@ -66,11 +66,13 @@ {% endfor %} - {% if not perms.kfet.add_order %} - - {% endif %} {{ formset.management_form }} - + {% if not perms.kfet.add_inventory %} +