3
0
Fork 0
mirror of https://github.com/nanoy42/coope synced 2024-11-22 11:23:11 +00:00

Fix la vue editKeg

This commit is contained in:
Yoann Pétri 2019-05-17 16:19:28 +02:00
parent a319ef8adf
commit a9f0d20779
3 changed files with 6 additions and 4 deletions

View file

@ -1,3 +1,5 @@
## v3.5.2
* Fix la vue editKeg
## v3.5.1
* Les catégories apapraissent que si elles sont pas vides
* Nombre de produits affiché sur la liste des catégories

View file

@ -46,9 +46,9 @@ class KegForm(forms.ModelForm):
"""
def __init__(self, *args, **kwargs):
super(KegForm, self).__init__(*args, **kwargs)
self.fields['pinte'].queryset = Product.objects.filter(category=Product.P_PRESSION)
self.fields['demi'].queryset = Product.objects.filter(category=Product.D_PRESSION)
self.fields['galopin'].queryset = Product.objects.filter(category=Product.G_PRESSION)
self.fields['pinte'].queryset = Product.objects.filter(draft_category=Product.DRAFT_PINTE)
self.fields['demi'].queryset = Product.objects.filter(draft_category=Product.DRAFT_DEMI)
self.fields['galopin'].queryset = Product.objects.filter(draft_category=Product.DRAFT_GALOPIN)
class Meta:
model = Keg

View file

@ -42,6 +42,6 @@
<li><a href="https://www.facebook.com/coopesmetz/" class="icon fa-facebook alt"><span class="label">Facebook</span></a></li>
</ul>
</section>
<p class="copyright">coope.rez v3.5.1 (release stable) &copy; 2018-2019 Yoann Pietri.</p>
<p class="copyright">coope.rez v3.5.2 (release stable) &copy; 2018-2019 Yoann Pietri.</p>