예제 #1
0
파일: token.py 프로젝트: gtie/VegaDNS-API
 def get_apikey(self, key, secret):
     return ApiKey().select(ApiKey, Account).join(
         Account,
         on=ApiKey.account_id == Account.account_id,
         attr='account_id').where(ApiKey.key == key,
                                  ApiKey.secret == secret,
                                  ApiKey.deleted == 0,
                                  Account.status == 'active').get()