oshipka/vm_gen/templates/_relationship_py
2020-06-03 16:00:51 +02:00

4 lines
224 B
Plaintext

[[ column.name ]]_id = db.Column(db.Integer, db.ForeignKey('[[ column.name ]].id'))
[[ column.name ]] = db.relationship('[[ column.name|snake_to_camel ]]', backref=db.backref("[[ name|camel_to_snake|pluralize ]]"))