You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
603 B
18 lines
603 B
from django import forms
|
|
from main.models import Feedback, STARS_CHOICES
|
|
from store.alemtat import alemtat_get_services_tuple
|
|
from store.models import OrderData, ProductFeedback
|
|
|
|
|
|
class OrderForm(forms.ModelForm):
|
|
class Meta:
|
|
model = OrderData
|
|
fields = ['first_name', 'last_name', 'phone', 'email', 'city', 'address', 'deliv_type']
|
|
|
|
|
|
class ProductFeedbackForm(forms.ModelForm):
|
|
stars = forms.IntegerField(widget=forms.RadioSelect(choices=STARS_CHOICES), label='Оценка')
|
|
|
|
class Meta:
|
|
model = ProductFeedback
|
|
fields = ['stars', 'name', 'email', 'text', ]
|
|
|