def METHOD_NAME(app):
    """
    Register blueprints
    :param app: a flask app instance
    :return:
    """
    app.register_blueprint(home_routes)
    admin = Admin(
        app,
        name='Open Event API',
        template_mode='bootstrap3',
        index_view=MyAdminIndexView(),
        base_template='admin_base.html',
    )
    # Get all the models in the db, all models should have a explicit __tablename__
    classes, models, table_names = [], [], []
    # noinspection PyProtectedMember
    for class_ in list(db.Model._decl_class_registry.values()):
        try:
            table_names.append(class_.__tablename__)
            classes.append(class_)
        except:
            pass
    for table in list(db.metadata.tables.items()):
        if table[0] in table_names:
            models.append(classes[table_names.index(table[0])])
    for model in models:
        admin.add_view(AdminModelView(model, db.session))