Exemple #1
0
def register_extensions(app):
    db.init_app(app)
    login_manager.init_app(app)
    assets.init_app(app)
    toolbar = DebugToolbarExtension(app)
    cache.init_app(app)
    migrate.init_app(app, db)
    return None
Exemple #2
0
def register_extensions(app):
    """Register Flask extensions."""
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    flask_static_digest.init_app(app)
    return None
Exemple #3
0
def registerExtensions(app):
    """Register Flask extensions."""
    bcrypt.init_app(app)
    cache.init_app(app)
    cors.init_app(app, supports_credentials=True)
    db.init_app(app)
    migrate.init_app(app)
    debug_toolbar.init_app(app)
    return None
Exemple #4
0
def register_extensions(app):
    assets.init_app(app)
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    return None
def register_extensions(app):
    """Register Flask extensions."""
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    csrf_protect.init_app(app)
    login_manager.init_app(app)
    migrate.init_app(app, db)
    return None
Exemple #6
0
def register_extensions(app):
    db.init_app(app)
    dbm.init_app(app)
    login_manager.init_app(app)
    assets.init_app(app)
    if app.config['DEBUG_TB_ENABLED']:
        DebugToolbarExtension(app)
    cache.init_app(app)
    migrate.init_app(app, db)
    return None
def configure_extensions(app):
    """Register Flask extensions."""
    assets.init_app(app)
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    csrf_protect.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    return None
def register_extensions(app):
    db.init_app(app)
    login_manager.init_app(app)
    assets.init_app(app)
    assets.app = app
    assets.url = app.static_url_path
    toolbar = DebugToolbarExtension(app)
    cache.init_app(app)
    migrate.init_app(app, db)
    return None
Exemple #9
0
def register_extensions(app):
    """Register Flask extensions."""
    assets.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    csrf_protect.init_app(app)
    debug_toolbar.init_app(app)
    user_datastore = SQLAlchemyUserDatastore(db, User, Role)
    security.init_app(app, user_datastore)
    migrate.init_app(app, db)
    return None
Exemple #10
0
def register_extensions(app):
    """Register Flask extensions."""
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    csrf_protect.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    webpack.init_app(app)
    return None
Exemple #11
0
def register_extensions(app):
    """Register Flask extensions."""
    assets.init_app(app)
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    csrf_protect.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    admin.init_app(app)
    return None
def register_extensions(app):
    """Register Flask extensions."""
    assets.init_app(app)
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    with app.app_context():
        db.create_all()
    csrf_protect.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    return None
Exemple #13
0
def register_extensions(app):
    """Register Flask extensions."""
    bcrypt.init_app(app)
    cache.init_app(app)
    db.init_app(app)
    csrf_protect.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    moment.init_app(app)
    mail.init_app(app)
    webpack.init_app(app)
    return None
Exemple #14
0
def register_extensions(app, app_base=None):
    ''' Register the Flask extensions used '''

    jsglue.JSGLUE_JS_PATH = '/{0}/jsglue.js'.format(app_base)
    jsglue.init_app(app)
    flags.init_app(app)
    bcrypt.init_app(app)
    cache.init_app(app)
    if app.config['USE_SENTRY']:
        sentry.init_app(app)

    # Initialize the Flask-Profiler ; see results at localhost:portnumber/app_base/profiler/
    if app.config['USE_PROFILER']:
        try:
            profiler.init_app(app)
        except Exception as e:
            pass
def register_extensions(app):
    """ Register Flask extensions. """

    bcrypt.init_app(app)
    cache.init_app(app)
    csrf_protect.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    migrate.init_app(app, db)
    # webpack.init_app(app)
    jwt.init_app(app)
    # If db is SQLAlchemy instance,
    # Flask-SQLAlchemy must be initialized before Flask-Marshmallow
    db.init_app(app)
    ma.init_app(app)
    mail.init_app(app)
    rest_api.init_app(app)
    celery.init_app(app)
Exemple #16
0
def register_extensions(app):
    bcrypt.init_app(app)
    cache.init_app(app)
    login_manager.init_app(app)
    debug_toolbar.init_app(app)
    return None