diff --git a/app/main/templates/agent.html b/app/main/templates/agent.html index e17edbd..362e9ad 100644 --- a/app/main/templates/agent.html +++ b/app/main/templates/agent.html @@ -52,8 +52,6 @@ {# TODO: put different spacing #}
-
APPRENTI
-
Fiche de poste :
{# TODO: put different spacing #} diff --git a/app/main/templates/agent_edit.html b/app/main/templates/agent_edit.html index 2919111..bbf541b 100644 --- a/app/main/templates/agent_edit.html +++ b/app/main/templates/agent_edit.html @@ -18,9 +18,15 @@ -
- - +
+ + +
+
+ +
@@ -38,10 +44,6 @@
-
- - -
{% endblock %} diff --git a/app/models.py b/app/models.py index cbc3013..5d2a612 100644 --- a/app/models.py +++ b/app/models.py @@ -111,7 +111,11 @@ class Agent(db.Model): :return: """ for key in self.export_keys: - setattr(self, key, form_request.form[key]) + # deal with checked value + if key in ['permanent', 'virtual']: + setattr(self, key, form_request.form.get(key)) + else: + setattr(self, key, form_request.form[key]) class Service(db.Model): -- libgit2 0.21.2