e2d027f71b
Fixes #78
31 lines
714 B
Python
31 lines
714 B
Python
from registrasion.models import conditions
|
|
from registrasion.models import inventory
|
|
|
|
from django import forms
|
|
|
|
# Reporting forms.
|
|
|
|
|
|
class DiscountForm(forms.Form):
|
|
discount = forms.ModelMultipleChoiceField(
|
|
queryset=conditions.DiscountBase.objects.all(),
|
|
required=False,
|
|
)
|
|
|
|
|
|
class ProductAndCategoryForm(forms.Form):
|
|
product = forms.ModelMultipleChoiceField(
|
|
queryset=inventory.Product.objects.all(),
|
|
required=False,
|
|
)
|
|
category = forms.ModelMultipleChoiceField(
|
|
queryset=inventory.Category.objects.all(),
|
|
required=False,
|
|
)
|
|
|
|
|
|
class UserIdForm(forms.Form):
|
|
user = forms.IntegerField(
|
|
label="User ID",
|
|
required=False,
|
|
)
|