Created
November 14, 2012 18:50
-
-
Save klen/4073967 to your computer and use it in GitHub Desktop.
Expand user model in Flask-Foundation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Somewhere in your app (Ex. foundation/base/yourapp/mixin.py | |
class NameMixin(object): | |
name = db.Column(db.String(50)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# You must enable your mixin in settings (Ex. foundation/base/config/production.py) | |
... | |
AUTH_USER_MIXINS = ['base.yourapp.mixin.NameMixin'] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment