You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
my-emacs-d/snippets/python-mode/translatable_model

14 lines
306 B

# -*- mode: snippet -*-
# name: Translatable Flask-SQLAlchemy model
# key: tmodel
# --
class ${1:name}(Translatable, db.Model):
__tablename__ = '${2:tablename}s'
id = db.Column(db.Integer, primary_key=True)
class $1Translation(translation_base($1)):
__tablename__ = '$2_translations'
$0