From efde7c98c202405c4bbbd9d8832f3f92fc402468 Mon Sep 17 00:00:00 2001 From: MR Lemon Date: Fri, 1 May 2020 16:19:04 +0100 Subject: step 1 of form wizard done --- ctrack/organisations/forms.py | 3 ++ .../organisations/org_create_wizard_form.html | 48 +++++++++++++++++----- 2 files changed, 40 insertions(+), 11 deletions(-) (limited to 'ctrack') diff --git a/ctrack/organisations/forms.py b/ctrack/organisations/forms.py index 0903649..d9495f8 100644 --- a/ctrack/organisations/forms.py +++ b/ctrack/organisations/forms.py @@ -12,14 +12,17 @@ class OrganisationCreateForm(forms.ModelForm): self.fields["name"].widget.attrs["class"] = "form-control" self.fields["submode"].widget.attrs["class"] = "form-control" self.fields["oes"].widget.attrs["class"] = "form-check-input" + self.fields["active"].widget.attrs["class"] = "form-check-input" self.fields["designation_type"].widget.attrs["class"] = "form-control" self.fields["registered_company_name"].widget.attrs["class"] = "form-control" + self.fields["registered_company_number"].widget.attrs["class"] = "form-control" class Meta: model = Organisation fields = ["name", "submode", "oes", "designation_type", "registered_company_name", "registered_company_number", "updated_by", "comments", "active"] + # This doesn't have any effect when using the form wizard labels = { "oes": "OES" } diff --git a/ctrack/organisations/templates/organisations/org_create_wizard_form.html b/ctrack/organisations/templates/organisations/org_create_wizard_form.html index 8faa1a3..238a782 100644 --- a/ctrack/organisations/templates/organisations/org_create_wizard_form.html +++ b/ctrack/organisations/templates/organisations/org_create_wizard_form.html @@ -36,6 +36,20 @@ {{ wizard.form.name }} +
+
+
+ {{ wizard.form.oes }} + +
+
+ {{ wizard.form.active }} + +
+
+
+
+
@@ -51,22 +65,34 @@
-
- {{ wizard.form.oes }} - -
-
- - {{ wizard.form.registered_company_name }} - {{ wizard.form.registered_company_name.help_text }} +
+
+
+
+ + {{ wizard.form.registered_company_name }} + {{ wizard.form.registered_company_name.help_text }} +
+
+
+
+ + {{ wizard.form.registered_company_number }} + {{ wizard.form.registered_company_number.help_text }} +
+
{# {{ wizard.form }}#} {% endif %} {% if wizard.steps.prev %} - - + + {% endif %} - +
+
+ +
+
-- cgit v1.2.3