Esempio n. 1
0
def setup_upref_mdata(app):
    """Setup user preference and metadata choices for user accounts"""
    global upref_mdata_choices
    upref_mdata_choices = dict(languages=[], locations=[],
                                timezones=[], user_types=[])
    if app.config.upref_mdata:
        from settings_upref_mdata import (upref_languages, upref_locations,
                mdata_timezones, mdata_user_types)
        upref_mdata_choices['languages'] = upref_languages()
        upref_mdata_choices['locations'] = upref_locations()
        upref_mdata_choices['timezones'] = mdata_timezones()
        upref_mdata_choices['user_types'] = mdata_user_types()
Esempio n. 2
0
def setup_upref_mdata(app):
    """Setup user preference and metadata choices for user accounts"""
    global upref_mdata_choices
    upref_mdata_choices = dict(languages=[], locations=[],
                                timezones=[], user_types=[])
    if app.config.upref_mdata:
        from settings_upref_mdata import (upref_languages, upref_locations,
                mdata_timezones, mdata_user_types)
        upref_mdata_choices['languages'] = upref_languages()
        upref_mdata_choices['locations'] = upref_locations()
        upref_mdata_choices['timezones'] = mdata_timezones()
        upref_mdata_choices['user_types'] = mdata_user_types()