Exemple #1
0
 def __init__(self, *args, **kwargs):
     super(UpdateProfileForm, self).__init__(*args, **kwargs)
     self.services.choices = [
         (service.id, service.name) for service in Service.all()
     ]
Exemple #2
0
 def __init__(self, *args, **kwargs):
     super(BaseUserForm, self).__init__(*args, **kwargs)
     self.services.choices = [
         (service.id, service.name) for service in Service.all()
     ]
     self.validate_unique_email = kwargs.get('validate_unique_email', True)
Exemple #3
0
 def __init__(self, *args, **kwargs):
     super(AlertForm, self).__init__(*args, **kwargs)
     self.needs.choices = [
         (service.id, service.name) for service in Service.all()
     ]
Exemple #4
0
 def __init__(self, *args, **kwargs):
     super(BaseUserForm, self).__init__(*args, **kwargs)
     self.services.choices = [(service.id, service.name)
                              for service in Service.all()]
     self.validate_unique_email = kwargs.get('validate_unique_email', True)
Exemple #5
0
 def __init__(self, *args, **kwargs):
     super(UpdateProfileForm, self).__init__(*args, **kwargs)
     self.services.choices = [(service.id, service.name)
                              for service in Service.all()]
Exemple #6
0
 def __init__(self, *args, **kwargs):
     super(AlertForm, self).__init__(*args, **kwargs)
     self.needs.choices = [(service.id, service.name)
                           for service in Service.all()]
Exemple #7
0
def get_services():
    """
    Gets the list of services.
    """
    # TODO: pagination
    return jsonify(Service.all())