From fafb47586910aace061c09e4187a35671e9bfe0c Mon Sep 17 00:00:00 2001 From: Anna Sidwell Date: Sat, 31 Mar 2018 20:59:42 +1100 Subject: [PATCH] Fiddle with form layout a bit to add coherence --- apps/map/forms.py | 30 ++++++++++++++++++------------ apps/map/templates/map/form.html | 2 +- 2 files changed, 19 insertions(+), 13 deletions(-) diff --git a/apps/map/forms.py b/apps/map/forms.py index 36c50df..6d7bd13 100644 --- a/apps/map/forms.py +++ b/apps/map/forms.py @@ -77,8 +77,6 @@ class LongCaseStudyForm(BaseCaseStudyForm): Tab(_("Basic information"), 'entry_name', 'location', - 'sector_of_economy', - 'positive_or_negative', 'country', 'area_of_land', 'land_ownership', @@ -91,28 +89,35 @@ class LongCaseStudyForm(BaseCaseStudyForm): 'project_status', 'synopsis', 'full_description', - 'project_owners', - 'shareholders', - 'financial_institutions', - 'financial_institutions_other', - 'energy_customers', 'image', 'image_caption', 'image_credit', 'video', 'video_caption', 'video_credit', - 'media_coverage_mainstream', - 'media_coverage_independent', - 'community_voices', - 'direct_comms', - 'social_media_links', + Fieldset( + _("Ownership and finance"), + 'project_owners', + 'shareholders', + 'financial_institutions', + 'financial_institutions_other', + 'energy_customers' + ), + Fieldset( + _("Media reports and other communications"), + 'media_coverage_mainstream', + 'media_coverage_independent', + 'community_voices', + 'direct_comms', + 'social_media_links' + ), FormActions( HTML(""+_("Next")+"") ) ), Tab( _("Technical and economic analysis"), + 'sector_of_economy', Fieldset( _("Power Generation Questions"), 'generation_technology', @@ -156,6 +161,7 @@ class LongCaseStudyForm(BaseCaseStudyForm): ), Tab( _("Socio-environmental analysis"), + 'positive_or_negative', Fieldset( _("Positive Case Questions"), 'positive_case_type', diff --git a/apps/map/templates/map/form.html b/apps/map/templates/map/form.html index 5d6e45e..1d6ef82 100644 --- a/apps/map/templates/map/form.html +++ b/apps/map/templates/map/form.html @@ -64,7 +64,7 @@ { // 2.1 - Power Generation "field": "#id_sector_of_economy", "showHide": ["#power_generation_questions"], - "condition": ["RNW"] + "condition": ["RN"] }, { "field": "#id_generation_technology",