from django.conf import settings from otree.api import ( models, widgets, BaseConstants, BaseSubsession, BaseGroup, BasePlayer ) doc = '' class Constants(BaseConstants): name_in_url = 'QUIZ' players_per_group = 3 num_rounds = 1 class Subsession(BaseSubsession): pass class Group(BaseGroup): pass class Player(BasePlayer): Errors = models.IntegerField(initial=0) # errori nelle domande di controllo. q1 = models.IntegerField( choices=[[1, 'A’s Pros and B’s Cons'], [2, 'B’s Pros and A’s Cons'], [3, 'B’s Pros and B’s Cons']], label='Candidate B knows two qualities and can choose only one to reveal to the Voter. Those two qualities are:', widget=widgets.RadioSelect) q2 = models.IntegerField( choices=[[1, 'Nothing'], [2, 'One Candidate’s message, randomly selected, and who sent it (A or B)'], [3, 'Both Candidates’ messages']], label='In a round without Media, what is the Voter told after the Candidates choose a message?', widget=widgets.RadioSelect) q3 = models.IntegerField(choices=[[1, 'The worse Candidate is elected.'], [2, 'The better Candidate is elected.'], [3, 'The elected Candidate is selected randomly.']], label='Who is elected if the Voter chooses to “pass”?', widget=widgets.RadioSelect) q4 = models.IntegerField(initial=0, label='What is A’s Total Quality? ') q5 = models.IntegerField(initial=0, label="What is B's Total Quality?") q6 = models.IntegerField(choices=[[1, 'When Candidate A is elected'], [2, 'When Candidate B is elected']], label='In this situation, when is the Voter successful?', widget=widgets.RadioSelect) q7 = models.IntegerField(choices=[[1, 'Voter earns $2 this round.'], [2, 'Candidate B is selected'], [3, 'Candidate A is selected']], label='Suppose the Voter votes for Candidate B and this round is selected for payment.', widget=widgets.RadioSelect)