from otree.api import Currency as c, currency_range from ._builtin import Page, WaitPage from .models import Constants class End_A(Page): def vars_for_template(self): self.player.personal_code() def is_displayed(self): return (self.participant.vars['consent'] and self.participant.vars['drop'] != 1 ) class End_B(Page): def vars_for_template(self): self.player.personal_code() self.player.letters = "DROPPED" def is_displayed(self): return (self.participant.vars['consent'] == False or self.participant.vars['drop'] == 1) page_sequence = [End_A, End_B]