1
0
Fork 0
gnuviechadminweb-historic/gnuviechadminweb/model/__init__.py
Jan Dittberner 949e699e25 * use sha512 passwords
* more robust SQLAlchemy session handling code
 * implemented password change mechanism
2008-06-05 18:25:08 +00:00

17 lines
508 B
Python

import sqlalchemy as sa
from sqlalchemy import orm
from gnuviechadminweb.model import meta
def init_model(engine):
"""Call me before using any of the tables or classes in the model."""
sm = orm.sessionmaker(autoflush=True, transactional=True, bind=engine)
meta.engine = engine
meta.Session = orm.scoped_session(sm)
from gnuviechadminweb.model.user import Group, Role, User
from gnuviechadminweb.model.GVAUsers import GVAUsers, sha512
from gnuviechadminweb.model.menu import Menu