예제 #1
0
파일: forms.py 프로젝트: kriberg/eve-armada
 def clean_location(self):
     name = self.cleaned_data['location']
     try:
         get_location_id(name)
         return name
     except:
         raise ValidationError('Location does not exist.')
예제 #2
0
 def get_location_id(self):
     return get_location_id(self.location)