Skip to content

Instantly share code, notes, and snippets.

@rdeaton
Created October 30, 2012 22:53
Show Gist options
  • Save rdeaton/3983627 to your computer and use it in GitHub Desktop.
Save rdeaton/3983627 to your computer and use it in GitHub Desktop.
Reset_Requests_table = db.Table('Reset_Requests', db.Model.metadata,
db.Column('student_id', db.Integer, db.ForeignKey('user.id')),
db.Column('teacher_id', db.Integer, db.ForeignKey('user.id')),
db.Column('approved', db.Boolean)
)
class Reset_Requests(object):
pass
mapper(Reset_Requests, Reset_Requests_table,
polymorphic_on=Reset_Requests_table.c.type,
properties={
'alt':Reset_Requests_table.c.some_alt
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment