From 006262c7eaafe8fded74398c3c89c0b21f7ed85d Mon Sep 17 00:00:00 2001 From: Carl van Tonder Date: Thu, 24 May 2018 20:52:43 -0400 Subject: [PATCH] Lengthen "key actors" and "who..involved" fields --- .../map/migrations/0062_auto_20180525_0035.py | 76 +++++++++++++++++++ .../map/migrations/0063_auto_20180525_0052.py | 25 ++++++ apps/map/models.py | 14 +--- 3 files changed, 105 insertions(+), 10 deletions(-) create mode 100644 apps/map/migrations/0062_auto_20180525_0035.py create mode 100644 apps/map/migrations/0063_auto_20180525_0052.py diff --git a/apps/map/migrations/0062_auto_20180525_0035.py b/apps/map/migrations/0062_auto_20180525_0035.py new file mode 100644 index 0000000..6698e9c --- /dev/null +++ b/apps/map/migrations/0062_auto_20180525_0035.py @@ -0,0 +1,76 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.6 on 2018-05-25 00:35 +from __future__ import unicode_literals + +from django.db import migrations, models +import multiselectfield.db.fields + + +class Migration(migrations.Migration): + + dependencies = [ + ('map', '0061_auto_20180523_1659'), + ] + + operations = [ + migrations.AlterField( + model_name='casestudy', + name='biomass_detail', + field=models.CharField(blank=True, default=None, help_text='If you selected biogas or biomass, please describe the feedstock (where the fuel came from e.g. corn, algae, anaerobic digestion, commercial waste etc.)', max_length=200, null=True, verbose_name='Description of feedstock'), + ), + migrations.AlterField( + model_name='casestudy', + name='community_voices', + field=models.TextField(blank=True, default=None, help_text='Add any direct quotes from members of the community that relate to this project', null=True, verbose_name='Community voices'), + ), + migrations.AlterField( + model_name='casestudy', + name='entry_name', + field=models.CharField(help_text='Enter the name of the entry. This should usually be the name of the project.', max_length=128, verbose_name='Name'), + ), + migrations.AlterField( + model_name='casestudy', + name='full_description', + field=models.TextField(help_text='Describe the project in full. Separate paragraphs with a new line Please add as much detail as you feel is necessary here.', verbose_name='Full description'), + ), + migrations.AlterField( + model_name='casestudy', + name='generation_technology', + field=models.CharField(blank=True, choices=[('Wind energy', (('SSWE', 'Small-scale (less than 500 kW)'), ('LSWE', 'Large-scale (more than 500kW)'))), ('Photovoltaic electricity', (('SSPV', 'Small-scale (less than 500 kW)'), ('LSPV', 'Large-scale (more than 500kW)'))), ('Hydroelectric', (('SHYD', 'Small-scale (less than 1MW)'), ('MHYD', 'Medium-scale (between 1-20MW)'), ('LHYD', 'Large-scale (more than 20MW - often not considered renewable)'))), ('STHE', 'Solar thermal electricity (e.g. using parabolic reflectors)'), ('GEOT', 'Geothermal electricity'), ('BIOG', 'Biogas turbine'), ('OTHB', 'Other biomass (including liquid/solid biofuel)'), ('OTHR', 'Other (tidal, wave etc.)')], default=None, help_text='Select the type of renewable energy generation that most applies to this case study.', max_length=4, null=True, verbose_name='Generation technology'), + ), + migrations.AlterField( + model_name='casestudy', + name='generation_technology_other', + field=models.CharField(blank=True, default=None, help_text='If you selected other, please specify the generation technology (e.g. tidal, wave etc.)', max_length=200, null=True, verbose_name='Other generation type'), + ), + migrations.AlterField( + model_name='casestudy', + name='land_ownership', + field=models.CharField(choices=[('PRI', 'Private land'), ('PUB', 'Public land'), ('COM', 'Community land'), ('OTH', 'Other')], help_text='What type of ownership/tenure does the land fall under?', max_length=3, verbose_name='Land ownership/tenure'), + ), + migrations.AlterField( + model_name='casestudy', + name='land_ownership_details', + field=models.CharField(blank=True, help_text="Please specify details about land ownership if you chose 'other'", max_length=256, null=True, verbose_name='Land ownership/tenure details'), + ), + migrations.AlterField( + model_name='casestudy', + name='power_technology', + field=models.CharField(blank=True, choices=[('PT', 'Power transmission (power lines, substations etc.)'), ('ES', 'Energy storage (pumped storage, compressed air, battery systems etc.)'), ('OT', 'Others')], default=None, help_text='Select the related energy technology.', max_length=2, null=True, verbose_name='Power technology'), + ), + migrations.AlterField( + model_name='casestudy', + name='project_status', + field=models.CharField(choices=[('EXSTNG', 'Existing project'), ('UCONST', 'Under construction'), ('PROJCD', 'Planned project')], help_text='What is the current status of the project?', max_length=6, verbose_name='Status of project'), + ), + migrations.AlterField( + model_name='casestudy', + name='sector_of_economy', + field=models.CharField(choices=[('RN', 'Renewable energy generation'), ('PG', 'Power grids'), ('SM', 'Supply of minerals')], help_text='Which sector of the renewable energy economy is most relevant?', max_length=3, verbose_name='Sector of the renewable energy economy'), + ), + migrations.AlterField( + model_name='casestudy', + name='type_of_ecosystem', + field=multiselectfield.db.fields.MultiSelectField(blank=True, choices=[('MARINE', 'Marine (e.g. ocean, sea)'), ('FRESH', 'Freshwater (e.g. freshwater, lake)'), ('FOREST', 'Forest/jungle'), ('AGRI', 'Agricultural land'), ('GRASS', 'Grassland'), ('DESERT', 'Desert (tundra, ice or sand)'), ('WETLND', 'Wetland (marsh, mangrove, peat soil)'), ('URBAN', 'Urban')], default=None, help_text='Select the most relevant type(s).', max_length=56, null=True, verbose_name='Type(s) of ecosystem'), + ), + ] diff --git a/apps/map/migrations/0063_auto_20180525_0052.py b/apps/map/migrations/0063_auto_20180525_0052.py new file mode 100644 index 0000000..0ef81b5 --- /dev/null +++ b/apps/map/migrations/0063_auto_20180525_0052.py @@ -0,0 +1,25 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.6 on 2018-05-25 00:52 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('map', '0062_auto_20180525_0035'), + ] + + operations = [ + migrations.AlterField( + model_name='casestudy', + name='key_actors_involved', + field=models.TextField(blank=True, null=True, verbose_name='Key actors involved (individual/organisational)'), + ), + migrations.AlterField( + model_name='casestudy', + name='who_has_been_involved', + field=models.TextField(blank=True, null=True, verbose_name='Which communities, groups and organisations have been involved?'), + ), + ] diff --git a/apps/map/models.py b/apps/map/models.py index d1caf67..89db88b 100644 --- a/apps/map/models.py +++ b/apps/map/models.py @@ -813,12 +813,9 @@ class CaseStudy(models.Model): ) # 3.1.3 + 3.2.5 - key_actors_involved = models.CharField( + key_actors_involved = models.TextField( verbose_name=_('Key actors involved (individual/organisational)'), - max_length=256, - default=None, - null=True, - blank=True + blank=True, null=True ) # 3.1.4 @@ -944,12 +941,9 @@ class CaseStudy(models.Model): ) # 3.2.4.2 - who_has_been_involved = models.CharField( + who_has_been_involved = models.TextField( verbose_name=_("Which communities, groups and organisations have been involved?"), - max_length=512, - default=None, - null=True, - blank=True + blank=True, null=True ) # 3.2.4.3