Created
April 30, 2017 12:11
-
-
Save marcelolebre/4f8b7cb1ab60fc1944c099a257e15fbc to your computer and use it in GitHub Desktop.
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
class RoleFinder(object): | |
@classmethod | |
def get_from_id(cls, role_id): | |
return Role.query.get(role_id) | |
@classmethod | |
def get_from_app(cls, app_id): | |
return Role.query.filter_by(app_id=app_id).first() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment