Exemplo n.º 1
0
import cherrypy
import uber
from sideboard.lib import parse_config
from uber.config import c, Config, dynamic
from uber.errors import HTTPRedirect
from uber.jinja import template_overrides
from uber.models import Attendee, Session
from uber.utils import mount_site_sections, static_overrides

from magprime._version import __version__  # noqa: F401


magprime_config = parse_config(__file__)
static_overrides(join(magprime_config['module_root'], 'static'))
template_overrides(join(magprime_config['module_root'], 'templates'))


@Config.mixin
class ExtraConfig:
    @property
    @dynamic
    def SEASON_BADGE_PRICE(self):
        return self.BADGE_PRICE + self.SEASON_LEVEL

    @property
    def SEASON_EVENTS(self):
        return magprime_config['season_events']

    @property
    def PREREG_BADGE_TYPES(self):
Exemplo n.º 2
0
from os.path import join

from uber.jinja import template_overrides
from uber.utils import mount_site_sections, static_overrides
from .config import config
from . import models  # noqa: F401
from . import model_checks  # noqa: F401
from . import automated_emails  # noqa: F401

static_overrides(join(config['module_root'], 'static'))
template_overrides(join(config['module_root'], 'templates'))
mount_site_sections(config['module_root'])
Exemplo n.º 3
0
from sqlalchemy.types import Boolean, Date
from uber.config import c, Config
from uber.decorators import cost_property, prereg_validation, presave_adjustment, validation
from uber.menu import MenuItem
from uber.models import Choice, DefaultColumn as Column, Session
from uber.jinja import template_overrides
from uber.utils import add_opt, mount_site_sections, static_overrides

from magstock._version import __version__  # noqa: F401


config = parse_config(__file__)
c.include_plugin_config(config)
mount_site_sections(config['module_root'])
static_overrides(join(config['module_root'], 'static'))
template_overrides(join(config['module_root'], 'templates'))

c.MENU.append_menu_item(
    MenuItem(name='MAGStock', submenu=[
        MenuItem(name='Tent Groupings', href='../magstock/grouped'),
        MenuItem(name='Food Report', href='../magstock/food_consumers'),
        MenuItem(name='Campsite Assignments', href='../magstock/campsite_assignments'),
        MenuItem(name='Parking Info', href='../magstock/parking'),
    ])
)


@Config.mixin
class ExtraConfig:
    @property
    def FOOD_COUNT(self):