diff --git a/opentech/apply/funds/management/commands/migration_base.py b/opentech/apply/funds/management/commands/migration_base.py index 34335f08c78e85b390a869d44a7f640f71af1255..d4dc29974eb7a7cf48f22c6a5162ed48743217dc 100644 --- a/opentech/apply/funds/management/commands/migration_base.py +++ b/opentech/apply/funds/management/commands/migration_base.py @@ -90,6 +90,9 @@ class MigrateCommand(BaseCommand): if "value" not in form_data: form_data["value"] = 0 + if "duration" not in form_data: + form_data["duration"] = 0 + submission.form_data = form_data try: diff --git a/opentech/apply/funds/management/commands/seed_community_lab_application.py b/opentech/apply/funds/management/commands/seed_community_lab_application.py index 6c9832ed30634b25454320b05b61abe741c8b5fd..c2483f49c2bb98e72de87fb4484d9d71abb37ff5 100644 --- a/opentech/apply/funds/management/commands/seed_community_lab_application.py +++ b/opentech/apply/funds/management/commands/seed_community_lab_application.py @@ -30,6 +30,7 @@ class Command(BaseCommand): {"type": "email", "value": {"field_label": "E-mail", "help_text": "", "info": None}, "id": "02a6cd0e-7ff6-46cd-9bdb-bf5858fe2514"}, {"type": "date", "value": {"field_label": "Date of event", "help_text": "", "required": "", "default_value": ""}, "id": "8c74af9c-6cc7-4558-9d72-0f2c9a87f22b"}, {"type": "value", "value": {"field_label": "Amount requested", "help_text": "", "info": None}, "id": "dfa76e03-0148-421b-a0fb-67f6fa1edee0"}, + {"type": "duration", "value": {"field_label": "Duration", "help_text": "", "info": None}, "id": "c61fbc9a-6da9-4293-9e21-3e20724bd36c"}, {"type": "text_markup", "value": "<h3>More information about your product</h3>", "id": "d2090b37-11e0-4282-8f98-5edfb05918c0"}, {"type": "rich_text", "value": {"field_label": "Please provide us a description of this event", "help_text": "", "required": "", "default_value": ""}, "id": "fe488e12-b5f4-491a-9ca9-d7aff0993884"}, {"type": "rich_text", "value": {"field_label": "Please describe the target audience(s)", "help_text": "", "required": "", "default_value": ""}, "id": "e7a0bc56-ad5d-4be7-9709-eb823a0e6e3d"}, diff --git a/opentech/apply/funds/management/commands/seed_concept_note.py b/opentech/apply/funds/management/commands/seed_concept_note.py index f1abcd52163e92a2f3a8fc0e18d3076a779dde6c..3e0c01f2cddf1bfa803029048596619e53935b86 100644 --- a/opentech/apply/funds/management/commands/seed_concept_note.py +++ b/opentech/apply/funds/management/commands/seed_concept_note.py @@ -63,7 +63,7 @@ class Command(BaseCommand): {"type": "text_markup", "value": "<h3>How will you do it?</h3>", "id": "e5fe71f5-8ec5-4ac9-ba21-38e03cdcf73b"}, {"type": "rich_text", "value": {"field_label": "Describe how", "help_text": "", "required": "", "default_value": ""}, "id": "418b8099-4525-437f-a55c-9b35745d0384"}, {"type": "category", "value": {"field_label": "Objective(s)", "help_text": "", "required": "", "category": objectives_id, "multi": "true"}, "id": "390702bd-e4e1-4dc2-8c43-d51bf018b427"}, - {"type": "dropdown", "value": {"field_label": "How long will it take?", "help_text": "", "required": "", "choices": ["1 month", "2 month", "3 month", "4 month", "5 month", "6 month", "7 month", "8 month", "9 month", "10 month", "11 month", "12 month", "18 month", "24 month"]}, "id": "a3fa1b0b-3e8e-4335-8c09-d1403668f01b"}, + {"type": "duration", "value": {"field_label": "How long will it take?", "help_text": "", "info": None}, "id": "b8d4f24f-c5bd-4a18-aa13-7c7358b3f99f"}, {"type": "value", "value": {"field_label": "How much do you want?", "help_text": "", "info": None}, "id": "1e669b4d-e43f-4c7a-9730-08e25cb1592d"}, {"type": "rich_text", "value": {"field_label": "How long have you been thinking of working on this idea? What made you first think about it?", "help_text": "", "required": "", "default_value": ""}, "id": "dfb9c307-9328-4a99-9efc-321d474b2ba7"}, {"type": "text_markup", "value": "<h3>Who is the project for?</h3>", "id": "563c12f1-d856-4ee2-a449-793bbfd12296"}, @@ -111,10 +111,11 @@ class Command(BaseCommand): {"type": "text_markup", "value": "<h3>Proposal information</h3>", "id": "f6bdb7e0-ec19-4b88-a2df-f0e7a512df8d"}, {"type": "title", "value": {"field_label": "Proposal title", "help_text": "", "info": None}, "id": "6a83b04d-0909-4018-bc77-f8d72a019dd4"}, {"type": "value", "value": {"field_label": "Requested funding", "help_text": "", "info": None}, "id": "0299f96f-3809-4f9e-a786-4af89547881b"}, - {"type": "full_name", "value": {"field_label": "Legal name", "help_text": "", "info": None}, "id": "739a413b-46cc-4936-82ce-e68c2dfa41ca"}, - {"type": "char", "value": {"field_label": "Commonly used name", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "d5cd3d89-89ea-44c2-9772-0da658c36881"}, + {"type": "duration", "value": {"field_label": "How long will it take?", "help_text": "", "info": None}, "id": "3ff602a1-642b-4742-a2c9-c9226af727ac"}, + {"type": "full_name", "value": {"field_label": "Your nameLegal name", "help_text": "", "info": None}, "id": "739a413b-46cc-4936-82ce-e68c2dfa41ca"}, + {"type": "char", "value": {"field_label": "Legal name", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "d5cd3d89-89ea-44c2-9772-0da658c36881"}, {"type": "char", "value": {"field_label": "Primary point of contact", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "a3c9af86-d047-4663-864a-b6dd97a60c39"}, - {"type": "email", "value": {"field_label": "E-mail address", "help_text": "", "info": None}, "id": "6c95d411-bd68-4374-8c2d-1b64dc03ed68"}, + {"type": "email", "value": {"field_label": "E-mail", "help_text": "", "info": None}, "id": "6c95d411-bd68-4374-8c2d-1b64dc03ed68"}, {"type": "char", "value": {"field_label": "Phone", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "40479d2a-7d53-4c81-834a-775ccd6c91c0"}, {"type": "address", "value": {"field_label": "Address", "help_text": "", "info": None}, "id": "f7e431b1-9965-4ebe-ab30-a00ff4b972ec"}, {"type": "text_markup", "value": "<h3>Proposal narrative</h3>", "id": "07f2ffb3-4eda-4f4c-8ebc-9da157e0102c"}, @@ -138,7 +139,7 @@ class Command(BaseCommand): {"type": "category", "value": {"field_label": "Addressed problems", "help_text": "", "required": "", "category": addressed_id, "multi": "true"}, "id": "a9b2b6de-fb7b-4709-aa59-f0ad987a677a"}, {"type": "category", "value": {"field_label": "Technology attributes", "help_text": "", "required": "", "category": tech_id, "multi": "true"}, "id": "251cf41a-0a49-4725-8d5a-5e496d018647"}, {"type": "category", "value": {"field_label": "Region", "help_text": "", "required": "", "category": regions_id, "multi": "true"}, "id": "ed6244ae-6903-4412-8b7a-c219ed25dfbb"}, - {"type": "category", "value": {"field_label": "", "help_text": "", "required": "", "category": countries_id, "multi": "true"}, "id": "4b79c527-bf24-47f1-87a7-39945e70caeb"}, + {"type": "category", "value": {"field_label": "Country", "help_text": "", "required": "", "category": countries_id, "multi": "true"}, "id": "4b79c527-bf24-47f1-87a7-39945e70caeb"}, {"type": "text_markup", "value": "<h3>Other</h3>", "id": "3cb5d831-bb5d-494a-946a-b24f7867027c"}, {"type": "multi_file", "value": {"field_label": "Upload", "help_text": "", "required": ""}, "id": "6bec61a1-3527-4e21-aa65-f26d845bbb68"}, {"type": "rich_text", "value": {"field_label": "Comments", "help_text": "", "required": "", "default_value": ""}, "id": "c0ff8444-8d43-46ef-8498-ed1a32c09c6a"} diff --git a/opentech/apply/funds/management/commands/seed_fellowship.py b/opentech/apply/funds/management/commands/seed_fellowship.py index 910fb405ac0acd1974d5c91ec9a5f79f28b4c409..6b84f43a3dd5c036b756c3c9d616398d03f17d9e 100644 --- a/opentech/apply/funds/management/commands/seed_fellowship.py +++ b/opentech/apply/funds/management/commands/seed_fellowship.py @@ -57,7 +57,7 @@ class Command(BaseCommand): {"type": "rich_text", "value": {"field_label": "What is your project idea?", "help_text": "", "required": "", "default_value": ""}, "id": "1eb8b4e3-e2bb-4810-a8ce-3fc82a3192c8"}, {"type": "rich_text", "value": {"field_label": "How would you do it?", "help_text": "", "required": "", "default_value": ""}, "id": "177d56e8-2df1-4ead-8e3d-4916610fbed6"}, {"type": "rich_text", "value": {"field_label": "Why are you the right person for this project?", "help_text": "", "required": "", "default_value": ""}, "id": "05ff1755-947b-4e41-8f71-aae99977c572"}, - {"type": "dropdown", "value": {"field_label": "How long do you want to work on this fellowship?", "help_text": "", "required": "", "choices": ["3 months", "6 months", "9 months", "12 months", "18 months"]}, "id": "611dacd7-553a-4be8-9283-1d006099d0c9"}, + {"type": "duration", "value": {"field_label": "How long do you want to work on this fellowship?", "help_text": "", "info": None}, "id": "3ccac109-2839-4b5d-b133-0e6cfca7c766"}, {"type": "text_markup", "value": "<h3>Host organization</h3>", "id": "f4b3ae6f-a1d6-4c9d-b334-e40614167257"}, {"type": "char", "value": {"field_label": "What is your most ideal host organization?", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "0afaf4e1-4556-4e79-aa3d-4990e33620da"}, {"type": "char", "value": {"field_label": "What is your next best host organization?", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "a543b34f-ae6a-4b17-8ac3-ececc14573a0"}, @@ -95,6 +95,7 @@ class Command(BaseCommand): {"type": "text_markup", "value": "<h3>Proposal information</h3>", "id": ""}, {"type": "title", "value": {"field_label": "Proposal title", "help_text": "", "info": None}, "id": ""}, {"type": "value", "value": {"field_label": "If you are applying for direct funding, how much do you need?", "help_text": "Amount requested should be less than 50000 USD.", "info": None}, "id": "cfae89dc-f327-45f4-80e9-f267c3bd1ec7"}, + {"type": "duration", "value": {"field_label": "How long do you want to work on this fellowship?", "help_text": "", "info": None}, "id": "08b9b5c3-e01d-41ac-95be-600a4fee7d87"}, {"type": "char", "value": {"field_label": "Host organisation", "help_text": "", "required": "", "format": "", "default_value": ""}, "id": "bc03235e-3c78-4770-9fc2-97feb93c2c8c"}, {"type": "date", "value": {"field_label": "Start date", "help_text": "", "required": "", "default_value": ""}, "id": "672cb6f1-335c-4005-a0f1-46c414feda06"}, {"type": "date", "value": {"field_label": "Completion date", "help_text": "", "required": "", "default_value": ""}, "id": "8262f209-f084-4a79-9dfa-2d18137119bb"}, diff --git a/opentech/apply/funds/management/commands/seed_rapid_response.py b/opentech/apply/funds/management/commands/seed_rapid_response.py index 88fcd884e45d0f811ea245ab3246becb4ca83de8..9ecb0d392a9d726d95e6485f57fb64f1c1339a4d 100644 --- a/opentech/apply/funds/management/commands/seed_rapid_response.py +++ b/opentech/apply/funds/management/commands/seed_rapid_response.py @@ -51,7 +51,7 @@ class Command(BaseCommand): {"type": "value", "value": {"field_label": "If you are applying for direct funding, how much do you need?", "help_text": "Amount requested should be less than 50000 USD.", "info": None}, "id": "cfae89dc-f327-45f4-80e9-f267c3bd1ec7"}, {"type": "dropdown", "value": {"field_label": "If you are requesting to receive or provide a service, what is it?", "help_text": "", "required": "", "choices": ["Audit of presumably compromised websites", "DDoS response and mitigation", "Secure web hosting", "monitoring and resiliency of websites during special events (elections, campaigns etc.)", "VPN connections", "Safe internet connections", "Forensic analysis of digital attacks", "Recovery of compromised websites", "Malware analysis", "Equipment replacements", "Finding legal representation", "Payment of legal fees"]}, "id": "ebdf9a22-58c7-4bd6-a58d-e71363357470"}, {"type": "rich_text", "value": {"field_label": "If not listed above, what other services do you want to provide or receive?", "help_text": "", "required": "", "default_value": ""}, "id": "c8c329c7-78e4-4cbf-a3b1-77a1324e92ff"}, - {"type": "dropdown", "value": {"field_label": "How long will it take?", "help_text": "", "required": "true", "choices": ["1 month", "2 months", "3 months", "4 months", "5 months", "6 months"]}, "id": "806d401c-b52c-46f7-9e96-f36fa70f53d8"}, + {"type": "duration", "value": {"field_label": "How long will it take?", "help_text": "", "info": None}, "id": "b47f84f5-81bc-4aff-a865-5b927f504246"}, {"type": "rich_text", "value": {"field_label": "What is the challenge you are trying to address and who will it help?", "help_text": "Please briefly provide contextual or background information regarding the problem you would like to address and the target groups/communities you are trying to help.", "required": "true", "default_value": ""}, "id": "1ec16cdc-7a68-40be-b17b-9a218def4260"}, {"type": "rich_text", "value": {"field_label": "What are you proposing to do and how will you accomplish it?", "help_text": "In other words, please describe your project\u2019s overall goal as well as specific objectives. What activities are you going to carry out in order to achieve your objectives?", "required": "true", "default_value": ""}, "id": "4fa2ac11-d1cd-4d23-8082-93a14c8f99c8"}, {"type": "rich_text", "value": {"field_label": "Anticipated outputs and outcomes", "help_text": "", "required": "true", "default_value": ""}, "id": "3cde39ae-b687-4c4f-b58b-849396c2fdb8"},