# Definition of views/pages for the survey. # Please note: When using oTree 2.x, this file should be called "pages.py" instead of "views.py" # from otree.api import Currency as c, currency_range from . import models from ._builtin import Page, WaitPage from .models import Constants from otreeutils.surveys import SurveyPage, setup_survey_pages import random class Feedback(Page): form_model = 'player' form_fields = ['feedback'] class SurveyPage2(SurveyPage): pass class SurveyPage4(SurveyPage): pass class StateBoredomAfter(SurveyPage): pass # Create a list of survey pages. # The order is important! The survey questions are taken in the same order # from the SURVEY_DEFINITIONS in models.py survey_pages = [ SurveyPage2, SurveyPage4, StateBoredomAfter, ] # Common setup for all pages (will set the questions per page) setup_survey_pages(models.Player, survey_pages) page_sequence = [ StateBoredomAfter, # State Boredom Scale (After) SurveyPage4, # IBT Scale SurveyPage2, # Boredom Proneness Scale Feedback, ]