import modules.badges.util from modules.wikifolios.report import PartReport, ExpertBadgeReport import wtforms as wtf # The name of the template dict key that stores a course's base location. COURSE_BASE_KEY = 'gcb_course_base' # The name of the template dict key that stores data from course.yaml. COURSE_INFO_KEY = 'course_info' XSRF_SECRET_LENGTH = 20 XSRF_SECRET = ConfigProperty( 'gcb_xsrf_secret', str, ( 'Text used to encrypt tokens, which help prevent Cross-site request ' 'forgery (CSRF, XSRF). You can set the value to any alphanumeric text, ' 'preferably using 16-64 characters. Once you change this value, the ' 'server rejects all subsequent requests issued using an old value for ' 'this variable.'), 'course builder XSRF secret') # Whether to record page load/unload events in a database. CAN_PERSIST_PAGE_EVENTS = ConfigProperty( 'gcb_can_persist_page_events', bool, ( 'Whether or not to record student page interactions in a ' 'datastore. Without event recording, you cannot analyze student ' 'page interactions. On the other hand, no event recording reduces ' 'the number of datastore operations and minimizes the use of Google ' 'App Engine quota. Turn event recording on if you want to analyze ' 'this data.'), False)
"""Course explorer module.""" __author__ = 'Rahul Singal ([email protected])' from common import users from controllers import utils from models import custom_modules from models.config import ConfigProperty from models.models import StudentProfileDAO from modules.course_explorer import messages from modules.course_explorer import student GCB_ENABLE_COURSE_EXPLORER_PAGE = ConfigProperty( 'gcb_enable_course_explorer_page', bool, messages.SITE_SETTINGS_COURSE_EXPLORER, default_value=False, label='Course Explorer', multiline=False, validator=None) custom_module = None class ExplorerPageInitializer(utils.PageInitializer): """Page initializer for explorer page. Allow links to the course explorer to be added to the navbars of all course pages. """ @classmethod def initialize(cls, template_values):
""" MailChimp client functions, for subscribing and unsubscribing. """ from models.config import ConfigProperty import mailsnake import mailsnake.exceptions import logging import datetime import os # This module uses Michael Helmick's version of mailsnake # https://github.com/michaelhelmick/python-mailsnake MAILCHIMP_API_KEY = ConfigProperty( 'mailchimp_api_key', str, """The API Key for MailChimp, used for adding students to lists, etc.""", '') MAILCHIMP_PRE_REG_LIST_ID = ConfigProperty( 'mailchimp_pre_reg_list_id', str, """The List ID of the MailChimp list that contains everyone who has pre-registered. Set to None to disable this subscription.""", '') MAILCHIMP_CONFIRMED_LIST_ID = ConfigProperty( 'mailchimp_confirmed_list_id', str, """The List ID of the MailChimp list that contains everyone who has confirmed their registration. Set to None to disable this subscription.""", '') MAILCHIMP_FOR_CREDIT_LIST_ID = ConfigProperty( 'mailchimp_for_credit_list_id', str, """The List ID of the MailChimp list that