mirror of
https://github.com/pretix/pretix.git
synced 2026-05-04 15:04:03 +00:00
Refs #102 -- Added multiple-choice question types
This commit is contained in:
@@ -12,7 +12,7 @@ from typing import List, Union
|
||||
from ..decimal import round_decimal
|
||||
from .base import CachedFile, LoggedModel
|
||||
from .event import Event
|
||||
from .items import Item, ItemVariation, Question, Quota
|
||||
from .items import Item, ItemVariation, Question, QuestionOption, Quota
|
||||
|
||||
|
||||
def generate_secret():
|
||||
@@ -286,6 +286,9 @@ class QuestionAnswer(models.Model):
|
||||
question = models.ForeignKey(
|
||||
Question, related_name='answers'
|
||||
)
|
||||
options = models.ManyToManyField(
|
||||
QuestionOption, related_name='answers', blank=True
|
||||
)
|
||||
answer = models.TextField()
|
||||
|
||||
def __str__(self):
|
||||
|
||||
Reference in New Issue
Block a user