コード例 #1
0
ファイル: __init__.py プロジェクト: Fivebread/streetsign
def end_of_request(exception): # pylint: disable=unused-argument
    ''' close the database '''
    DB.close()
コード例 #2
0
ファイル: __init__.py プロジェクト: rcompaore/streetsign
def end_of_request(exception):  # pylint: disable=unused-argument
    ''' close the database '''
    DB.close()
コード例 #3
0
ファイル: __init__.py プロジェクト: Fivebread/streetsign
def before_the_action():
    ''' load some variables in for template etc to use, and connect the DB '''

    g.site_vars = app.config.get('SITE_VARS')
    DB.init(app.config.get('DATABASE_FILE'))
    DB.connect()
コード例 #4
0
ファイル: __init__.py プロジェクト: rcompaore/streetsign
def before_the_action():
    ''' load some variables in for template etc to use, and connect the DB '''

    g.site_vars = app.config.get('SITE_VARS')
    DB.init(app.config.get('DATABASE_FILE'))
    DB.connect()