from otree.api import Currency as c, currency_range from . import models from ._builtin import Page, WaitPage from .models import Constants class Demographics(Page): form_model = 'player' form_fields = ['age', 'gender', 'political','education','income'] # class GeneralTrust(Page): # form_model = 'player' # form_fields = ['gts_{}'.format(i) for i in range(1,7)] # def vars_for_template(self): # return {'gts_scales': range(1,6)} class AQ(Page): form_model = 'player' form_fields = ['AQ_{}'.format(i) for i in range(1, 11)] def vars_for_template(self): return {'AQ_scales': range(1, 5)} class MMQ(Page): form_model = 'player' form_fields = ['MMQ_{}'.format(i) for i in range(1, 17)] def vars_for_template(self): return {'MMQ_scales': range(1,5)} class PPQ(Page): form_model = 'player' form_fields = ['PPQ_{}'.format(i) for i in range(1,27)] def vars_for_template(self): return {'PPQ_scales': range(1,6)} class Debrief(Page): form_model = 'player' form_fields = ['debrief_{}'.format(i) for i in range(1,5)] page_sequence = [ Demographics, # GeneralTrust, AQ, MMQ, PPQ, Debrief ]