forked from openlp/openlp
DB Fixed
This commit is contained in:
parent
2dd0aa234e
commit
1e4b922bfa
@ -73,6 +73,13 @@ def upgrade_db(url, upgrade):
|
||||
The python module that contains the upgrade instructions.
|
||||
"""
|
||||
session, metadata = init_db(url)
|
||||
|
||||
class Metadata(BaseModel):
|
||||
"""
|
||||
Provides a class for the metadata table.
|
||||
"""
|
||||
pass
|
||||
|
||||
tables = upgrade.upgrade_setup(metadata)
|
||||
metadata_table = Table(u'metadata', metadata,
|
||||
Column(u'key', types.Unicode(64), primary_key=True),
|
||||
@ -103,6 +110,7 @@ def upgrade_db(url, upgrade):
|
||||
session.commit()
|
||||
return int(version_meta.value), upgrade.__version__
|
||||
|
||||
|
||||
def delete_database(plugin_name, db_file_name=None):
|
||||
"""
|
||||
Remove a database file from the system.
|
||||
@ -138,14 +146,6 @@ class BaseModel(object):
|
||||
instance.__setattr__(key, value)
|
||||
return instance
|
||||
|
||||
|
||||
class Metadata(BaseModel):
|
||||
"""
|
||||
Provides a class for the metadata table.
|
||||
"""
|
||||
pass
|
||||
|
||||
|
||||
class Manager(object):
|
||||
"""
|
||||
Provide generic object persistence management
|
||||
|
Loading…
Reference in New Issue
Block a user