# coding=utf-8 from otree.api import ( models, widgets, BaseConstants, BaseSubsession, BaseGroup, BasePlayer, Currency as c, currency_range ) import random from django import forms from django.forms.widgets import CheckboxSelectMultiple author = '' doc = """ Leader and followers one-shot public goods game with disclosure of SVO types (two treatments). """ class Constants(BaseConstants): name_in_url = 'cc_type' players_per_group = None num_rounds = 1 endowment_low = c(20) endowment_high = c(40) multiplier = 1.6 class Subsession(BaseSubsession): pass class Group(BaseGroup): pass class Player(BasePlayer): con_investment_0 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_1 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_2 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_3 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_4 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_5 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_6 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_7 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_8 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_9 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_10 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_11 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_12 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_13 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_14 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_15 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_16 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_17 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_18 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_19 = models.CurrencyField(min=0, max=Constants.endowment_low) con_investment_20 = models.CurrencyField(min=0, max=Constants.endowment_low)