2012-02-24 10 views

Odpowiedz

13

Można złapać ten nadrzędnymi build_filters:

from tastypie.exceptions import BadRequest 

def build_filters(self, filters=None): 
    if 'language' not in filters: 
     raise BadRequest("missing language param") # or maybe create your own exception 
    return super(LinguistResource, self).build_filters(filters)