|
@ -28,9 +28,10 @@ class DiagnosticoMobileForm(BaseDynamicEntityForm): |
|
|
self._build_dynamics_fields(category) |
|
|
self._build_dynamics_fields(category) |
|
|
|
|
|
|
|
|
def __iter__(self): |
|
|
def __iter__(self): |
|
|
fields_by_label = [ (field.label, field) for field in self.fields.values()] |
|
|
# ordena os campos do formulario usando o atributo label |
|
|
for label, field in sorted(fields_by_label): |
|
|
fields_by_label = [(field.label, name, field) for name, field in self.fields.items()] |
|
|
yield BoundField(self, field, field.label) |
|
|
for label, name, field in sorted(fields_by_label): |
|
|
|
|
|
yield BoundField(self, field, name) |
|
|
|
|
|
|
|
|
def _build_dynamics_fields(self, category): |
|
|
def _build_dynamics_fields(self, category): |
|
|
"""Método da classe ``BaseDynamicEntityForm`` sobrescrita, |
|
|
"""Método da classe ``BaseDynamicEntityForm`` sobrescrita, |
|
|