From b5611b65054ff3829421bf21405faeb7f2b066fb Mon Sep 17 00:00:00 2001 From: Joe Evans Date: Wed, 4 Mar 2026 16:30:27 +0000 Subject: [PATCH 1/2] Add migration files from live server --- activity/migrations/0001_initial.py | 135 ++++ analytics/migrations/0001_initial.py | 211 +++++ .../migrations/0002_auto_20221123_1733.py | 28 + ...saction_ballot_item_we_vote_id_and_more.py | 23 + ...4_analyticsaction_politician_we_vote_id.py | 18 + ...ction_election_action_constant_and_more.py | 21 + ...006_analyticsaction_voter_date_and_more.py | 29 + api_internal_cache/migrations/0001_initial.py | 39 + apple/migrations/0001_initial.py | 31 + .../0002_alter_appleuser_voter_we_vote_id.py | 18 + ballot/migrations/0001_initial.py | 100 +++ .../0002_alter_ballotitem_measure_url.py | 18 + ...ed_polling_location_we_vote_id_and_more.py | 33 + ...llotitem_ballot_ball_google__7fb0d0_idx.py | 17 + ...idx_election_poll_office_index_and_more.py | 35 + ...lter_ballotreturned_we_vote_id_and_more.py | 38 + ...tem_election_poll_office_index_and_more.py | 37 + .../0008_ballotitem_election_state_index.py | 17 + bookmark/migrations/0001_initial.py | 35 + ...kmarkitem_candidate_we_vote_id_and_more.py | 33 + campaign/migrations/0001_initial.py | 137 ++++ ...ampaignxpolitician_candidate_we_vote_id.py | 18 + .../migrations/0003_auto_20230410_1203.py | 23 + .../migrations/0004_auto_20230516_0835.py | 33 + .../migrations/0005_auto_20230521_1027.py | 23 + ...ter_campaignxsupporter_voter_we_vote_id.py | 18 + ...7_campaignx_ocd_id_state_mismatch_found.py | 18 + ...ampaignx_ocd_id_state_mismatch_resolved.py | 18 + ...cd_id_state_mismatch_checked_politician.py | 18 + .../0010_campaignxentriesarenotduplicates.py | 21 + ...d_state_mismatch_checked_campaign_title.py | 18 + ..._campaignx_linked_politician_we_vote_id.py | 18 + ...ampaignx_profile_image_background_color.py | 18 + ...x_linked_politician_we_vote_id_verified.py | 18 + ...nxentriesarepossibleduplicates_and_more.py | 27 + .../0016_campaignx_opposers_count.py | 18 + ...plicates_campaignx1_we_vote_id_and_more.py | 43 + ...orters_count_to_update_with_bulk_script.py | 18 + .../0019_campaignx_organization_we_vote_id.py | 18 + .../0020_alter_campaignx_seo_friendly_path.py | 18 + ..._campaignx_linked_politician_we_vote_id.py | 18 + ...gnx_passkey_for_creating_campaign_owner.py | 18 + candidate/migrations/0001_initial.py | 155 ++++ .../migrations/0002_auto_20220522_1747.py | 28 + ..._candidatecampaign_is_battleground_race.py | 18 + ...candidatecampaign_ballotpedia_office_id.py | 18 + .../migrations/0005_auto_20230126_1420.py | 33 + ...campaign_twitter_handle_updates_failing.py | 18 + .../migrations/0007_auto_20230210_1159.py | 28 + ...andidatecampaign_office_held_we_vote_id.py | 18 + ...009_candidatecampaign_seo_friendly_path.py | 18 + ...ign_seo_friendly_path_date_last_updated.py | 18 + .../migrations/0011_auto_20230504_0648.py | 23 + ...0012_candidatecampaign_supporters_count.py | 18 + .../migrations/0013_auto_20230524_1618.py | 63 ++ .../0014_candidatecampaign_district_name.py | 18 + .../migrations/0015_auto_20230629_0744.py | 23 + ...ampaign_ballot_guide_official_statement.py | 18 + ...idatecampaign_representative_we_vote_id.py | 18 + .../migrations/0018_auto_20231216_1125.py | 23 + ...campaign_profile_image_background_color.py | 18 + ...ndidatecampaign_candidate_analysis_done.py | 18 + .../migrations/0021_auto_20240210_1816.py | 112 +++ .../migrations/0022_auto_20240214_2151.py | 48 ++ ...023_candidatecampaign_race_office_level.py | 18 + .../migrations/0024_auto_20240407_1401.py | 88 +++ .../migrations/0025_auto_20240409_0659.py | 23 + ...n_profile_image_background_color_needed.py | 18 + ...ampaign_ballotpedia_photo_url_is_broken.py | 18 + ...gn_ballotpedia_photo_url_is_placeholder.py | 18 + ...atecampaign_facebook_photo_url_and_more.py | 23 + ...tecampaign_facebook_photo_url_is_broken.py | 18 + ...campaign_wikipedia_photo_does_not_exist.py | 18 + ...ign_candidate_contact_form_url_and_more.py | 23 + ...n_ballotpedia_candidate_links_retrieved.py | 18 + .../0034_candidatesarepossibleduplicates.py | 22 + ...andidatecampaign_politician_id_and_more.py | 23 + .../0036_alter_candidatecampaign_ctcl_uuid.py | 18 + ...campaign_candidate_c_seo_fri_694764_idx.py | 17 + ...candidate_c_seo_fri_694764_idx_and_more.py | 33 + ...paign_list_politician_and_name_and_more.py | 21 + ..._candidate_list_for_politician_and_more.py | 21 + ...ndidatecampaign_candidate_year_and_more.py | 26 + ...0042_candidatectclalternatemap_and_more.py | 26 + ...ndidatecampaign_bluesky_handle_and_more.py | 43 + ...44_candidatecampaign_is_claimed_profile.py | 18 + ...imate_election_date_calculated_and_more.py | 23 + ...ndidatecampaign_threads_handle_and_more.py | 28 + ...duplicationneededforstatetoday_and_more.py | 93 +++ .../0048_candidatecampaign_opposers_count.py | 18 + challenge/migrations/0001_initial.py | 167 ++++ ...pant_delete_challengesupporter_and_more.py | 55 ++ ...icipant_is_subscribed_by_email_and_more.py | 60 ++ .../0004_challengeinvitee_and_more.py | 83 ++ ...vitee_invite_text_from_inviter_and_more.py | 32 + ...einvitee_date_challenge_joined_and_more.py | 28 + ...engeparticipant_invitees_count_and_more.py | 38 + ...challengeparticipant_invites_sent_count.py | 18 + ...engeinvitee_invitee_voter_name_and_more.py | 33 + .../0010_remove_challenge_opposers_count.py | 17 + election/migrations/0001_initial.py | 64 ++ ..._vote_usa_same_day_election_suffix_list.py | 18 + .../migrations/0003_auto_20220727_1420.py | 28 + .../migrations/0004_auto_20230616_0717.py | 23 + electoral_district/migrations/0001_initial.py | 48 ++ email_outbound/migrations/0001_initial.py | 96 +++ ...bounddescription_kind_of_email_template.py | 18 + .../migrations/0003_auto_20220720_1721.py | 33 + ...bounddescription_kind_of_email_template.py | 18 + ..._emailaddress_voter_we_vote_id_and_more.py | 53 ++ ...ailcampaign_emailcampaignlabel_and_more.py | 83 ++ ..._emailtemplate_email_template_folder_id.py | 18 + ...e_emailrecipienttemplatefolder_and_more.py | 72 ++ ...ilcampaign_scheduled_send_time_and_more.py | 23 + .../0010_emailcampaign_from_email_and_more.py | 28 + ...mpaignrecipient_recipient_name_and_more.py | 152 ++++ ...der_emailaudiencebuilderfolder_and_more.py | 76 ++ ...gnrecipient_open_tracking_code_and_more.py | 33 + ...encefilter_audiencefilterchain_and_more.py | 118 +++ ...in_filter1_to_filter2_operator_and_more.py | 53 ++ ...ilter_boolean_contact_contains_and_more.py | 156 ++++ .../0017_emailcampaign_audience_builder_id.py | 18 + follow/migrations/0001_initial.py | 83 ++ ...r_followissue_following_status_and_more.py | 23 + ...r_followcampaignx_campaignx_id_and_more.py | 58 ++ ...zation_organization_we_vote_id_and_more.py | 23 + ...n_organization_we_vote_id_that_is_follo.py | 18 + friend/migrations/0001_initial.py | 102 +++ friend/migrations/0002_auto_20220619_0823.py | 69 ++ friend/migrations/0003_auto_20220623_1210.py | 33 + friend/migrations/0004_auto_20220707_0808.py | 23 + ...iontwitterlink_recipient_twitter_handle.py | 18 + ...ink_recipient_email_we_vote_id_and_more.py | 33 + ...rrentfriend_curr_viewer_viewee_and_more.py | 29 + .../migrations/0001_initial.py | 54 ++ .../migrations/0002_auto_20240211_0925.py | 48 ++ googlebot_site_map/migrations/0001_initial.py | 26 + image/migrations/0001_initial.py | 84 ++ ...2_wevoteimage_representative_we_vote_id.py | 18 + .../0003_wevoteimage_politician_we_vote_id.py | 18 + image/migrations/0004_auto_20230606_1749.py | 23 + image/migrations/0005_auto_20230806_1012.py | 23 + ..._wevoteimage_is_active_version_and_more.py | 22 + ..._wevoteimage_is_active_version_and_more.py | 26 + .../migrations/0001_initial.py | 56 ++ .../migrations/0001_initial.py | 743 ++++++++++++++++++ .../migrations/0002_auto_20220727_1420.py | 33 + ...0003_alter_batchprocess_kind_of_process.py | 18 + .../migrations/0004_auto_20230104_0640.py | 38 + .../migrations/0005_auto_20230106_1130.py | 33 + .../migrations/0006_auto_20230110_0710.py | 82 ++ .../migrations/0007_auto_20230201_1248.py | 44 ++ .../migrations/0008_auto_20230203_0925.py | 28 + .../migrations/0009_auto_20230203_1547.py | 48 ++ ...0_alter_batchrowactionpolitician_gender.py | 18 + .../migrations/0011_auto_20240129_0555.py | 28 + ...onorganization_organization_ballotpedia.py | 18 + ...tionorganization_organization_wikipedia.py | 18 + ...er_batchrowactionposition_more_info_url.py | 18 + ...er_batchdescription_source_uri_and_more.py | 48 ++ ...0016_alter_batchprocess_kind_of_process.py | 18 + ...0017_alter_batchprocess_kind_of_process.py | 18 + ...0018_alter_batchprocess_kind_of_process.py | 18 + ...0019_alter_batchprocess_kind_of_process.py | 18 + .../migrations/0001_initial.py | 35 + import_export_ctcl/migrations/0001_initial.py | 61 ++ .../migrations/0001_initial.py | 92 +++ .../migrations/0001_initial.py | 52 ++ .../migrations/0001_initial.py | 47 ++ .../migrations/0001_initial.py | 49 ++ .../migrations/0001_initial.py | 35 + ..._openreplayevent_base_referrer_and_more.py | 188 +++++ .../migrations/0001_initial.py | 49 ++ .../migrations/0001_initial.py | 49 ++ .../migrations/0001_initial.py | 31 + .../migrations/0002_auto_20240303_1539.py | 43 + ...e_twitter_voters_access_secret_and_more.py | 37 + .../migrations/0001_initial.py | 230 ++++++ .../migrations/0001_initial.py | 52 ++ issue/migrations/0001_initial.py | 46 ++ .../0002_issue_forced_sort_order.py | 18 + ...ter_organizationlinktoissue_link_active.py | 18 + .../migrations/0004_alter_issue_we_vote_id.py | 18 + ...05_issue_hide_issue_we_vote_id_and_more.py | 25 + ...ktoissue_issue_org_link_active_and_more.py | 21 + measure/migrations/0001_initial.py | 92 +++ .../0002_alter_measurecampaign_url.py | 18 + ...es_contest_measure1_we_vote_id_and_more.py | 28 + ...asure_ballotpedia_measure_name_and_more.py | 58 ++ office/migrations/0001_initial.py | 82 ++ ..._battleground_race_cached_in_candidates.py | 18 + office/migrations/0003_auto_20230110_0710.py | 22 + ...04_contestoffice_office_held_we_vote_id.py | 18 + ..._battleground_race_cached_in_candidates.py | 17 + ...battleground_race_spread_to_all_objects.py | 18 + office/migrations/0007_auto_20230419_1557.py | 48 ++ office/migrations/0008_auto_20230531_0902.py | 23 + ..._contestoffice_election_date_as_integer.py | 18 + ...tes_contest_office1_we_vote_id_and_more.py | 28 + ...alter_contestoffice_we_vote_id_and_more.py | 22 + ..._office_explanation_we_vote_id_and_more.py | 35 + office_held/migrations/0001_initial.py | 44 ++ .../migrations/0002_auto_20230126_1420.py | 209 +++++ .../migrations/0003_auto_20230201_1248.py | 42 + .../migrations/0004_auto_20230222_1441.py | 28 + .../migrations/0005_auto_20230306_1649.py | 43 + .../0006_officeheld_office_held_url.py | 18 + .../migrations/0007_auto_20230311_0908.py | 23 + .../migrations/0008_auto_20230423_0727.py | 23 + .../migrations/0009_auto_20230531_0902.py | 23 + .../migrations/0010_auto_20230629_0744.py | 23 + .../migrations/0011_auto_20230827_1805.py | 23 + ...fficeheld_office_explanation_we_vote_id.py | 18 + organization/migrations/0001_initial.py | 151 ++++ .../migrations/0002_auto_20221007_1756.py | 23 + .../migrations/0003_auto_20230210_1159.py | 133 ++++ .../migrations/0004_organizationchangelog.py | 25 + .../migrations/0005_auto_20230804_1408.py | 28 + .../migrations/0006_auto_20240129_0555.py | 23 + ...ion_profile_image_type_currently_active.py | 18 + ...rganization_facebook_photo_url_and_more.py | 23 + ..._organization_contact_form_url_and_more.py | 23 + ...lter_organization_organization_facebook.py | 18 + ..._organization_instagram_handle_and_more.py | 38 + ...er_organization_twitter_followers_count.py | 18 + ...og_changed_by_voter_we_vote_id_and_more.py | 58 ++ ...organization_politicians_match_and_more.py | 25 + ..._organization_politicians_sort_and_more.py | 46 ++ ...hallenge_owned_by_organization_and_more.py | 28 + ..._organizationsarenotduplicates_and_more.py | 30 + ..._bluesky_handle_organization_tiktok_url.py | 23 + ...organization_augmentation_done_and_more.py | 28 + .../0020_organization_help_needed.py | 18 + party/migrations/0001_initial.py | 25 + .../migrations/0002_alter_party_we_vote_id.py | 18 + pledge_to_vote/migrations/0001_initial.py | 29 + politician/migrations/0001_initial.py | 94 +++ .../migrations/0002_auto_20230104_0640.py | 38 + .../migrations/0003_auto_20230106_1130.py | 113 +++ .../migrations/0004_auto_20230126_1420.py | 43 + .../migrations/0005_auto_20230128_1026.py | 38 + .../migrations/0006_auto_20230201_1248.py | 33 + .../migrations/0007_auto_20230203_1547.py | 48 ++ .../migrations/0008_auto_20230208_1449.py | 98 +++ .../0009_politiciansarepossibleduplicates.py | 22 + .../migrations/0010_auto_20230306_1649.py | 53 ++ .../migrations/0011_auto_20230320_1111.py | 29 + ...ian_seo_friendly_path_date_last_updated.py | 18 + ..._politician_linked_campaignx_we_vote_id.py | 18 + ..._campaignx_we_vote_id_date_last_updated.py | 18 + .../0015_politician_supporters_count.py | 18 + .../migrations/0016_auto_20230606_1749.py | 43 + ..._google_civic_name_alternates_generated.py | 18 + ...0018_politician_photo_url_from_vote_usa.py | 18 + ..._politician_ocd_id_state_mismatch_found.py | 18 + ...an_seo_friendly_path_needs_regeneration.py | 18 + ...itician_ballot_guide_official_statement.py | 18 + .../migrations/0022_auto_20230720_0429.py | 23 + .../migrations/0023_auto_20231216_1125.py | 23 + ...n_profile_image_background_color_needed.py | 18 + .../migrations/0025_auto_20240210_1816.py | 93 +++ .../migrations/0026_auto_20240407_1401.py | 54 ++ ...itician_ballotpedia_photo_url_is_broken.py | 18 + ...an_ballotpedia_photo_url_is_placeholder.py | 18 + ...9_recommendedpoliticianlinkbypolitician.py | 21 + ...litician_wikipedia_photo_does_not_exist.py | 18 + ..._politician_politician_contact_form_url.py | 18 + ...n_ballotpedia_candidate_links_retrieved.py | 18 + ...0033_politician_opposers_count_and_more.py | 33 + .../0034_alter_politician_we_vote_id.py | 18 + ..._organization_manual_intervention_neede.py | 37 + ...organization_analysis_complete_and_more.py | 23 + ...te_election_last_updated_from_candidate.py | 18 + ...y_handle_politician_tiktok_url_and_more.py | 43 + ...an_linked_campaignx_we_vote_id_verified.py | 18 + .../0040_politician_is_claimed_profile.py | 18 + .../migrations/0041_politiciansupporter.py | 39 + ...paignx_we_vote_id_verified_in_campaignx.py | 18 + ...0043_politician_threads_handle_and_more.py | 28 + ...duplicationneededforstatetoday_and_more.py | 78 ++ ...045_remove_politician_tag_link_and_more.py | 31 + polling_location/migrations/0001_initial.py | 61 ++ .../migrations/0002_auto_20230126_1420.py | 23 + ...nlogentry_kind_of_log_entry_and_deleted.py | 17 + ...onlogentry_log_entry_one_location_index.py | 17 + ...ntry_we_vote_id_and_kind_index_and_more.py | 21 + ...6_pollinglocation_state_and_not_deleted.py | 17 + ...nlogentry_deleted_and_kind_of_log_entry.py | 17 + ...ntry_kind_and_we_vote_id_index_and_more.py | 21 + position/migrations/0001_initial.py | 167 ++++ .../migrations/0002_auto_20230331_1340.py | 23 + .../migrations/0003_auto_20230521_1027.py | 23 + .../migrations/0004_auto_20240129_0555.py | 33 + ..._positionentered_more_info_url_and_more.py | 23 + ..._positions_for_candidate_index_and_more.py | 32 + ..._positions_for_candidate_voter_and_more.py | 29 + ...d_positions_for_election_index_and_more.py | 40 + ...sitionentered_politician_follow_created.py | 18 + ...ed_follow_organization_created_and_more.py | 33 + ..._candidate_campaign_we_vote_id_and_more.py | 34 + ...politician_we_vote_id_analyzed_and_more.py | 23 + ...ed_positions_for_org_candidate_and_more.py | 24 + ...d_candidate_voter_date_entered_and_more.py | 24 + quick_info/migrations/0001_initial.py | 57 ++ ..._alter_quickinfo_more_info_url_and_more.py | 23 + reaction/migrations/0001_initial.py | 26 + representative/migrations/0001_initial.py | 79 ++ .../migrations/0002_auto_20230126_1420.py | 325 ++++++++ .../migrations/0003_auto_20230201_1248.py | 23 + ...presentativesmissingfrompollinglocation.py | 25 + .../migrations/0005_auto_20230208_1449.py | 78 ++ .../migrations/0006_auto_20230222_1441.py | 28 + .../migrations/0007_auto_20230306_1649.py | 43 + .../0008_representative_seo_friendly_path.py | 18 + ...ive_seo_friendly_path_date_last_updated.py | 18 + ...epresentative_office_held_district_name.py | 18 + ...1_delete_representativetoofficeheldlink.py | 16 + .../migrations/0012_auto_20230504_0648.py | 23 + .../0013_representative_supporters_count.py | 18 + .../migrations/0014_auto_20230629_0744.py | 23 + ..._alter_representative_seo_friendly_path.py | 18 + ...entative_profile_image_background_color.py | 18 + ...ive_profile_image_type_currently_active.py | 18 + .../0018_representative_is_claimed_profile.py | 18 + retrieve_tables/migrations/0001_initial.py | 27 + ...ievetablestate_voter_device_id_and_more.py | 22 + share/migrations/0001_initial.py | 114 +++ share/migrations/0002_auto_20220810_0843.py | 33 + share/migrations/0003_auto_20221024_2026.py | 58 ++ share/migrations/0004_auto_20221026_1801.py | 23 + share/migrations/0005_auto_20221119_1136.py | 68 ++ ...aryalltime_voterwhosharessummaryoneyear.py | 42 + ...hosharessummaryoneyear_voter_we_vote_id.py | 18 + share/migrations/0008_auto_20221122_1256.py | 23 + share/migrations/0009_auto_20221128_1626.py | 23 + ...hareditem_destination_full_url_and_more.py | 28 + ..._shareditem_is_challenge_share_and_more.py | 23 + sms/migrations/0001_initial.py | 56 ++ ...ption_recipient_sms_we_vote_id_and_more.py | 53 ++ stripe_donations/migrations/0001_initial.py | 101 +++ .../migrations/0002_stripedispute.py | 41 + stripe_ip_history/migrations/0001_initial.py | 31 + tag/migrations/0001_initial.py | 23 + twitter/migrations/0001_initial.py | 118 +++ twitter/migrations/0002_auto_20230208_1449.py | 53 ++ ...ntermonthlysummary_twitterapicounterwee.py | 51 ++ twitter/migrations/0004_auto_20240308_1407.py | 48 ++ twitter/migrations/0005_auto_20240311_1800.py | 23 + .../0006_twitterapicounter_success.py | 18 + ..._tweet_organization_we_vote_id_and_more.py | 43 + volunteer_task/migrations/0001_initial.py | 36 + .../migrations/0002_auto_20240313_2051.py | 33 + ...rweeklymetrics_politicians_deduplicated.py | 18 + .../0004_volunteerteam_volunteerteammember.py | 31 + .../migrations/0005_auto_20240407_1401.py | 53 ++ .../migrations/0006_auto_20240407_2129.py | 33 + ...rteam_which_day_is_end_of_week_and_more.py | 23 + ...weeklymetrics_voter_we_vote_id_and_more.py | 27 + ...trics_voter_date_unique_string_and_more.py | 22 + ...klymetrics_date_last_updated_as_integer.py | 18 + ...etrics_organizations_augmented_and_more.py | 23 + voter/migrations/0001_initial.py | 236 ++++++ voter/migrations/0002_auto_20220429_1110.py | 13 + voter/migrations/0003_auto_20220429_1358.py | 45 ++ voter/migrations/0004_auto_20220429_1403.py | 53 ++ voter/migrations/0005_auto_20220522_1747.py | 28 + voter/migrations/0006_voter_friend_count.py | 18 + .../0007_votercontactemail_is_friend.py | 18 + voter/migrations/0008_auto_20220915_0921.py | 23 + .../0009_votermergelog_votermergestatus.py | 92 +++ voter/migrations/0010_auto_20230707_1616.py | 38 + voter/migrations/0011_auto_20230709_0853.py | 73 ++ voter/migrations/0012_auto_20230709_1344.py | 33 + voter/migrations/0013_auto_20230729_1248.py | 28 + .../0014_voter_is_signed_in_cached.py | 18 + ...ter_profile_image_type_currently_active.py | 18 + .../migrations/0016_voter_is_voter_manager.py | 18 + voter/migrations/0017_auto_20240303_1539.py | 23 + voter/migrations/0018_auto_20240309_1804.py | 33 + ...er_voter_linked_organization_we_vote_id.py | 18 + ...r_twitter_voters_access_secret_and_more.py | 27 + ...voter_primary_email_we_vote_id_and_more.py | 23 + ...voter_fetch_voter_by_org_index_and_more.py | 21 + .../0023_voter_fetch_voter_by_org2_index.py | 17 + ...er_voter_linked_organization_we_vote_id.py | 18 + ...25_alter_voteraddress_voter_id_and_more.py | 26 + ...0026_voteraddress_voter_id_address_date.py | 17 + ...tatus_move_challenges_complete_and_more.py | 23 + ...date_voter_app_review_platform_and_more.py | 33 + voter_guide/migrations/0001_initial.py | 108 +++ .../migrations/0002_voterguidesgenerated.py | 22 + .../migrations/0003_auto_20230608_1306.py | 23 + .../0004_alter_voterguide_twitter_handle.py | 18 + ...sibilityposition_ballot_item_state_code.py | 18 + ...rguidepossibilityposition_more_info_url.py | 18 + ...bility_done_needs_verification_and_more.py | 33 + ...008_voterguide_election_owner_followers.py | 17 + wevote_settings/migrations/0001_initial.py | 38 + .../0002_alter_remoterequesthistory_status.py | 18 + .../0003_wevotesetting_admin_app.py | 18 + .../migrations/0004_auto_20230211_0733.py | 28 + ...ter_remoterequesthistory_kind_of_action.py | 18 + ...ter_remoterequesthistory_kind_of_action.py | 18 + ...ter_remoterequesthistory_kind_of_action.py | 18 + wevote_tokens/migrations/0001_initial.py | 33 + ...eusetoken__user_singleusetoken__user_id.py | 23 + ...ter_singleusetoken__created_at_and_more.py | 34 + .../migrations/0004_singleusetoken__scope.py | 18 + .../0005_remove_singleusetoken__user_id.py | 17 + .../0006_singleusetoken__user_id.py | 18 + 410 files changed, 16258 insertions(+) create mode 100644 activity/migrations/0001_initial.py create mode 100644 analytics/migrations/0001_initial.py create mode 100644 analytics/migrations/0002_auto_20221123_1733.py create mode 100644 analytics/migrations/0003_alter_analyticsaction_ballot_item_we_vote_id_and_more.py create mode 100644 analytics/migrations/0004_analyticsaction_politician_we_vote_id.py create mode 100644 analytics/migrations/0005_analyticsaction_election_action_constant_and_more.py create mode 100644 analytics/migrations/0006_analyticsaction_voter_date_and_more.py create mode 100644 api_internal_cache/migrations/0001_initial.py create mode 100644 apple/migrations/0001_initial.py create mode 100644 apple/migrations/0002_alter_appleuser_voter_we_vote_id.py create mode 100644 ballot/migrations/0001_initial.py create mode 100644 ballot/migrations/0002_alter_ballotitem_measure_url.py create mode 100644 ballot/migrations/0003_alter_ballotreturned_polling_location_we_vote_id_and_more.py create mode 100644 ballot/migrations/0004_ballotitem_ballot_ball_google__7fb0d0_idx.py create mode 100644 ballot/migrations/0005_rename_ballot_ball_google__7fb0d0_idx_election_poll_office_index_and_more.py create mode 100644 ballot/migrations/0006_alter_ballotreturned_we_vote_id_and_more.py create mode 100644 ballot/migrations/0007_remove_ballotitem_election_poll_office_index_and_more.py create mode 100644 ballot/migrations/0008_ballotitem_election_state_index.py create mode 100644 bookmark/migrations/0001_initial.py create mode 100644 bookmark/migrations/0002_alter_bookmarkitem_candidate_we_vote_id_and_more.py create mode 100644 campaign/migrations/0001_initial.py create mode 100644 campaign/migrations/0002_campaignxpolitician_candidate_we_vote_id.py create mode 100644 campaign/migrations/0003_auto_20230410_1203.py create mode 100644 campaign/migrations/0004_auto_20230516_0835.py create mode 100644 campaign/migrations/0005_auto_20230521_1027.py create mode 100644 campaign/migrations/0006_alter_campaignxsupporter_voter_we_vote_id.py create mode 100644 campaign/migrations/0007_campaignx_ocd_id_state_mismatch_found.py create mode 100644 campaign/migrations/0008_campaignx_ocd_id_state_mismatch_resolved.py create mode 100644 campaign/migrations/0009_campaignx_ocd_id_state_mismatch_checked_politician.py create mode 100644 campaign/migrations/0010_campaignxentriesarenotduplicates.py create mode 100644 campaign/migrations/0011_campaignx_ocd_id_state_mismatch_checked_campaign_title.py create mode 100644 campaign/migrations/0012_alter_campaignx_linked_politician_we_vote_id.py create mode 100644 campaign/migrations/0013_campaignx_profile_image_background_color.py create mode 100644 campaign/migrations/0014_campaignx_linked_politician_we_vote_id_verified.py create mode 100644 campaign/migrations/0015_campaignxentriesarepossibleduplicates_and_more.py create mode 100644 campaign/migrations/0016_campaignx_opposers_count.py create mode 100644 campaign/migrations/0017_alter_campaignxentriesarenotduplicates_campaignx1_we_vote_id_and_more.py create mode 100644 campaign/migrations/0018_campaignx_supporters_count_to_update_with_bulk_script.py create mode 100644 campaign/migrations/0019_campaignx_organization_we_vote_id.py create mode 100644 campaign/migrations/0020_alter_campaignx_seo_friendly_path.py create mode 100644 campaign/migrations/0021_alter_campaignx_linked_politician_we_vote_id.py create mode 100644 campaign/migrations/0022_campaignx_passkey_for_creating_campaign_owner.py create mode 100644 candidate/migrations/0001_initial.py create mode 100644 candidate/migrations/0002_auto_20220522_1747.py create mode 100644 candidate/migrations/0003_candidatecampaign_is_battleground_race.py create mode 100644 candidate/migrations/0004_alter_candidatecampaign_ballotpedia_office_id.py create mode 100644 candidate/migrations/0005_auto_20230126_1420.py create mode 100644 candidate/migrations/0006_candidatecampaign_twitter_handle_updates_failing.py create mode 100644 candidate/migrations/0007_auto_20230210_1159.py create mode 100644 candidate/migrations/0008_candidatecampaign_office_held_we_vote_id.py create mode 100644 candidate/migrations/0009_candidatecampaign_seo_friendly_path.py create mode 100644 candidate/migrations/0010_candidatecampaign_seo_friendly_path_date_last_updated.py create mode 100644 candidate/migrations/0011_auto_20230504_0648.py create mode 100644 candidate/migrations/0012_candidatecampaign_supporters_count.py create mode 100644 candidate/migrations/0013_auto_20230524_1618.py create mode 100644 candidate/migrations/0014_candidatecampaign_district_name.py create mode 100644 candidate/migrations/0015_auto_20230629_0744.py create mode 100644 candidate/migrations/0016_alter_candidatecampaign_ballot_guide_official_statement.py create mode 100644 candidate/migrations/0017_candidatecampaign_representative_we_vote_id.py create mode 100644 candidate/migrations/0018_auto_20231216_1125.py create mode 100644 candidate/migrations/0019_candidatecampaign_profile_image_background_color.py create mode 100644 candidate/migrations/0020_candidatecampaign_candidate_analysis_done.py create mode 100644 candidate/migrations/0021_auto_20240210_1816.py create mode 100644 candidate/migrations/0022_auto_20240214_2151.py create mode 100644 candidate/migrations/0023_candidatecampaign_race_office_level.py create mode 100644 candidate/migrations/0024_auto_20240407_1401.py create mode 100644 candidate/migrations/0025_auto_20240409_0659.py create mode 100644 candidate/migrations/0026_candidatecampaign_profile_image_background_color_needed.py create mode 100644 candidate/migrations/0027_candidatecampaign_ballotpedia_photo_url_is_broken.py create mode 100644 candidate/migrations/0028_candidatecampaign_ballotpedia_photo_url_is_placeholder.py create mode 100644 candidate/migrations/0029_candidatecampaign_facebook_photo_url_and_more.py create mode 100644 candidate/migrations/0030_candidatecampaign_facebook_photo_url_is_broken.py create mode 100644 candidate/migrations/0031_candidatecampaign_wikipedia_photo_does_not_exist.py create mode 100644 candidate/migrations/0032_alter_candidatecampaign_candidate_contact_form_url_and_more.py create mode 100644 candidate/migrations/0033_candidatecampaign_ballotpedia_candidate_links_retrieved.py create mode 100644 candidate/migrations/0034_candidatesarepossibleduplicates.py create mode 100644 candidate/migrations/0035_alter_candidatecampaign_politician_id_and_more.py create mode 100644 candidate/migrations/0036_alter_candidatecampaign_ctcl_uuid.py create mode 100644 candidate/migrations/0037_candidatecampaign_candidate_c_seo_fri_694764_idx.py create mode 100644 candidate/migrations/0038_remove_candidatecampaign_candidate_c_seo_fri_694764_idx_and_more.py create mode 100644 candidate/migrations/0039_candidatecampaign_list_politician_and_name_and_more.py create mode 100644 candidate/migrations/0040_remove_candidatecampaign_candidate_list_for_politician_and_more.py create mode 100644 candidate/migrations/0041_alter_candidatecampaign_candidate_year_and_more.py create mode 100644 candidate/migrations/0042_candidatectclalternatemap_and_more.py create mode 100644 candidate/migrations/0043_candidatecampaign_bluesky_handle_and_more.py create mode 100644 candidate/migrations/0044_candidatecampaign_is_claimed_profile.py create mode 100644 candidate/migrations/0045_candidatecampaign_candidate_ultimate_election_date_calculated_and_more.py create mode 100644 candidate/migrations/0046_candidatecampaign_threads_handle_and_more.py create mode 100644 candidate/migrations/0047_deduplicationneededforstatetoday_and_more.py create mode 100644 candidate/migrations/0048_candidatecampaign_opposers_count.py create mode 100644 challenge/migrations/0001_initial.py create mode 100644 challenge/migrations/0002_challengeparticipant_delete_challengesupporter_and_more.py create mode 100644 challenge/migrations/0003_remove_challengeparticipant_is_subscribed_by_email_and_more.py create mode 100644 challenge/migrations/0004_challengeinvitee_and_more.py create mode 100644 challenge/migrations/0005_rename_custom_message_from_inviter_challengeinvitee_invite_text_from_inviter_and_more.py create mode 100644 challenge/migrations/0006_rename_date_accepted_invite_challengeinvitee_date_challenge_joined_and_more.py create mode 100644 challenge/migrations/0007_rename_friends_invited_challengeparticipant_invitees_count_and_more.py create mode 100644 challenge/migrations/0008_challengeparticipant_invites_sent_count.py create mode 100644 challenge/migrations/0009_challengeinvitee_invitee_voter_name_and_more.py create mode 100644 challenge/migrations/0010_remove_challenge_opposers_count.py create mode 100644 election/migrations/0001_initial.py create mode 100644 election/migrations/0002_election_vote_usa_same_day_election_suffix_list.py create mode 100644 election/migrations/0003_auto_20220727_1420.py create mode 100644 election/migrations/0004_auto_20230616_0717.py create mode 100644 electoral_district/migrations/0001_initial.py create mode 100644 email_outbound/migrations/0001_initial.py create mode 100644 email_outbound/migrations/0002_alter_emailoutbounddescription_kind_of_email_template.py create mode 100644 email_outbound/migrations/0003_auto_20220720_1721.py create mode 100644 email_outbound/migrations/0004_alter_emailoutbounddescription_kind_of_email_template.py create mode 100644 email_outbound/migrations/0005_alter_emailaddress_voter_we_vote_id_and_more.py create mode 100644 email_outbound/migrations/0006_emailcampaign_emailcampaignlabel_and_more.py create mode 100644 email_outbound/migrations/0007_alter_emailtemplate_email_template_folder_id.py create mode 100644 email_outbound/migrations/0008_emailrecipienttemplate_emailrecipienttemplatefolder_and_more.py create mode 100644 email_outbound/migrations/0009_emailcampaign_scheduled_send_time_and_more.py create mode 100644 email_outbound/migrations/0010_emailcampaign_from_email_and_more.py create mode 100644 email_outbound/migrations/0011_remove_emailcampaignrecipient_recipient_name_and_more.py create mode 100644 email_outbound/migrations/0012_emailaudiencebuilder_emailaudiencebuilderfolder_and_more.py create mode 100644 email_outbound/migrations/0013_emailcampaignrecipient_open_tracking_code_and_more.py create mode 100644 email_outbound/migrations/0014_audiencebuilder_audiencefilter_audiencefilterchain_and_more.py create mode 100644 email_outbound/migrations/0015_alter_audiencefilterchain_filter1_to_filter2_operator_and_more.py create mode 100644 email_outbound/migrations/0016_remove_audiencefilter_boolean_contact_contains_and_more.py create mode 100644 email_outbound/migrations/0017_emailcampaign_audience_builder_id.py create mode 100644 follow/migrations/0001_initial.py create mode 100644 follow/migrations/0002_alter_followissue_following_status_and_more.py create mode 100644 follow/migrations/0003_alter_followcampaignx_campaignx_id_and_more.py create mode 100644 follow/migrations/0004_alter_followorganization_organization_we_vote_id_and_more.py create mode 100644 follow/migrations/0005_rename_voter_linked_organization_we_vote_id_followorganization_organization_we_vote_id_that_is_follo.py create mode 100644 friend/migrations/0001_initial.py create mode 100644 friend/migrations/0002_auto_20220619_0823.py create mode 100644 friend/migrations/0003_auto_20220623_1210.py create mode 100644 friend/migrations/0004_auto_20220707_0808.py create mode 100644 friend/migrations/0005_alter_friendinvitationtwitterlink_recipient_twitter_handle.py create mode 100644 friend/migrations/0006_alter_friendinvitationemaillink_recipient_email_we_vote_id_and_more.py create mode 100644 friend/migrations/0007_currentfriend_curr_viewer_viewee_and_more.py create mode 100644 google_custom_search/migrations/0001_initial.py create mode 100644 google_custom_search/migrations/0002_auto_20240211_0925.py create mode 100644 googlebot_site_map/migrations/0001_initial.py create mode 100644 image/migrations/0001_initial.py create mode 100644 image/migrations/0002_wevoteimage_representative_we_vote_id.py create mode 100644 image/migrations/0003_wevoteimage_politician_we_vote_id.py create mode 100644 image/migrations/0004_auto_20230606_1749.py create mode 100644 image/migrations/0005_auto_20230806_1012.py create mode 100644 image/migrations/0006_alter_wevoteimage_is_active_version_and_more.py create mode 100644 image/migrations/0007_alter_wevoteimage_is_active_version_and_more.py create mode 100644 import_export_ballotpedia/migrations/0001_initial.py create mode 100644 import_export_batches/migrations/0001_initial.py create mode 100644 import_export_batches/migrations/0002_auto_20220727_1420.py create mode 100644 import_export_batches/migrations/0003_alter_batchprocess_kind_of_process.py create mode 100644 import_export_batches/migrations/0004_auto_20230104_0640.py create mode 100644 import_export_batches/migrations/0005_auto_20230106_1130.py create mode 100644 import_export_batches/migrations/0006_auto_20230110_0710.py create mode 100644 import_export_batches/migrations/0007_auto_20230201_1248.py create mode 100644 import_export_batches/migrations/0008_auto_20230203_0925.py create mode 100644 import_export_batches/migrations/0009_auto_20230203_1547.py create mode 100644 import_export_batches/migrations/0010_alter_batchrowactionpolitician_gender.py create mode 100644 import_export_batches/migrations/0011_auto_20240129_0555.py create mode 100644 import_export_batches/migrations/0012_batchrowactionorganization_organization_ballotpedia.py create mode 100644 import_export_batches/migrations/0013_batchrowactionorganization_organization_wikipedia.py create mode 100644 import_export_batches/migrations/0014_alter_batchrowactionposition_more_info_url.py create mode 100644 import_export_batches/migrations/0015_alter_batchdescription_source_uri_and_more.py create mode 100644 import_export_batches/migrations/0016_alter_batchprocess_kind_of_process.py create mode 100644 import_export_batches/migrations/0017_alter_batchprocess_kind_of_process.py create mode 100644 import_export_batches/migrations/0018_alter_batchprocess_kind_of_process.py create mode 100644 import_export_batches/migrations/0019_alter_batchprocess_kind_of_process.py create mode 100644 import_export_bigquery/migrations/0001_initial.py create mode 100644 import_export_ctcl/migrations/0001_initial.py create mode 100644 import_export_facebook/migrations/0001_initial.py create mode 100644 import_export_google_civic/migrations/0001_initial.py create mode 100644 import_export_maplight/migrations/0001_initial.py create mode 100644 import_export_open_people/migrations/0001_initial.py create mode 100644 import_export_openreplay/migrations/0001_initial.py create mode 100644 import_export_openreplay/migrations/0002_openreplayevent_base_referrer_and_more.py create mode 100644 import_export_snovio/migrations/0001_initial.py create mode 100644 import_export_targetsmart/migrations/0001_initial.py create mode 100644 import_export_twitter/migrations/0001_initial.py create mode 100644 import_export_twitter/migrations/0002_auto_20240303_1539.py create mode 100644 import_export_twitter/migrations/0003_remove_twitterauthresponse_twitter_voters_access_secret_and_more.py create mode 100644 import_export_vote_smart/migrations/0001_initial.py create mode 100644 import_export_vote_usa/migrations/0001_initial.py create mode 100644 issue/migrations/0001_initial.py create mode 100644 issue/migrations/0002_issue_forced_sort_order.py create mode 100644 issue/migrations/0003_alter_organizationlinktoissue_link_active.py create mode 100644 issue/migrations/0004_alter_issue_we_vote_id.py create mode 100644 issue/migrations/0005_issue_hide_issue_we_vote_id_and_more.py create mode 100644 issue/migrations/0006_remove_organizationlinktoissue_issue_org_link_active_and_more.py create mode 100644 measure/migrations/0001_initial.py create mode 100644 measure/migrations/0002_alter_measurecampaign_url.py create mode 100644 measure/migrations/0003_alter_contestmeasuresarenotduplicates_contest_measure1_we_vote_id_and_more.py create mode 100644 measure/migrations/0004_alter_contestmeasure_ballotpedia_measure_name_and_more.py create mode 100644 office/migrations/0001_initial.py create mode 100644 office/migrations/0002_contestoffice_is_battleground_race_cached_in_candidates.py create mode 100644 office/migrations/0003_auto_20230110_0710.py create mode 100644 office/migrations/0004_contestoffice_office_held_we_vote_id.py create mode 100644 office/migrations/0005_remove_contestoffice_is_battleground_race_cached_in_candidates.py create mode 100644 office/migrations/0006_contestoffice_is_battleground_race_spread_to_all_objects.py create mode 100644 office/migrations/0007_auto_20230419_1557.py create mode 100644 office/migrations/0008_auto_20230531_0902.py create mode 100644 office/migrations/0009_contestoffice_election_date_as_integer.py create mode 100644 office/migrations/0010_alter_contestofficesarenotduplicates_contest_office1_we_vote_id_and_more.py create mode 100644 office/migrations/0011_alter_contestoffice_we_vote_id_and_more.py create mode 100644 office/migrations/0012_contestoffice_office_explanation_we_vote_id_and_more.py create mode 100644 office_held/migrations/0001_initial.py create mode 100644 office_held/migrations/0002_auto_20230126_1420.py create mode 100644 office_held/migrations/0003_auto_20230201_1248.py create mode 100644 office_held/migrations/0004_auto_20230222_1441.py create mode 100644 office_held/migrations/0005_auto_20230306_1649.py create mode 100644 office_held/migrations/0006_officeheld_office_held_url.py create mode 100644 office_held/migrations/0007_auto_20230311_0908.py create mode 100644 office_held/migrations/0008_auto_20230423_0727.py create mode 100644 office_held/migrations/0009_auto_20230531_0902.py create mode 100644 office_held/migrations/0010_auto_20230629_0744.py create mode 100644 office_held/migrations/0011_auto_20230827_1805.py create mode 100644 office_held/migrations/0012_officeheld_office_explanation_we_vote_id.py create mode 100644 organization/migrations/0001_initial.py create mode 100644 organization/migrations/0002_auto_20221007_1756.py create mode 100644 organization/migrations/0003_auto_20230210_1159.py create mode 100644 organization/migrations/0004_organizationchangelog.py create mode 100644 organization/migrations/0005_auto_20230804_1408.py create mode 100644 organization/migrations/0006_auto_20240129_0555.py create mode 100644 organization/migrations/0007_alter_organization_profile_image_type_currently_active.py create mode 100644 organization/migrations/0008_organization_facebook_photo_url_and_more.py create mode 100644 organization/migrations/0009_alter_organization_organization_contact_form_url_and_more.py create mode 100644 organization/migrations/0010_alter_organization_organization_facebook.py create mode 100644 organization/migrations/0011_alter_organization_organization_instagram_handle_and_more.py create mode 100644 organization/migrations/0012_alter_organization_twitter_followers_count.py create mode 100644 organization/migrations/0013_alter_organizationchangelog_changed_by_voter_we_vote_id_and_more.py create mode 100644 organization/migrations/0014_organization_organization_politicians_match_and_more.py create mode 100644 organization/migrations/0015_rename_organization_politicians_match_organization_politicians_sort_and_more.py create mode 100644 organization/migrations/0016_organizationteammember_can_edit_challenge_owned_by_organization_and_more.py create mode 100644 organization/migrations/0017_organizationsarenotduplicates_and_more.py create mode 100644 organization/migrations/0018_organization_bluesky_handle_organization_tiktok_url.py create mode 100644 organization/migrations/0019_organization_augmentation_done_and_more.py create mode 100644 organization/migrations/0020_organization_help_needed.py create mode 100644 party/migrations/0001_initial.py create mode 100644 party/migrations/0002_alter_party_we_vote_id.py create mode 100644 pledge_to_vote/migrations/0001_initial.py create mode 100644 politician/migrations/0001_initial.py create mode 100644 politician/migrations/0002_auto_20230104_0640.py create mode 100644 politician/migrations/0003_auto_20230106_1130.py create mode 100644 politician/migrations/0004_auto_20230126_1420.py create mode 100644 politician/migrations/0005_auto_20230128_1026.py create mode 100644 politician/migrations/0006_auto_20230201_1248.py create mode 100644 politician/migrations/0007_auto_20230203_1547.py create mode 100644 politician/migrations/0008_auto_20230208_1449.py create mode 100644 politician/migrations/0009_politiciansarepossibleduplicates.py create mode 100644 politician/migrations/0010_auto_20230306_1649.py create mode 100644 politician/migrations/0011_auto_20230320_1111.py create mode 100644 politician/migrations/0012_politician_seo_friendly_path_date_last_updated.py create mode 100644 politician/migrations/0013_politician_linked_campaignx_we_vote_id.py create mode 100644 politician/migrations/0014_politician_linked_campaignx_we_vote_id_date_last_updated.py create mode 100644 politician/migrations/0015_politician_supporters_count.py create mode 100644 politician/migrations/0016_auto_20230606_1749.py create mode 100644 politician/migrations/0017_politician_google_civic_name_alternates_generated.py create mode 100644 politician/migrations/0018_politician_photo_url_from_vote_usa.py create mode 100644 politician/migrations/0019_politician_ocd_id_state_mismatch_found.py create mode 100644 politician/migrations/0020_politician_seo_friendly_path_needs_regeneration.py create mode 100644 politician/migrations/0021_politician_ballot_guide_official_statement.py create mode 100644 politician/migrations/0022_auto_20230720_0429.py create mode 100644 politician/migrations/0023_auto_20231216_1125.py create mode 100644 politician/migrations/0024_politician_profile_image_background_color_needed.py create mode 100644 politician/migrations/0025_auto_20240210_1816.py create mode 100644 politician/migrations/0026_auto_20240407_1401.py create mode 100644 politician/migrations/0027_politician_ballotpedia_photo_url_is_broken.py create mode 100644 politician/migrations/0028_politician_ballotpedia_photo_url_is_placeholder.py create mode 100644 politician/migrations/0029_recommendedpoliticianlinkbypolitician.py create mode 100644 politician/migrations/0030_politician_wikipedia_photo_does_not_exist.py create mode 100644 politician/migrations/0031_alter_politician_politician_contact_form_url.py create mode 100644 politician/migrations/0032_politician_ballotpedia_candidate_links_retrieved.py create mode 100644 politician/migrations/0033_politician_opposers_count_and_more.py create mode 100644 politician/migrations/0034_alter_politician_we_vote_id.py create mode 100644 politician/migrations/0035_rename_organization_and_manual_intervention_needed_politician_organization_manual_intervention_neede.py create mode 100644 politician/migrations/0036_politician_follow_organization_analysis_complete_and_more.py create mode 100644 politician/migrations/0037_politician_date_ultimate_election_last_updated_from_candidate.py create mode 100644 politician/migrations/0038_politician_bluesky_handle_politician_tiktok_url_and_more.py create mode 100644 politician/migrations/0039_politician_linked_campaignx_we_vote_id_verified.py create mode 100644 politician/migrations/0040_politician_is_claimed_profile.py create mode 100644 politician/migrations/0041_politiciansupporter.py create mode 100644 politician/migrations/0042_politician_linked_campaignx_we_vote_id_verified_in_campaignx.py create mode 100644 politician/migrations/0043_politician_threads_handle_and_more.py create mode 100644 politician/migrations/0044_deduplicationneededforstatetoday_and_more.py create mode 100644 politician/migrations/0045_remove_politician_tag_link_and_more.py create mode 100644 polling_location/migrations/0001_initial.py create mode 100644 polling_location/migrations/0002_auto_20230126_1420.py create mode 100644 polling_location/migrations/0003_pollinglocationlogentry_kind_of_log_entry_and_deleted.py create mode 100644 polling_location/migrations/0004_pollinglocationlogentry_log_entry_one_location_index.py create mode 100644 polling_location/migrations/0005_pollinglocationlogentry_we_vote_id_and_kind_index_and_more.py create mode 100644 polling_location/migrations/0006_pollinglocation_state_and_not_deleted.py create mode 100644 polling_location/migrations/0007_pollinglocationlogentry_deleted_and_kind_of_log_entry.py create mode 100644 polling_location/migrations/0008_remove_pollinglocationlogentry_kind_and_we_vote_id_index_and_more.py create mode 100644 position/migrations/0001_initial.py create mode 100644 position/migrations/0002_auto_20230331_1340.py create mode 100644 position/migrations/0003_auto_20230521_1027.py create mode 100644 position/migrations/0004_auto_20240129_0555.py create mode 100644 position/migrations/0005_alter_positionentered_more_info_url_and_more.py create mode 100644 position/migrations/0006_positionentered_positions_for_candidate_index_and_more.py create mode 100644 position/migrations/0007_rename_positions_for_candidate_index_positions_for_candidate_voter_and_more.py create mode 100644 position/migrations/0008_remove_positionentered_positions_for_election_index_and_more.py create mode 100644 position/migrations/0009_positionentered_politician_follow_created.py create mode 100644 position/migrations/0010_rename_politician_follow_created_positionentered_follow_organization_created_and_more.py create mode 100644 position/migrations/0011_alter_positionentered_candidate_campaign_we_vote_id_and_more.py create mode 100644 position/migrations/0012_positionentered_politician_we_vote_id_analyzed_and_more.py create mode 100644 position/migrations/0013_remove_positionentered_positions_for_org_candidate_and_more.py create mode 100644 position/migrations/0014_positionentered_candidate_voter_date_entered_and_more.py create mode 100644 quick_info/migrations/0001_initial.py create mode 100644 quick_info/migrations/0002_alter_quickinfo_more_info_url_and_more.py create mode 100644 reaction/migrations/0001_initial.py create mode 100644 representative/migrations/0001_initial.py create mode 100644 representative/migrations/0002_auto_20230126_1420.py create mode 100644 representative/migrations/0003_auto_20230201_1248.py create mode 100644 representative/migrations/0004_representativesmissingfrompollinglocation.py create mode 100644 representative/migrations/0005_auto_20230208_1449.py create mode 100644 representative/migrations/0006_auto_20230222_1441.py create mode 100644 representative/migrations/0007_auto_20230306_1649.py create mode 100644 representative/migrations/0008_representative_seo_friendly_path.py create mode 100644 representative/migrations/0009_representative_seo_friendly_path_date_last_updated.py create mode 100644 representative/migrations/0010_representative_office_held_district_name.py create mode 100644 representative/migrations/0011_delete_representativetoofficeheldlink.py create mode 100644 representative/migrations/0012_auto_20230504_0648.py create mode 100644 representative/migrations/0013_representative_supporters_count.py create mode 100644 representative/migrations/0014_auto_20230629_0744.py create mode 100644 representative/migrations/0015_alter_representative_seo_friendly_path.py create mode 100644 representative/migrations/0016_representative_profile_image_background_color.py create mode 100644 representative/migrations/0017_alter_representative_profile_image_type_currently_active.py create mode 100644 representative/migrations/0018_representative_is_claimed_profile.py create mode 100644 retrieve_tables/migrations/0001_initial.py create mode 100644 retrieve_tables/migrations/0002_remove_retrievetablestate_voter_device_id_and_more.py create mode 100644 share/migrations/0001_initial.py create mode 100644 share/migrations/0002_auto_20220810_0843.py create mode 100644 share/migrations/0003_auto_20221024_2026.py create mode 100644 share/migrations/0004_auto_20221026_1801.py create mode 100644 share/migrations/0005_auto_20221119_1136.py create mode 100644 share/migrations/0006_voterwhosharessummaryalltime_voterwhosharessummaryoneyear.py create mode 100644 share/migrations/0007_alter_voterwhosharessummaryoneyear_voter_we_vote_id.py create mode 100644 share/migrations/0008_auto_20221122_1256.py create mode 100644 share/migrations/0009_auto_20221128_1626.py create mode 100644 share/migrations/0010_alter_shareditem_destination_full_url_and_more.py create mode 100644 share/migrations/0011_shareditem_is_challenge_share_and_more.py create mode 100644 sms/migrations/0001_initial.py create mode 100644 sms/migrations/0002_alter_smsoutbounddescription_recipient_sms_we_vote_id_and_more.py create mode 100644 stripe_donations/migrations/0001_initial.py create mode 100644 stripe_donations/migrations/0002_stripedispute.py create mode 100644 stripe_ip_history/migrations/0001_initial.py create mode 100644 tag/migrations/0001_initial.py create mode 100644 twitter/migrations/0001_initial.py create mode 100644 twitter/migrations/0002_auto_20230208_1449.py create mode 100644 twitter/migrations/0003_twitterapicounter_twitterapicounterdailysummary_twitterapicountermonthlysummary_twitterapicounterwee.py create mode 100644 twitter/migrations/0004_auto_20240308_1407.py create mode 100644 twitter/migrations/0005_auto_20240311_1800.py create mode 100644 twitter/migrations/0006_twitterapicounter_success.py create mode 100644 twitter/migrations/0007_alter_tweet_organization_we_vote_id_and_more.py create mode 100644 volunteer_task/migrations/0001_initial.py create mode 100644 volunteer_task/migrations/0002_auto_20240313_2051.py create mode 100644 volunteer_task/migrations/0003_volunteerweeklymetrics_politicians_deduplicated.py create mode 100644 volunteer_task/migrations/0004_volunteerteam_volunteerteammember.py create mode 100644 volunteer_task/migrations/0005_auto_20240407_1401.py create mode 100644 volunteer_task/migrations/0006_auto_20240407_2129.py create mode 100644 volunteer_task/migrations/0007_volunteerteam_which_day_is_end_of_week_and_more.py create mode 100644 volunteer_task/migrations/0008_alter_volunteerweeklymetrics_voter_we_vote_id_and_more.py create mode 100644 volunteer_task/migrations/0009_alter_volunteerweeklymetrics_voter_date_unique_string_and_more.py create mode 100644 volunteer_task/migrations/0010_volunteerweeklymetrics_date_last_updated_as_integer.py create mode 100644 volunteer_task/migrations/0011_volunteerweeklymetrics_organizations_augmented_and_more.py create mode 100644 voter/migrations/0001_initial.py create mode 100644 voter/migrations/0002_auto_20220429_1110.py create mode 100644 voter/migrations/0003_auto_20220429_1358.py create mode 100644 voter/migrations/0004_auto_20220429_1403.py create mode 100644 voter/migrations/0005_auto_20220522_1747.py create mode 100644 voter/migrations/0006_voter_friend_count.py create mode 100644 voter/migrations/0007_votercontactemail_is_friend.py create mode 100644 voter/migrations/0008_auto_20220915_0921.py create mode 100644 voter/migrations/0009_votermergelog_votermergestatus.py create mode 100644 voter/migrations/0010_auto_20230707_1616.py create mode 100644 voter/migrations/0011_auto_20230709_0853.py create mode 100644 voter/migrations/0012_auto_20230709_1344.py create mode 100644 voter/migrations/0013_auto_20230729_1248.py create mode 100644 voter/migrations/0014_voter_is_signed_in_cached.py create mode 100644 voter/migrations/0015_alter_voter_profile_image_type_currently_active.py create mode 100644 voter/migrations/0016_voter_is_voter_manager.py create mode 100644 voter/migrations/0017_auto_20240303_1539.py create mode 100644 voter/migrations/0018_auto_20240309_1804.py create mode 100644 voter/migrations/0019_alter_voter_linked_organization_we_vote_id.py create mode 100644 voter/migrations/0020_remove_voter_twitter_voters_access_secret_and_more.py create mode 100644 voter/migrations/0021_alter_voter_primary_email_we_vote_id_and_more.py create mode 100644 voter/migrations/0022_voter_voter_fetch_voter_by_org_index_and_more.py create mode 100644 voter/migrations/0023_voter_fetch_voter_by_org2_index.py create mode 100644 voter/migrations/0024_alter_voter_linked_organization_we_vote_id.py create mode 100644 voter/migrations/0025_alter_voteraddress_voter_id_and_more.py create mode 100644 voter/migrations/0026_voteraddress_voter_id_address_date.py create mode 100644 voter/migrations/0027_votermergestatus_move_challenges_complete_and_more.py create mode 100644 voter/migrations/0028_voter_app_review_date_voter_app_review_platform_and_more.py create mode 100644 voter_guide/migrations/0001_initial.py create mode 100644 voter_guide/migrations/0002_voterguidesgenerated.py create mode 100644 voter_guide/migrations/0003_auto_20230608_1306.py create mode 100644 voter_guide/migrations/0004_alter_voterguide_twitter_handle.py create mode 100644 voter_guide/migrations/0005_voterguidepossibilityposition_ballot_item_state_code.py create mode 100644 voter_guide/migrations/0006_alter_voterguidepossibilityposition_more_info_url.py create mode 100644 voter_guide/migrations/0007_voterguidepossibility_done_needs_verification_and_more.py create mode 100644 voter_guide/migrations/0008_voterguide_election_owner_followers.py create mode 100644 wevote_settings/migrations/0001_initial.py create mode 100644 wevote_settings/migrations/0002_alter_remoterequesthistory_status.py create mode 100644 wevote_settings/migrations/0003_wevotesetting_admin_app.py create mode 100644 wevote_settings/migrations/0004_auto_20230211_0733.py create mode 100644 wevote_settings/migrations/0005_alter_remoterequesthistory_kind_of_action.py create mode 100644 wevote_settings/migrations/0006_alter_remoterequesthistory_kind_of_action.py create mode 100644 wevote_settings/migrations/0007_alter_remoterequesthistory_kind_of_action.py create mode 100644 wevote_tokens/migrations/0001_initial.py create mode 100644 wevote_tokens/migrations/0002_remove_singleusetoken__user_singleusetoken__user_id.py create mode 100644 wevote_tokens/migrations/0003_alter_singleusetoken__created_at_and_more.py create mode 100644 wevote_tokens/migrations/0004_singleusetoken__scope.py create mode 100644 wevote_tokens/migrations/0005_remove_singleusetoken__user_id.py create mode 100644 wevote_tokens/migrations/0006_singleusetoken__user_id.py diff --git a/activity/migrations/0001_initial.py b/activity/migrations/0001_initial.py new file mode 100644 index 000000000..7f88312c9 --- /dev/null +++ b/activity/migrations/0001_initial.py @@ -0,0 +1,135 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='ActivityComment', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('parent_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('parent_comment_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('commenter_name', models.CharField(default=None, max_length=255, null=True)), + ('commenter_organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('commenter_twitter_followers_count', models.PositiveIntegerField(default=None, null=True)), + ('commenter_twitter_handle', models.CharField(default=None, max_length=255, null=True)), + ('commenter_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('commenter_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('commenter_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('date_created', models.DateTimeField(null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('deleted', models.BooleanField(default=False)), + ('statement_text', models.TextField(blank=True, null=True)), + ('visibility_is_public', models.BooleanField(default=False)), + ('we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='ActivityNotice', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('activity_notice_seed_id', models.PositiveIntegerField(default=None, null=True)), + ('activity_tidbit_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('campaignx_news_item_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('campaignx_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('date_of_notice', models.DateTimeField(null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True)), + ('activity_notice_clicked', models.BooleanField(default=False)), + ('activity_notice_seen', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ('kind_of_notice', models.CharField(default=None, max_length=50, null=True)), + ('kind_of_seed', models.CharField(default=None, max_length=50, null=True)), + ('new_positions_entered_count', models.PositiveIntegerField(default=None, null=True)), + ('number_of_comments', models.PositiveIntegerField(default=None, null=True)), + ('number_of_likes', models.PositiveIntegerField(default=None, null=True)), + ('position_name_list_serialized', models.TextField(default=None, null=True)), + ('position_we_vote_id_list_serialized', models.TextField(default=None, null=True)), + ('speaker_name', models.CharField(default=None, max_length=255, null=True)), + ('speaker_organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('speaker_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('recipient_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('is_in_app', models.BooleanField(default=False)), + ('send_to_email', models.BooleanField(default=False)), + ('scheduled_to_email', models.BooleanField(default=False)), + ('sent_to_email', models.BooleanField(default=False)), + ('send_to_sms', models.BooleanField(default=False)), + ('scheduled_to_sms', models.BooleanField(default=False)), + ('sent_to_sms', models.BooleanField(default=False)), + ('speaker_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('speaker_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('statement_subject', models.CharField(default=None, max_length=255, null=True)), + ('statement_text_preview', models.TextField(default=None, null=True)), + ], + ), + migrations.CreateModel( + name='ActivityNoticeSeed', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('activity_notices_created', models.BooleanField(default=False)), + ('activity_tidbit_we_vote_ids_for_friends_serialized', models.TextField(default=None, null=True)), + ('activity_tidbit_we_vote_ids_for_public_serialized', models.TextField(default=None, null=True)), + ('date_of_notice_earlier_than_update_window', models.BooleanField(default=False)), + ('activity_notices_scheduled', models.BooleanField(default=False)), + ('added_to_voter_daily_summary', models.BooleanField(default=False)), + ('campaignx_news_item_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('campaignx_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('date_of_notice', models.DateTimeField(null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True)), + ('date_sent_to_email', models.DateTimeField(null=True)), + ('deleted', models.BooleanField(default=False)), + ('kind_of_seed', models.CharField(default=None, max_length=50, null=True)), + ('position_names_for_friends_serialized', models.TextField(default=None, null=True)), + ('position_names_for_public_serialized', models.TextField(default=None, null=True)), + ('position_we_vote_ids_for_friends_serialized', models.TextField(default=None, null=True)), + ('position_we_vote_ids_for_public_serialized', models.TextField(default=None, null=True)), + ('recipient_name', models.CharField(default=None, max_length=255, null=True)), + ('recipient_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('speaker_voter_we_vote_ids_serialized', models.TextField(default=None, null=True)), + ('speaker_organization_we_vote_ids_serialized', models.TextField(default=None, null=True)), + ('send_to_email', models.BooleanField(default=False)), + ('scheduled_to_email', models.BooleanField(default=False)), + ('sent_to_email', models.BooleanField(default=False)), + ('send_to_sms', models.BooleanField(default=False)), + ('scheduled_to_sms', models.BooleanField(default=False)), + ('sent_to_sms', models.BooleanField(default=False)), + ('speaker_name', models.CharField(default=None, max_length=255, null=True)), + ('speaker_organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('speaker_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('speaker_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('speaker_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('speaker_twitter_handle', models.CharField(default=None, max_length=255, null=True)), + ('speaker_twitter_followers_count', models.IntegerField(default=0)), + ('statement_subject', models.CharField(default=None, max_length=255, null=True)), + ('statement_text_preview', models.TextField(default=None, null=True)), + ('super_share_item_id', models.PositiveIntegerField(default=None, null=True)), + ('we_vote_id', models.CharField(default=None, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='ActivityPost', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_created', models.DateTimeField(null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('deleted', models.BooleanField(default=False)), + ('speaker_name', models.CharField(default=None, max_length=255, null=True)), + ('speaker_organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('speaker_twitter_followers_count', models.PositiveIntegerField(default=None, null=True)), + ('speaker_twitter_handle', models.CharField(default=None, max_length=255, null=True)), + ('speaker_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('speaker_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('speaker_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('statement_text', models.TextField(blank=True, null=True)), + ('visibility_is_public', models.BooleanField(default=False)), + ('we_vote_id', models.CharField(default=None, max_length=255, null=True, unique=True)), + ], + ), + ] diff --git a/analytics/migrations/0001_initial.py b/analytics/migrations/0001_initial.py new file mode 100644 index 000000000..204a0e4b3 --- /dev/null +++ b/analytics/migrations/0001_initial.py @@ -0,0 +1,211 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='AnalyticsAction', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('action_constant', models.PositiveSmallIntegerField(db_index=True, null=True, verbose_name='constant representing action')), + ('exact_time', models.DateTimeField(auto_now_add=True, verbose_name='date and time of action')), + ('date_as_integer', models.PositiveIntegerField(db_index=True, null=True, verbose_name='YYYYMMDD of the action')), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id')), + ('voter_id', models.PositiveIntegerField(null=True, verbose_name='voter internal id')), + ('is_signed_in', models.BooleanField(default=False, verbose_name='')), + ('state_code', models.CharField(blank=True, max_length=255, null=True, verbose_name='state_code')), + ('organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('organization_id', models.PositiveIntegerField(blank=True, null=True)), + ('ballot_item_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='google civic election id')), + ('first_visit_today', models.BooleanField(default=False, verbose_name='')), + ('voter_device_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter_device_id of initiating voter')), + ('authentication_failed_twice', models.BooleanField(default=False, verbose_name='')), + ('user_agent', models.CharField(blank=True, max_length=255, null=True, verbose_name='https request user agent')), + ('is_bot', models.BooleanField(default=False, verbose_name='request came from web-bots or spider')), + ('is_mobile', models.BooleanField(default=False, verbose_name='request came from mobile device')), + ('is_desktop', models.BooleanField(default=False, verbose_name='request came from desktop device')), + ('is_tablet', models.BooleanField(default=False, verbose_name='request came from tablet device')), + ], + ), + migrations.CreateModel( + name='AnalyticsProcessed', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('analytics_date_as_integer', models.PositiveIntegerField(verbose_name='YYYYMMDD')), + ('batch_process_id', models.PositiveIntegerField(null=True)), + ('batch_process_analytics_chunk_id', models.PositiveIntegerField(null=True)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('google_civic_election_id', models.PositiveIntegerField(null=True)), + ('voter_we_vote_id', models.CharField(max_length=255, null=True)), + ('kind_of_process', models.CharField(max_length=50, null=True)), + ], + ), + migrations.CreateModel( + name='AnalyticsProcessingStatus', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('analytics_date_as_integer', models.PositiveIntegerField(unique=True, verbose_name='YYYYMMDD')), + ('finished_augment_analytics_action_with_election_id', models.BooleanField(default=False)), + ('finished_augment_analytics_action_with_first_visit', models.BooleanField(default=False)), + ('finished_calculate_organization_daily_metrics', models.BooleanField(default=False)), + ('finished_calculate_organization_election_metrics', models.BooleanField(default=False)), + ('finished_calculate_sitewide_daily_metrics', models.BooleanField(default=False)), + ('finished_calculate_sitewide_election_metrics', models.BooleanField(default=False)), + ('finished_calculate_sitewide_voter_metrics', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='OrganizationDailyMetrics', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_as_integer', models.PositiveIntegerField(db_index=True, null=True, verbose_name='YYYYMMDD of the action')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('visitors_total', models.PositiveIntegerField(null=True, verbose_name='number of visitors, all time')), + ('authenticated_visitors_total', models.PositiveIntegerField(null=True, verbose_name='')), + ('visitors_today', models.PositiveIntegerField(null=True, verbose_name='number of visitors, today')), + ('authenticated_visitors_today', models.PositiveIntegerField(null=True, verbose_name='')), + ('new_visitors_today', models.PositiveIntegerField(null=True, verbose_name='new visitors, today')), + ('voter_guide_entrants_today', models.PositiveIntegerField(null=True, verbose_name='first touch, voter guide')), + ('voter_guide_entrants', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_visiting_ballot', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_visiting_ballot', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_total', models.PositiveIntegerField(null=True, verbose_name='all time')), + ('new_followers_today', models.PositiveIntegerField(null=True, verbose_name='today')), + ('auto_followers_total', models.PositiveIntegerField(null=True, verbose_name='all')), + ('new_auto_followers_today', models.PositiveIntegerField(null=True, verbose_name='today')), + ('issues_linked_total', models.PositiveIntegerField(null=True, verbose_name='organization classifications, all time')), + ('organization_public_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ], + ), + migrations.CreateModel( + name='OrganizationElectionMetrics', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('visitors_total', models.PositiveIntegerField(null=True, verbose_name='')), + ('authenticated_visitors_total', models.PositiveIntegerField(null=True, verbose_name='')), + ('voter_guide_entrants', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_at_time_of_election', models.PositiveIntegerField(null=True, verbose_name='')), + ('new_followers', models.PositiveIntegerField(null=True, verbose_name='')), + ('new_auto_followers', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_visited_ballot', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_visited_ballot', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_took_position', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_public_positions', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_public_positions_with_comments', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_friends_only_positions', models.PositiveIntegerField(null=True, verbose_name='')), + ('entrants_friends_only_positions_with_comments', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_took_position', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_public_positions', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_public_positions_with_comments', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_friends_only_positions', models.PositiveIntegerField(null=True, verbose_name='')), + ('followers_friends_only_positions_with_comments', models.PositiveIntegerField(null=True, verbose_name='')), + ], + ), + migrations.CreateModel( + name='SitewideDailyMetrics', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_as_integer', models.PositiveIntegerField(db_index=True, null=True, verbose_name='YYYYMMDD of the action')), + ('visitors_total', models.PositiveIntegerField(null=True, verbose_name='number of visitors, all time')), + ('visitors_today', models.PositiveIntegerField(null=True, verbose_name='number of visitors, today')), + ('new_visitors_today', models.PositiveIntegerField(null=True, verbose_name='new visitors, today')), + ('voter_guide_entrants_today', models.PositiveIntegerField(null=True, verbose_name='first touch, voter guide')), + ('welcome_page_entrants_today', models.PositiveIntegerField(null=True, verbose_name='first touch, welcome page')), + ('friend_entrants_today', models.PositiveIntegerField(null=True, verbose_name='first touch, response to friend')), + ('authenticated_visitors_total', models.PositiveIntegerField(null=True, verbose_name='number of visitors, all time')), + ('authenticated_visitors_today', models.PositiveIntegerField(null=True, verbose_name='number of visitors, today')), + ('ballot_views_today', models.PositiveIntegerField(null=True, verbose_name='number of voters who viewed a ballot today')), + ('voter_guides_viewed_total', models.PositiveIntegerField(null=True, verbose_name='number of voter guides viewed, all time')), + ('voter_guides_viewed_today', models.PositiveIntegerField(null=True, verbose_name='number of voter guides viewed, today')), + ('issues_followed_total', models.PositiveIntegerField(null=True, verbose_name='number of issues followed, all time')), + ('issues_followed_today', models.PositiveIntegerField(null=True, verbose_name='issues followed today, today')), + ('issue_follows_total', models.PositiveIntegerField(null=True, verbose_name='one follow for one issue, all time')), + ('issue_follows_today', models.PositiveIntegerField(null=True, verbose_name='one follow for one issue, today')), + ('organizations_followed_total', models.PositiveIntegerField(null=True, verbose_name='voter follow organizations, all time')), + ('organizations_followed_today', models.PositiveIntegerField(null=True, verbose_name='voter follow organizations, today')), + ('organizations_auto_followed_total', models.PositiveIntegerField(null=True, verbose_name='auto_follow organizations, all')), + ('organizations_auto_followed_today', models.PositiveIntegerField(null=True, verbose_name='auto_follow organizations, today')), + ('organizations_with_linked_issues', models.PositiveIntegerField(null=True, verbose_name='organizations linked to issues, all')), + ('issues_linked_total', models.PositiveIntegerField(null=True, verbose_name='')), + ('issues_linked_today', models.PositiveIntegerField(null=True, verbose_name='')), + ('organizations_signed_in_total', models.PositiveIntegerField(null=True, verbose_name='organizations signed in, all')), + ('organizations_with_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('organizations_with_new_positions_today', models.PositiveIntegerField(null=True, verbose_name='today')), + ('organization_public_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('individuals_with_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('individuals_with_public_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('individuals_with_friends_only_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('friends_only_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('entered_full_address', models.PositiveIntegerField(null=True, verbose_name='all')), + ], + ), + migrations.CreateModel( + name='SitewideElectionMetrics', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('visitors_total', models.PositiveIntegerField(null=True, verbose_name='')), + ('authenticated_visitors_total', models.PositiveIntegerField(null=True, verbose_name='')), + ('voter_guide_entries', models.PositiveIntegerField(null=True, verbose_name='')), + ('voter_guide_views', models.PositiveIntegerField(null=True, verbose_name='one person viewed one voter guide, this election')), + ('voter_guides_viewed', models.PositiveIntegerField(null=True, verbose_name='one org, seen at least once, this election')), + ('issues_followed', models.PositiveIntegerField(null=True, verbose_name='follow issue connections, all time')), + ('unique_voters_that_followed_organizations', models.PositiveIntegerField(null=True, verbose_name='')), + ('unique_voters_that_auto_followed_organizations', models.PositiveIntegerField(null=True, verbose_name='')), + ('organizations_followed', models.PositiveIntegerField(null=True, verbose_name='voter follow organizations, today')), + ('organizations_auto_followed', models.PositiveIntegerField(null=True, verbose_name='auto_follow organizations, today')), + ('organizations_signed_in', models.PositiveIntegerField(null=True, verbose_name='organizations signed in, all')), + ('organizations_with_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('organization_public_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('individuals_with_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('individuals_with_public_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('individuals_with_friends_only_positions', models.PositiveIntegerField(null=True, verbose_name='all')), + ('public_positions', models.PositiveIntegerField(null=True, verbose_name='')), + ('public_positions_with_comments', models.PositiveIntegerField(null=True, verbose_name='')), + ('friends_only_positions', models.PositiveIntegerField(null=True, verbose_name='')), + ('friends_only_positions_with_comments', models.PositiveIntegerField(null=True, verbose_name='')), + ('entered_full_address', models.PositiveIntegerField(null=True, verbose_name='')), + ], + ), + migrations.CreateModel( + name='SitewideVoterMetrics', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id')), + ('actions_count', models.PositiveIntegerField(db_index=True, null=True, verbose_name='all')), + ('elections_viewed', models.PositiveIntegerField(null=True, verbose_name='all')), + ('voter_guides_viewed', models.PositiveIntegerField(null=True, verbose_name='all')), + ('ballot_visited', models.PositiveIntegerField(null=True, verbose_name='all')), + ('welcome_visited', models.PositiveIntegerField(db_index=True, null=True, verbose_name='all')), + ('entered_full_address', models.PositiveIntegerField(null=True, verbose_name='all')), + ('issues_followed', models.PositiveIntegerField(null=True, verbose_name='all')), + ('organizations_followed', models.PositiveIntegerField(null=True, verbose_name='all')), + ('time_until_sign_in', models.PositiveIntegerField(null=True, verbose_name='all')), + ('positions_entered_friends_only', models.PositiveIntegerField(null=True, verbose_name='all')), + ('positions_entered_public', models.PositiveIntegerField(null=True, verbose_name='all')), + ('comments_entered_friends_only', models.PositiveIntegerField(null=True, verbose_name='all')), + ('comments_entered_public', models.PositiveIntegerField(null=True, verbose_name='all')), + ('signed_in_twitter', models.BooleanField(default=False, verbose_name='')), + ('signed_in_facebook', models.BooleanField(default=False, verbose_name='')), + ('signed_in_with_email', models.BooleanField(default=False, verbose_name='')), + ('signed_in_with_sms_phone_number', models.BooleanField(default=False, verbose_name='')), + ('seconds_on_site', models.PositiveIntegerField(null=True, verbose_name='all')), + ('days_visited', models.PositiveIntegerField(null=True, verbose_name='all')), + ('last_action_date', models.DateTimeField(db_index=True, null=True, verbose_name='last action date and time')), + ('last_calculated_date_as_integer', models.PositiveIntegerField(db_index=True, null=True, verbose_name='YYYYMMDD of the last time stats calculated')), + ], + ), + ] diff --git a/analytics/migrations/0002_auto_20221123_1733.py b/analytics/migrations/0002_auto_20221123_1733.py new file mode 100644 index 000000000..b152bb0b1 --- /dev/null +++ b/analytics/migrations/0002_auto_20221123_1733.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.16 on 2022-11-24 01:33 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('analytics', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='sitewidedailymetrics', + name='shared_items_clicked_today', + field=models.PositiveIntegerField(null=True, verbose_name=''), + ), + migrations.AddField( + model_name='sitewidedailymetrics', + name='shared_link_clicked_count_today', + field=models.PositiveIntegerField(null=True, verbose_name=''), + ), + migrations.AddField( + model_name='sitewidedailymetrics', + name='shared_link_clicked_unique_viewers_today', + field=models.PositiveIntegerField(null=True, verbose_name=''), + ), + ] diff --git a/analytics/migrations/0003_alter_analyticsaction_ballot_item_we_vote_id_and_more.py b/analytics/migrations/0003_alter_analyticsaction_ballot_item_we_vote_id_and_more.py new file mode 100644 index 000000000..423f5b2c6 --- /dev/null +++ b/analytics/migrations/0003_alter_analyticsaction_ballot_item_we_vote_id_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-13 13:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('analytics', '0002_auto_20221123_1733'), + ] + + operations = [ + migrations.AlterField( + model_name='analyticsaction', + name='ballot_item_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='analyticsaction', + name='state_code', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='state_code'), + ), + ] diff --git a/analytics/migrations/0004_analyticsaction_politician_we_vote_id.py b/analytics/migrations/0004_analyticsaction_politician_we_vote_id.py new file mode 100644 index 000000000..cc2e69cb8 --- /dev/null +++ b/analytics/migrations/0004_analyticsaction_politician_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.7 on 2024-08-01 16:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('analytics', '0003_alter_analyticsaction_ballot_item_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='analyticsaction', + name='politician_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + ] diff --git a/analytics/migrations/0005_analyticsaction_election_action_constant_and_more.py b/analytics/migrations/0005_analyticsaction_election_action_constant_and_more.py new file mode 100644 index 000000000..72ffef769 --- /dev/null +++ b/analytics/migrations/0005_analyticsaction_election_action_constant_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.8 on 2024-09-01 18:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('analytics', '0004_analyticsaction_politician_we_vote_id'), + ] + + operations = [ + migrations.AddIndex( + model_name='analyticsaction', + index=models.Index(fields=['google_civic_election_id', 'action_constant'], name='election_action_constant'), + ), + migrations.AddIndex( + model_name='analyticsaction', + index=models.Index(fields=['voter_we_vote_id', 'action_constant'], name='voter_action_constant'), + ), + ] diff --git a/analytics/migrations/0006_analyticsaction_voter_date_and_more.py b/analytics/migrations/0006_analyticsaction_voter_date_and_more.py new file mode 100644 index 000000000..3a2f92b1f --- /dev/null +++ b/analytics/migrations/0006_analyticsaction_voter_date_and_more.py @@ -0,0 +1,29 @@ +# Generated by Django 5.0.8 on 2024-09-01 19:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('analytics', '0005_analyticsaction_election_action_constant_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='analyticsaction', + index=models.Index(fields=['voter_we_vote_id', 'date_as_integer'], name='voter_date'), + ), + migrations.AddIndex( + model_name='analyticsaction', + index=models.Index(fields=['voter_we_vote_id'], name='voter_index'), + ), + migrations.AddIndex( + model_name='analyticsaction', + index=models.Index(fields=['date_as_integer'], name='date_as_integer_index'), + ), + migrations.AddIndex( + model_name='analyticsaction', + index=models.Index(fields=['date_as_integer', 'is_signed_in'], name='date_as_integer_signed_in'), + ), + ] diff --git a/api_internal_cache/migrations/0001_initial.py b/api_internal_cache/migrations/0001_initial.py new file mode 100644 index 000000000..3953c6330 --- /dev/null +++ b/api_internal_cache/migrations/0001_initial.py @@ -0,0 +1,39 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='ApiInternalCache', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('api_name', models.CharField(blank=True, default='', max_length=255)), + ('election_id_list_serialized', models.TextField(default='')), + ('cached_api_response_serialized', models.TextField(default='')), + ('date_cached', models.DateTimeField(auto_now_add=True, null=True)), + ('replaced', models.BooleanField(default=False)), + ('date_replaced', models.DateTimeField(null=True)), + ], + ), + migrations.CreateModel( + name='ApiRefreshRequest', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('api_name', models.CharField(blank=True, max_length=255, null=True)), + ('election_id_list_serialized', models.TextField(blank=True, null=True)), + ('date_scheduled', models.DateTimeField(auto_now_add=True, null=True)), + ('date_refresh_is_needed', models.DateTimeField(null=True)), + ('date_checked_out', models.DateTimeField(null=True)), + ('date_refresh_completed', models.DateTimeField(null=True)), + ('refresh_completed', models.BooleanField(default=False)), + ], + ), + ] diff --git a/apple/migrations/0001_initial.py b/apple/migrations/0001_initial.py new file mode 100644 index 000000000..0b3400687 --- /dev/null +++ b/apple/migrations/0001_initial.py @@ -0,0 +1,31 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='AppleUser', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(max_length=255, unique=True, verbose_name='we vote id for the Apple ID owner')), + ('user_code', models.CharField(max_length=255, verbose_name="User's apple id code")), + ('email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='apple email address')), + ('first_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's first_name from Apple")), + ('middle_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's middle_name from Apple")), + ('last_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's last_name from Apple")), + ('apple_platform', models.CharField(blank=True, max_length=32, null=True, verbose_name='Platform of Apple Device')), + ('apple_os_version', models.CharField(blank=True, max_length=32, null=True, verbose_name='Apple OS Version')), + ('apple_model', models.CharField(blank=True, max_length=32, null=True, verbose_name='Apple Device Model')), + ('date_created', models.DateTimeField(auto_now_add=True, verbose_name='date created')), + ('date_last_referenced', models.DateTimeField(auto_now=True, verbose_name='date last referenced')), + ], + ), + ] diff --git a/apple/migrations/0002_alter_appleuser_voter_we_vote_id.py b/apple/migrations/0002_alter_appleuser_voter_we_vote_id.py new file mode 100644 index 000000000..bb80b50a2 --- /dev/null +++ b/apple/migrations/0002_alter_appleuser_voter_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('apple', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='appleuser', + name='voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, unique=True, verbose_name='we vote id for the Apple ID owner'), + ), + ] diff --git a/ballot/migrations/0001_initial.py b/ballot/migrations/0001_initial.py new file mode 100644 index 000000000..5a4acce6c --- /dev/null +++ b/ballot/migrations/0001_initial.py @@ -0,0 +1,100 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BallotItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_id', models.IntegerField(db_index=True, default=0, verbose_name='the voter unique id')), + ('polling_location_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('google_civic_election_id', models.CharField(db_index=True, max_length=20, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('state_code', models.CharField(db_index=True, max_length=2, null=True, verbose_name='state the ballot item is related to')), + ('google_ballot_placement', models.BigIntegerField(blank=True, null=True, verbose_name='the order this item should appear on the ballot')), + ('local_ballot_order', models.IntegerField(blank=True, null=True, verbose_name='locally calculated order this item should appear on the ballot')), + ('contest_office_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='local id for this contest office')), + ('contest_office_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this office')), + ('contest_measure_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='contest_measure unique id')), + ('contest_measure_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this measure')), + ('ballot_item_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='a label we can sort by')), + ('measure_subtitle', models.TextField(blank=True, default='', null=True, verbose_name='google civic referendum subtitle')), + ('measure_text', models.TextField(blank=True, default='', null=True, verbose_name='measure text')), + ('measure_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of measure')), + ('yes_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a yes vote means')), + ('no_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a no vote means')), + ], + ), + migrations.CreateModel( + name='BallotReturned', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('voter_id', models.IntegerField(blank=True, null=True, verbose_name='the voter unique id')), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=0, verbose_name='google civic election id')), + ('election_description_text', models.CharField(max_length=255, verbose_name='text label for this election')), + ('election_date', models.DateField(null=True, verbose_name='election start date')), + ('ballot_location_display_option_on', models.BooleanField(db_index=True, default=False)), + ('ballot_location_display_name', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='name that shows in button')), + ('ballot_location_shortcut', models.CharField(blank=True, max_length=255, null=True, verbose_name='the url string to find this location')), + ('ballot_location_order', models.PositiveIntegerField(default=0, verbose_name='order of these ballot locations in display')), + ('text_for_map_search', models.CharField(max_length=255, verbose_name='address as entered')), + ('latitude', models.FloatField(null=True, verbose_name='latitude returned from Google')), + ('longitude', models.FloatField(null=True, verbose_name='longitude returned from Google')), + ('state_code', models.CharField(db_index=True, max_length=2, null=True, verbose_name='state code returned or calculated')), + ('normalized_line1', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized address line 1 returned from Google')), + ('normalized_line2', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized address line 2 returned from Google')), + ('normalized_city', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized city returned from Google')), + ('normalized_state', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized state returned from Google')), + ('normalized_zip', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized zip returned from Google')), + ('date_last_updated', models.DateTimeField(auto_now=True, db_index=True, verbose_name='date ballot items last retrieved')), + ], + ), + migrations.CreateModel( + name='BallotReturnedEmpty', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=0, verbose_name='google civic election id')), + ('is_from_ctcl', models.BooleanField(default=False)), + ('is_from_vote_usa', models.BooleanField(default=False)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True, verbose_name='state code returned or calculated')), + ('date_last_updated', models.DateTimeField(auto_now=True, db_index=True, verbose_name='date ballot items last retrieved')), + ], + ), + migrations.CreateModel( + name='VoterBallotSaved', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_id', models.IntegerField(default=0, verbose_name='the voter unique id')), + ('google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='state the ballot item is related to')), + ('election_description_text', models.CharField(max_length=255, verbose_name='text label for this election')), + ('election_date', models.DateField(null=True, verbose_name='election start date')), + ('original_text_for_map_search', models.CharField(max_length=255, verbose_name='address as entered')), + ('original_text_city', models.CharField(max_length=255, null=True)), + ('original_text_state', models.CharField(max_length=255, null=True)), + ('original_text_zip', models.CharField(max_length=255, null=True)), + ('substituted_address_city', models.CharField(max_length=255, null=True)), + ('substituted_address_state', models.CharField(max_length=255, null=True)), + ('substituted_address_zip', models.CharField(max_length=255, null=True)), + ('substituted_address_nearby', models.CharField(max_length=255, verbose_name='address from nearby ballot_returned')), + ('is_from_substituted_address', models.BooleanField(default=False)), + ('is_from_test_ballot', models.BooleanField(default=False)), + ('polling_location_we_vote_id_source', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point this was copied from')), + ('ballot_returned_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='ballot_returned we_vote_id this was copied from')), + ('ballot_location_display_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='the name of the ballot the voter is looking at')), + ('ballot_location_shortcut', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='the url string used to find specific ballot')), + ], + ), + ] diff --git a/ballot/migrations/0002_alter_ballotitem_measure_url.py b/ballot/migrations/0002_alter_ballotitem_measure_url.py new file mode 100644 index 000000000..d51a4f80f --- /dev/null +++ b/ballot/migrations/0002_alter_ballotitem_measure_url.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='ballotitem', + name='measure_url', + field=models.TextField(null=True, verbose_name='url of measure'), + ), + ] diff --git a/ballot/migrations/0003_alter_ballotreturned_polling_location_we_vote_id_and_more.py b/ballot/migrations/0003_alter_ballotreturned_polling_location_we_vote_id_and_more.py new file mode 100644 index 000000000..169b60f65 --- /dev/null +++ b/ballot/migrations/0003_alter_ballotreturned_polling_location_we_vote_id_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0002_alter_ballotitem_measure_url'), + ] + + operations = [ + migrations.AlterField( + model_name='ballotreturned', + name='polling_location_we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point'), + ), + migrations.AlterField( + model_name='ballotreturned', + name='we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='ballotreturnedempty', + name='polling_location_we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point'), + ), + migrations.AlterField( + model_name='voterballotsaved', + name='ballot_returned_we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='ballot_returned we_vote_id this was copied from'), + ), + ] diff --git a/ballot/migrations/0004_ballotitem_ballot_ball_google__7fb0d0_idx.py b/ballot/migrations/0004_ballotitem_ballot_ball_google__7fb0d0_idx.py new file mode 100644 index 000000000..8561fdc6b --- /dev/null +++ b/ballot/migrations/0004_ballotitem_ballot_ball_google__7fb0d0_idx.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-13 13:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0003_alter_ballotreturned_polling_location_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['google_civic_election_id', 'polling_location_we_vote_id', 'contest_office_we_vote_id'], name='ballot_ball_google__7fb0d0_idx'), + ), + ] diff --git a/ballot/migrations/0005_rename_ballot_ball_google__7fb0d0_idx_election_poll_office_index_and_more.py b/ballot/migrations/0005_rename_ballot_ball_google__7fb0d0_idx_election_poll_office_index_and_more.py new file mode 100644 index 000000000..33135f13b --- /dev/null +++ b/ballot/migrations/0005_rename_ballot_ball_google__7fb0d0_idx_election_poll_office_index_and_more.py @@ -0,0 +1,35 @@ +# Generated by Django 5.0.3 on 2024-07-13 19:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0004_ballotitem_ballot_ball_google__7fb0d0_idx'), + ] + + operations = [ + migrations.RenameIndex( + model_name='ballotitem', + new_name='election_poll_office_index', + old_name='ballot_ball_google__7fb0d0_idx', + ), + migrations.AlterField( + model_name='ballotreturned', + name='ballot_location_shortcut', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='the url string to find this location'), + ), + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['polling_location_we_vote_id', 'contest_office_we_vote_id', 'google_civic_election_id'], name='poll_office_election_index'), + ), + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['google_civic_election_id', 'polling_location_we_vote_id', 'contest_measure_we_vote_id'], name='election_poll_measure_index'), + ), + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['polling_location_we_vote_id', 'contest_measure_we_vote_id', 'google_civic_election_id'], name='poll_measure_election_index'), + ), + ] diff --git a/ballot/migrations/0006_alter_ballotreturned_we_vote_id_and_more.py b/ballot/migrations/0006_alter_ballotreturned_we_vote_id_and_more.py new file mode 100644 index 000000000..631ac5205 --- /dev/null +++ b/ballot/migrations/0006_alter_ballotreturned_we_vote_id_and_more.py @@ -0,0 +1,38 @@ +# Generated by Django 5.0.3 on 2024-07-18 19:09 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0005_rename_ballot_ball_google__7fb0d0_idx_election_poll_office_index_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='ballotreturned', + name='we_vote_id', + field=models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id'), + ), + migrations.AddIndex( + model_name='ballotreturned', + index=models.Index(fields=['polling_location_we_vote_id', 'text_for_map_search'], name='polling_location_and_text'), + ), + migrations.AddIndex( + model_name='ballotreturned', + index=models.Index(fields=['polling_location_we_vote_id', 'text_for_map_search', 'id'], name='polling_location_and_text_id'), + ), + migrations.AddIndex( + model_name='ballotreturned', + index=models.Index(fields=['text_for_map_search', 'polling_location_we_vote_id'], name='text_and_polling_location'), + ), + migrations.AddIndex( + model_name='ballotreturned', + index=models.Index(fields=['text_for_map_search', 'polling_location_we_vote_id', 'id'], name='text_and_polling_location_id'), + ), + migrations.AddIndex( + model_name='ballotreturned', + index=models.Index(fields=['we_vote_id'], name='ballot_returned_we_vote_id'), + ), + ] diff --git a/ballot/migrations/0007_remove_ballotitem_election_poll_office_index_and_more.py b/ballot/migrations/0007_remove_ballotitem_election_poll_office_index_and_more.py new file mode 100644 index 000000000..70c85018f --- /dev/null +++ b/ballot/migrations/0007_remove_ballotitem_election_poll_office_index_and_more.py @@ -0,0 +1,37 @@ +# Generated by Django 5.0.8 on 2024-09-01 13:34 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0006_alter_ballotreturned_we_vote_id_and_more'), + ] + + operations = [ + migrations.RemoveIndex( + model_name='ballotitem', + name='election_poll_office_index', + ), + migrations.RemoveIndex( + model_name='ballotitem', + name='poll_office_election_index', + ), + migrations.RemoveIndex( + model_name='ballotitem', + name='election_poll_measure_index', + ), + migrations.RemoveIndex( + model_name='ballotitem', + name='poll_measure_election_index', + ), + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['contest_office_we_vote_id', 'polling_location_we_vote_id', 'google_civic_election_id'], name='office_poll_election_index'), + ), + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['contest_measure_we_vote_id', 'polling_location_we_vote_id', 'google_civic_election_id'], name='measure_poll_election_index'), + ), + ] diff --git a/ballot/migrations/0008_ballotitem_election_state_index.py b/ballot/migrations/0008_ballotitem_election_state_index.py new file mode 100644 index 000000000..38219363a --- /dev/null +++ b/ballot/migrations/0008_ballotitem_election_state_index.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.8 on 2024-09-02 15:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ballot', '0007_remove_ballotitem_election_poll_office_index_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='ballotitem', + index=models.Index(fields=['google_civic_election_id', 'state_code'], name='election_state_index'), + ), + ] diff --git a/bookmark/migrations/0001_initial.py b/bookmark/migrations/0001_initial.py new file mode 100644 index 000000000..f20cb9cbb --- /dev/null +++ b/bookmark/migrations/0001_initial.py @@ -0,0 +1,35 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BookmarkItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_id', models.BigIntegerField(blank=True, null=True)), + ('candidate_id', models.BigIntegerField(blank=True, null=True)), + ('candidate_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('contest_office_id', models.BigIntegerField(blank=True, null=True)), + ('contest_office_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('contest_measure_id', models.BigIntegerField(blank=True, null=True)), + ('contest_measure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('bookmark_status', models.CharField(choices=[('BOOKMARKED', 'Item Bookmarked'), ('NOT_BOOKMARKED', 'Item Not Bookmarked')], default='NOT_BOOKMARKED', max_length=16)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='BookmarkItemList', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ], + ), + ] diff --git a/bookmark/migrations/0002_alter_bookmarkitem_candidate_we_vote_id_and_more.py b/bookmark/migrations/0002_alter_bookmarkitem_candidate_we_vote_id_and_more.py new file mode 100644 index 000000000..bff64f7b0 --- /dev/null +++ b/bookmark/migrations/0002_alter_bookmarkitem_candidate_we_vote_id_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('bookmark', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='bookmarkitem', + name='candidate_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='bookmarkitem', + name='contest_measure_id', + field=models.BigIntegerField(blank=True, db_index=True, null=True), + ), + migrations.AlterField( + model_name='bookmarkitem', + name='contest_measure_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='bookmarkitem', + name='contest_office_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + ] diff --git a/campaign/migrations/0001_initial.py b/campaign/migrations/0001_initial.py new file mode 100644 index 000000000..953daf0f7 --- /dev/null +++ b/campaign/migrations/0001_initial.py @@ -0,0 +1,137 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='CampaignX', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('campaign_description', models.TextField(blank=True, null=True)), + ('campaign_title', models.CharField(max_length=255, verbose_name='title of campaign')), + ('final_election_date_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('in_draft_mode', models.BooleanField(db_index=True, default=True)), + ('is_ok_to_promote_on_we_vote', models.BooleanField(db_index=True, default=True)), + ('is_blocked_by_we_vote', models.BooleanField(db_index=True, default=False)), + ('is_blocked_by_we_vote_reason', models.TextField(blank=True, null=True)), + ('is_in_team_review_mode', models.BooleanField(db_index=True, default=False)), + ('is_not_promoted_by_we_vote', models.BooleanField(db_index=True, default=False)), + ('is_not_promoted_by_we_vote_reason', models.TextField(blank=True, null=True)), + ('is_still_active', models.BooleanField(db_index=True, default=True)), + ('is_victorious', models.BooleanField(db_index=True, default=False)), + ('politician_starter_list_serialized', models.TextField(blank=True, null=True)), + ('seo_friendly_path', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ('started_by_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('supporters_count', models.PositiveIntegerField(default=0)), + ('supporters_count_minimum_ignored', models.BooleanField(db_index=True, default=False)), + ('supporters_count_victory_goal', models.PositiveIntegerField(default=0)), + ('we_vote_hosted_campaign_photo_original_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_campaign_photo_large_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_campaign_photo_medium_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_campaign_photo_small_url', models.TextField(blank=True, null=True)), + ('date_campaign_started', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='CampaignXListedByOrganization', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('site_owner_organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('listing_requested_by_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('visible_to_public', models.BooleanField(default=False)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='CampaignXNewsItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('speaker_name', models.CharField(max_length=255, null=True)), + ('campaign_news_subject', models.TextField(null=True)), + ('campaign_news_text', models.TextField(null=True)), + ('in_draft_mode', models.BooleanField(db_index=True, default=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ('visibility_blocked_by_we_vote', models.BooleanField(default=False)), + ('visible_to_public', models.BooleanField(default=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('date_posted', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('date_sent_to_email', models.DateTimeField(db_index=True, null=True)), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='CampaignXOwner', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ('feature_this_profile_image', models.BooleanField(default=True)), + ('order_in_list', models.PositiveIntegerField(null=True)), + ('organization_name', models.CharField(max_length=255)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('visible_to_public', models.BooleanField(default=False)), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='CampaignXPolitician', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('next_election_date_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('politician_name', models.CharField(max_length=255)), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='politician home state')), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='CampaignXSEOFriendlyPath', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_we_vote_id', models.CharField(max_length=255, null=True)), + ('campaign_title', models.CharField(max_length=255)), + ('base_pathname_string', models.CharField(max_length=255, null=True)), + ('pathname_modifier', models.CharField(max_length=10, null=True)), + ('final_pathname_string', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='CampaignXSupporter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaign_supported', models.BooleanField(db_index=True, default=True)), + ('campaignx_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('is_subscribed_by_email', models.BooleanField(default=True)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('supporter_name', models.CharField(max_length=255, null=True)), + ('supporter_endorsement', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ('visibility_blocked_by_we_vote', models.BooleanField(default=False)), + ('visible_to_public', models.BooleanField(default=False)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('date_supported', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ], + ), + ] diff --git a/campaign/migrations/0002_campaignxpolitician_candidate_we_vote_id.py b/campaign/migrations/0002_campaignxpolitician_candidate_we_vote_id.py new file mode 100644 index 000000000..416c38846 --- /dev/null +++ b/campaign/migrations/0002_campaignxpolitician_candidate_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2022-12-31 03:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='campaignxpolitician', + name='candidate_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/campaign/migrations/0003_auto_20230410_1203.py b/campaign/migrations/0003_auto_20230410_1203.py new file mode 100644 index 000000000..579f03de7 --- /dev/null +++ b/campaign/migrations/0003_auto_20230410_1203.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-04-10 19:03 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0002_campaignxpolitician_candidate_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='campaign_description_linked_to_twitter', + field=models.BooleanField(db_index=True, default=False), + ), + migrations.AddField( + model_name='campaignx', + name='linked_politician_we_vote_id', + field=models.CharField(max_length=255, null=True, unique=True), + ), + ] diff --git a/campaign/migrations/0004_auto_20230516_0835.py b/campaign/migrations/0004_auto_20230516_0835.py new file mode 100644 index 000000000..3377de820 --- /dev/null +++ b/campaign/migrations/0004_auto_20230516_0835.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.18 on 2023-05-16 15:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0003_auto_20230410_1203'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='date_last_updated_from_politician', + field=models.DateTimeField(default=None, null=True), + ), + migrations.AddField( + model_name='campaignx', + name='we_vote_hosted_profile_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='campaignx', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='campaignx', + name='we_vote_hosted_profile_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/campaign/migrations/0005_auto_20230521_1027.py b/campaign/migrations/0005_auto_20230521_1027.py new file mode 100644 index 000000000..ab46e4c53 --- /dev/null +++ b/campaign/migrations/0005_auto_20230521_1027.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-05-21 17:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0004_auto_20230516_0835'), + ] + + operations = [ + migrations.AddField( + model_name='campaignxsupporter', + name='linked_position_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='campaignxsupporter', + name='is_subscribed_by_email', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/campaign/migrations/0006_alter_campaignxsupporter_voter_we_vote_id.py b/campaign/migrations/0006_alter_campaignxsupporter_voter_we_vote_id.py new file mode 100644 index 000000000..113350851 --- /dev/null +++ b/campaign/migrations/0006_alter_campaignxsupporter_voter_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-05-21 17:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0005_auto_20230521_1027'), + ] + + operations = [ + migrations.AlterField( + model_name='campaignxsupporter', + name='voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/campaign/migrations/0007_campaignx_ocd_id_state_mismatch_found.py b/campaign/migrations/0007_campaignx_ocd_id_state_mismatch_found.py new file mode 100644 index 000000000..d35fa3ce7 --- /dev/null +++ b/campaign/migrations/0007_campaignx_ocd_id_state_mismatch_found.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-11-13 17:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0006_alter_campaignxsupporter_voter_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='ocd_id_state_mismatch_found', + field=models.BooleanField(default=False), + ), + ] diff --git a/campaign/migrations/0008_campaignx_ocd_id_state_mismatch_resolved.py b/campaign/migrations/0008_campaignx_ocd_id_state_mismatch_resolved.py new file mode 100644 index 000000000..15c294004 --- /dev/null +++ b/campaign/migrations/0008_campaignx_ocd_id_state_mismatch_resolved.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-11-17 21:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0007_campaignx_ocd_id_state_mismatch_found'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='ocd_id_state_mismatch_resolved', + field=models.BooleanField(default=False), + ), + ] diff --git a/campaign/migrations/0009_campaignx_ocd_id_state_mismatch_checked_politician.py b/campaign/migrations/0009_campaignx_ocd_id_state_mismatch_checked_politician.py new file mode 100644 index 000000000..acf2b1fee --- /dev/null +++ b/campaign/migrations/0009_campaignx_ocd_id_state_mismatch_checked_politician.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-11-18 01:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0008_campaignx_ocd_id_state_mismatch_resolved'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='ocd_id_state_mismatch_checked_politician', + field=models.BooleanField(default=False), + ), + ] diff --git a/campaign/migrations/0010_campaignxentriesarenotduplicates.py b/campaign/migrations/0010_campaignxentriesarenotduplicates.py new file mode 100644 index 000000000..4ed79895c --- /dev/null +++ b/campaign/migrations/0010_campaignxentriesarenotduplicates.py @@ -0,0 +1,21 @@ +# Generated by Django 3.2.23 on 2023-11-20 00:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0009_campaignx_ocd_id_state_mismatch_checked_politician'), + ] + + operations = [ + migrations.CreateModel( + name='CampaignXEntriesAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx1_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='first campaignx we are tracking')), + ('campaignx2_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='second campaignx we are tracking')), + ], + ), + ] diff --git a/campaign/migrations/0011_campaignx_ocd_id_state_mismatch_checked_campaign_title.py b/campaign/migrations/0011_campaignx_ocd_id_state_mismatch_checked_campaign_title.py new file mode 100644 index 000000000..6ac79a7e8 --- /dev/null +++ b/campaign/migrations/0011_campaignx_ocd_id_state_mismatch_checked_campaign_title.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-11-22 22:11 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0010_campaignxentriesarenotduplicates'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='ocd_id_state_mismatch_checked_campaign_title', + field=models.BooleanField(default=False), + ), + ] diff --git a/campaign/migrations/0012_alter_campaignx_linked_politician_we_vote_id.py b/campaign/migrations/0012_alter_campaignx_linked_politician_we_vote_id.py new file mode 100644 index 000000000..8415d1772 --- /dev/null +++ b/campaign/migrations/0012_alter_campaignx_linked_politician_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-12-16 19:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0011_campaignx_ocd_id_state_mismatch_checked_campaign_title'), + ] + + operations = [ + migrations.AlterField( + model_name='campaignx', + name='linked_politician_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, unique=True), + ), + ] diff --git a/campaign/migrations/0013_campaignx_profile_image_background_color.py b/campaign/migrations/0013_campaignx_profile_image_background_color.py new file mode 100644 index 000000000..782da9463 --- /dev/null +++ b/campaign/migrations/0013_campaignx_profile_image_background_color.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-12-21 15:21 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0012_alter_campaignx_linked_politician_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='profile_image_background_color', + field=models.CharField(blank=True, max_length=7, null=True), + ), + ] diff --git a/campaign/migrations/0014_campaignx_linked_politician_we_vote_id_verified.py b/campaign/migrations/0014_campaignx_linked_politician_we_vote_id_verified.py new file mode 100644 index 000000000..9d3ff3aaf --- /dev/null +++ b/campaign/migrations/0014_campaignx_linked_politician_we_vote_id_verified.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-04 23:43 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0013_campaignx_profile_image_background_color'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='linked_politician_we_vote_id_verified', + field=models.BooleanField(default=False), + ), + ] diff --git a/campaign/migrations/0015_campaignxentriesarepossibleduplicates_and_more.py b/campaign/migrations/0015_campaignxentriesarepossibleduplicates_and_more.py new file mode 100644 index 000000000..84fb698a4 --- /dev/null +++ b/campaign/migrations/0015_campaignxentriesarepossibleduplicates_and_more.py @@ -0,0 +1,27 @@ +# Generated by Django 5.0.3 on 2024-05-08 14:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0014_campaignx_linked_politician_we_vote_id_verified'), + ] + + operations = [ + migrations.CreateModel( + name='CampaignXEntriesArePossibleDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx1_we_vote_id', models.CharField(max_length=255, null=True)), + ('campaignx2_we_vote_id', models.CharField(max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True)), + ], + ), + migrations.AddField( + model_name='campaignx', + name='state_code', + field=models.CharField(max_length=2, null=True), + ), + ] diff --git a/campaign/migrations/0016_campaignx_opposers_count.py b/campaign/migrations/0016_campaignx_opposers_count.py new file mode 100644 index 000000000..f3ffa0c3d --- /dev/null +++ b/campaign/migrations/0016_campaignx_opposers_count.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-30 01:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0015_campaignxentriesarepossibleduplicates_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='opposers_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/campaign/migrations/0017_alter_campaignxentriesarenotduplicates_campaignx1_we_vote_id_and_more.py b/campaign/migrations/0017_alter_campaignxentriesarenotduplicates_campaignx1_we_vote_id_and_more.py new file mode 100644 index 000000000..286a451fc --- /dev/null +++ b/campaign/migrations/0017_alter_campaignxentriesarenotduplicates_campaignx1_we_vote_id_and_more.py @@ -0,0 +1,43 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0016_campaignx_opposers_count'), + ] + + operations = [ + migrations.AlterField( + model_name='campaignxentriesarenotduplicates', + name='campaignx1_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='first campaignx we are tracking'), + ), + migrations.AlterField( + model_name='campaignxentriesarenotduplicates', + name='campaignx2_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='second campaignx we are tracking'), + ), + migrations.AlterField( + model_name='campaignxentriesarepossibleduplicates', + name='campaignx1_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='campaignxentriesarepossibleduplicates', + name='campaignx2_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='campaignxlistedbyorganization', + name='campaignx_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='campaignxlistedbyorganization', + name='site_owner_organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + ] diff --git a/campaign/migrations/0018_campaignx_supporters_count_to_update_with_bulk_script.py b/campaign/migrations/0018_campaignx_supporters_count_to_update_with_bulk_script.py new file mode 100644 index 000000000..0723bdfff --- /dev/null +++ b/campaign/migrations/0018_campaignx_supporters_count_to_update_with_bulk_script.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-16 01:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0017_alter_campaignxentriesarenotduplicates_campaignx1_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='supporters_count_to_update_with_bulk_script', + field=models.BooleanField(default=True), + ), + ] diff --git a/campaign/migrations/0019_campaignx_organization_we_vote_id.py b/campaign/migrations/0019_campaignx_organization_we_vote_id.py new file mode 100644 index 000000000..ef827f039 --- /dev/null +++ b/campaign/migrations/0019_campaignx_organization_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-24 22:50 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0018_campaignx_supporters_count_to_update_with_bulk_script'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/campaign/migrations/0020_alter_campaignx_seo_friendly_path.py b/campaign/migrations/0020_alter_campaignx_seo_friendly_path.py new file mode 100644 index 000000000..34d08aea0 --- /dev/null +++ b/campaign/migrations/0020_alter_campaignx_seo_friendly_path.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-27 00:32 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0019_campaignx_organization_we_vote_id'), + ] + + operations = [ + migrations.AlterField( + model_name='campaignx', + name='seo_friendly_path', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/campaign/migrations/0021_alter_campaignx_linked_politician_we_vote_id.py b/campaign/migrations/0021_alter_campaignx_linked_politician_we_vote_id.py new file mode 100644 index 000000000..497d999d0 --- /dev/null +++ b/campaign/migrations/0021_alter_campaignx_linked_politician_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-27 15:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0020_alter_campaignx_seo_friendly_path'), + ] + + operations = [ + migrations.AlterField( + model_name='campaignx', + name='linked_politician_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/campaign/migrations/0022_campaignx_passkey_for_creating_campaign_owner.py b/campaign/migrations/0022_campaignx_passkey_for_creating_campaign_owner.py new file mode 100644 index 000000000..b8e046bf6 --- /dev/null +++ b/campaign/migrations/0022_campaignx_passkey_for_creating_campaign_owner.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-09-19 15:51 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('campaign', '0021_alter_campaignx_linked_politician_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='campaignx', + name='passkey_for_creating_campaign_owner', + field=models.CharField(db_index=True, max_length=25, null=True), + ), + ] diff --git a/candidate/migrations/0001_initial.py b/candidate/migrations/0001_initial.py new file mode 100644 index 000000000..280aba801 --- /dev/null +++ b/candidate/migrations/0001_initial.py @@ -0,0 +1,155 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='CandidateCampaign', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this candidate')), + ('maplight_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='maplight candidate id')), + ('vote_smart_id', models.CharField(blank=True, default=None, max_length=15, null=True, verbose_name='vote smart candidate id')), + ('contest_office_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='contest_office_id id')), + ('contest_office_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for the office this candidate is running for')), + ('contest_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the office')), + ('politician_id', models.BigIntegerField(blank=True, null=True, verbose_name='politician unique identifier')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote politician id')), + ('candidate_name', models.CharField(max_length=255, verbose_name='candidate name')), + ('google_civic_candidate_name', models.CharField(max_length=255, null=True, verbose_name='candidate name exactly as received from google civic')), + ('google_civic_candidate_name2', models.CharField(max_length=255, null=True, verbose_name='candidate name exactly as received from google civic')), + ('google_civic_candidate_name3', models.CharField(max_length=255, null=True, verbose_name='candidate name exactly as received from google civic')), + ('candidate_gender', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate gender')), + ('birth_day_text', models.CharField(blank=True, max_length=10, null=True, verbose_name='birth day')), + ('party', models.CharField(blank=True, max_length=255, null=True, verbose_name='party')), + ('photo_url', models.TextField(blank=True, null=True, verbose_name='photoUrl')), + ('photo_url_from_ctcl', models.TextField(blank=True, null=True)), + ('photo_url_from_maplight', models.TextField(blank=True, null=True, verbose_name='candidate portrait url of candidate from maplight')), + ('photo_url_from_vote_smart', models.TextField(blank=True, null=True, verbose_name='candidate portrait url of candidate from vote smart')), + ('photo_url_from_vote_usa', models.TextField(blank=True, null=True)), + ('order_on_ballot', models.CharField(blank=True, max_length=255, null=True, verbose_name='order on ballot')), + ('google_civic_election_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('instagram_handle', models.TextField(blank=True, null=True, verbose_name="candidate's instagram handle")), + ('instagram_followers_count', models.IntegerField(blank=True, null=True, verbose_name="count of candidate's instagram followers")), + ('candidate_ultimate_election_date', models.PositiveIntegerField(default=None, null=True)), + ('candidate_year', models.PositiveIntegerField(default=None, null=True)), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='state this candidate serves')), + ('date_last_updated', models.DateTimeField(auto_now=True, null=True)), + ('candidate_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of candidate')), + ('candidate_contact_form_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of candidate contact form')), + ('facebook_url', models.TextField(blank=True, null=True, verbose_name='facebook url of candidate')), + ('facebook_url_is_broken', models.BooleanField(default=False, verbose_name='facebook url is broken')), + ('facebook_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of profile image from facebook')), + ('twitter_url', models.URLField(blank=True, null=True, verbose_name='twitter url of candidate')), + ('twitter_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter id')), + ('candidate_twitter_handle', models.CharField(max_length=255, null=True)), + ('candidate_twitter_handle2', models.CharField(max_length=255, null=True)), + ('candidate_twitter_handle3', models.CharField(max_length=255, null=True)), + ('candidate_twitter_updates_failing', models.BooleanField(default=False)), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate plain text name from twitter')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='locally cached url of candidate profile image from twitter')), + ('twitter_profile_background_image_url_https', models.TextField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_banner_url_https', models.TextField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('vote_usa_office_id', models.CharField(blank=True, default=None, max_length=64, null=True, verbose_name='Vote USA permanent id for the office')), + ('vote_usa_politician_id', models.CharField(blank=True, default=None, max_length=64, null=True, verbose_name='Vote USA permanent id for this candidate')), + ('vote_usa_profile_image_url_https', models.TextField(blank=True, default=None, null=True)), + ('profile_image_type_currently_active', models.CharField(choices=[('FACEBOOK', 'Facebook'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA')], default='UNKNOWN', max_length=10)), + ('we_vote_hosted_profile_facebook_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_facebook_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_facebook_image_url_tiny', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_twitter_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_twitter_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_twitter_image_url_tiny', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_uploaded_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_uploaded_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_uploaded_image_url_tiny', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_vote_usa_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_vote_usa_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_vote_usa_image_url_tiny', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('google_plus_url', models.URLField(blank=True, null=True, verbose_name='google plus url of candidate')), + ('youtube_url', models.URLField(blank=True, null=True, verbose_name='youtube url of candidate')), + ('candidate_email', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate email')), + ('candidate_phone', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate phone')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_photo_url', models.TextField(blank=True, null=True, verbose_name='url of wikipedia logo')), + ('linkedin_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='linkedin url of candidate')), + ('linkedin_photo_url', models.TextField(blank=True, null=True, verbose_name='url of linkedin logo')), + ('other_source_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='other source url of candidate')), + ('other_source_photo_url', models.TextField(blank=True, null=True, verbose_name='url of other source image')), + ('ballotpedia_candidate_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia integer id')), + ('ballotpedia_candidate_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate name exactly as received from ballotpedia')), + ('ballotpedia_candidate_summary', models.TextField(blank=True, default=None, null=True, verbose_name='candidate summary from ballotpedia')), + ('ballotpedia_candidate_url', models.TextField(blank=True, null=True, verbose_name='url of candidate on ballotpedia')), + ('ballotpedia_election_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia election id')), + ('ballotpedia_image_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia image id')), + ('ballotpedia_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='locally cached candidate profile image from ballotpedia')), + ('ballotpedia_office_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia elected office integer id')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_person_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia integer id')), + ('ballotpedia_photo_url', models.TextField(blank=True, null=True, verbose_name='url of ballotpedia logo')), + ('ballotpedia_race_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia race integer id')), + ('ballot_guide_official_statement', models.TextField(blank=True, default='', null=True, verbose_name='official candidate statement from ballot guide')), + ('crowdpac_candidate_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='crowdpac integer id')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('candidate_is_top_ticket', models.BooleanField(default=False, verbose_name='candidate is top ticket')), + ('candidate_is_incumbent', models.BooleanField(default=False, verbose_name='candidate is the current incumbent')), + ('candidate_participation_status', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate participation status')), + ('withdrawn_from_election', models.BooleanField(default=False, verbose_name='Candidate has withdrawn from election')), + ('withdrawal_date', models.DateField(null=True, verbose_name='Withdrawal date from election')), + ('do_not_display_on_ballot', models.BooleanField(default=False)), + ('migrated_to_link', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='CandidateLogEntry', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, null=True)), + ('candidate_we_vote_id', models.CharField(max_length=255)), + ('candidate_field_name', models.CharField(max_length=255, null=True)), + ('date_time', models.DateTimeField(auto_now_add=True)), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True)), + ('is_from_twitter', models.BooleanField(db_index=True, default=False, null=True)), + ('kind_of_log_entry', models.CharField(db_index=True, default=None, max_length=50, null=True)), + ('log_entry_deleted', models.BooleanField(db_index=True, default=False)), + ('log_entry_message', models.TextField(null=True)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ], + ), + migrations.CreateModel( + name='CandidatesAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('candidate1_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='first candidate we are tracking')), + ('candidate2_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='second candidate we are tracking')), + ], + ), + migrations.CreateModel( + name='CandidateToOfficeLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('candidate_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('contest_office_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=0)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('position_dates_set', models.BooleanField(default=False)), + ], + ), + ] diff --git a/candidate/migrations/0002_auto_20220522_1747.py b/candidate/migrations/0002_auto_20220522_1747.py new file mode 100644 index 000000000..9161af4c8 --- /dev/null +++ b/candidate/migrations/0002_auto_20220522_1747.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.13 on 2022-05-23 00:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='flickr_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='go_fund_me_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='vimeo_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/candidate/migrations/0003_candidatecampaign_is_battleground_race.py b/candidate/migrations/0003_candidatecampaign_is_battleground_race.py new file mode 100644 index 000000000..999297999 --- /dev/null +++ b/candidate/migrations/0003_candidatecampaign_is_battleground_race.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2023-01-02 01:36 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0002_auto_20220522_1747'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='is_battleground_race', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0004_alter_candidatecampaign_ballotpedia_office_id.py b/candidate/migrations/0004_alter_candidatecampaign_ballotpedia_office_id.py new file mode 100644 index 000000000..b7158b8de --- /dev/null +++ b/candidate/migrations/0004_alter_candidatecampaign_ballotpedia_office_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2023-01-10 15:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0003_candidatecampaign_is_battleground_race'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='ballotpedia_office_id', + field=models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia office held integer id'), + ), + ] diff --git a/candidate/migrations/0005_auto_20230126_1420.py b/candidate/migrations/0005_auto_20230126_1420.py new file mode 100644 index 000000000..439a5e0f5 --- /dev/null +++ b/candidate/migrations/0005_auto_20230126_1420.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.16 on 2023-01-26 22:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0004_alter_candidatecampaign_ballotpedia_office_id'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='twitter_handle2_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='candidatecampaign', + name='wikipedia_url', + field=models.TextField(null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='linkedin_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='youtube_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/candidate/migrations/0006_candidatecampaign_twitter_handle_updates_failing.py b/candidate/migrations/0006_candidatecampaign_twitter_handle_updates_failing.py new file mode 100644 index 000000000..66dc8531e --- /dev/null +++ b/candidate/migrations/0006_candidatecampaign_twitter_handle_updates_failing.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2023-01-28 18:26 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0005_auto_20230126_1420'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='twitter_handle_updates_failing', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0007_auto_20230210_1159.py b/candidate/migrations/0007_auto_20230210_1159.py new file mode 100644 index 000000000..c33c1d9d8 --- /dev/null +++ b/candidate/migrations/0007_auto_20230210_1159.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.17 on 2023-02-10 19:59 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0006_candidatecampaign_twitter_handle_updates_failing'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='facebook_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='facebook_url_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='instagram_followers_count', + field=models.IntegerField(blank=True, null=True), + ), + ] diff --git a/candidate/migrations/0008_candidatecampaign_office_held_we_vote_id.py b/candidate/migrations/0008_candidatecampaign_office_held_we_vote_id.py new file mode 100644 index 000000000..4c41d1049 --- /dev/null +++ b/candidate/migrations/0008_candidatecampaign_office_held_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.17 on 2023-02-22 22:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0007_auto_20230210_1159'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='office_held_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + ] diff --git a/candidate/migrations/0009_candidatecampaign_seo_friendly_path.py b/candidate/migrations/0009_candidatecampaign_seo_friendly_path.py new file mode 100644 index 000000000..5296d1ebb --- /dev/null +++ b/candidate/migrations/0009_candidatecampaign_seo_friendly_path.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-24 03:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0008_candidatecampaign_office_held_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='seo_friendly_path', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/candidate/migrations/0010_candidatecampaign_seo_friendly_path_date_last_updated.py b/candidate/migrations/0010_candidatecampaign_seo_friendly_path_date_last_updated.py new file mode 100644 index 000000000..18d2afcee --- /dev/null +++ b/candidate/migrations/0010_candidatecampaign_seo_friendly_path_date_last_updated.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-24 17:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0009_candidatecampaign_seo_friendly_path'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='seo_friendly_path_date_last_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/candidate/migrations/0011_auto_20230504_0648.py b/candidate/migrations/0011_auto_20230504_0648.py new file mode 100644 index 000000000..b70d09a44 --- /dev/null +++ b/candidate/migrations/0011_auto_20230504_0648.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-05-04 13:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0010_candidatecampaign_seo_friendly_path_date_last_updated'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='linked_campaignx_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='linked_campaignx_we_vote_id_date_last_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/candidate/migrations/0012_candidatecampaign_supporters_count.py b/candidate/migrations/0012_candidatecampaign_supporters_count.py new file mode 100644 index 000000000..707807780 --- /dev/null +++ b/candidate/migrations/0012_candidatecampaign_supporters_count.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-05-21 17:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0011_auto_20230504_0648'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='supporters_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/candidate/migrations/0013_auto_20230524_1618.py b/candidate/migrations/0013_auto_20230524_1618.py new file mode 100644 index 000000000..522c2aa9a --- /dev/null +++ b/candidate/migrations/0013_auto_20230524_1618.py @@ -0,0 +1,63 @@ +# Generated by Django 3.2.18 on 2023-05-24 23:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0012_candidatecampaign_supporters_count'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_name', + field=models.CharField(db_index=True, max_length=255, verbose_name='candidate name'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_twitter_handle', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_twitter_handle2', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_twitter_handle3', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_year', + field=models.PositiveIntegerField(db_index=True, default=None, null=True), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='google_civic_candidate_name', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='candidate name exactly as received from google civic'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='google_civic_candidate_name2', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='candidate name exactly as received from google civic'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='google_civic_candidate_name3', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='candidate name exactly as received from google civic'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='instagram_handle', + field=models.TextField(blank=True, db_index=True, null=True, verbose_name="candidate's instagram handle"), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='vote_usa_politician_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=64, null=True, verbose_name='Vote USA permanent id for this candidate'), + ), + ] diff --git a/candidate/migrations/0014_candidatecampaign_district_name.py b/candidate/migrations/0014_candidatecampaign_district_name.py new file mode 100644 index 000000000..b4470760c --- /dev/null +++ b/candidate/migrations/0014_candidatecampaign_district_name.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-06-07 00:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0013_auto_20230524_1618'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='district_name', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='district name'), + ), + ] diff --git a/candidate/migrations/0015_auto_20230629_0744.py b/candidate/migrations/0015_auto_20230629_0744.py new file mode 100644 index 000000000..821ac5f6e --- /dev/null +++ b/candidate/migrations/0015_auto_20230629_0744.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.19 on 2023-06-29 14:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0014_candidatecampaign_district_name'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='ocd_id_state_mismatch_checked', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='candidatecampaign', + name='ocd_id_state_mismatch_found', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0016_alter_candidatecampaign_ballot_guide_official_statement.py b/candidate/migrations/0016_alter_candidatecampaign_ballot_guide_official_statement.py new file mode 100644 index 000000000..484ed6628 --- /dev/null +++ b/candidate/migrations/0016_alter_candidatecampaign_ballot_guide_official_statement.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-07-15 22:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0015_auto_20230629_0744'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='ballot_guide_official_statement', + field=models.TextField(blank=True, default=None, null=True, verbose_name='official candidate statement from ballot guide'), + ), + ] diff --git a/candidate/migrations/0017_candidatecampaign_representative_we_vote_id.py b/candidate/migrations/0017_candidatecampaign_representative_we_vote_id.py new file mode 100644 index 000000000..f304ab8e3 --- /dev/null +++ b/candidate/migrations/0017_candidatecampaign_representative_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.20 on 2023-08-28 01:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0016_alter_candidatecampaign_ballot_guide_official_statement'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='representative_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/candidate/migrations/0018_auto_20231216_1125.py b/candidate/migrations/0018_auto_20231216_1125.py new file mode 100644 index 000000000..ef4b7b15b --- /dev/null +++ b/candidate/migrations/0018_auto_20231216_1125.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.23 on 2023-12-16 19:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0017_candidatecampaign_representative_we_vote_id'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='politician_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote politician id'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='seo_friendly_path', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/candidate/migrations/0019_candidatecampaign_profile_image_background_color.py b/candidate/migrations/0019_candidatecampaign_profile_image_background_color.py new file mode 100644 index 000000000..a5d76873b --- /dev/null +++ b/candidate/migrations/0019_candidatecampaign_profile_image_background_color.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-12-21 15:21 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0018_auto_20231216_1125'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='profile_image_background_color', + field=models.CharField(blank=True, max_length=7, null=True), + ), + ] diff --git a/candidate/migrations/0020_candidatecampaign_candidate_analysis_done.py b/candidate/migrations/0020_candidatecampaign_candidate_analysis_done.py new file mode 100644 index 000000000..1572d3c19 --- /dev/null +++ b/candidate/migrations/0020_candidatecampaign_candidate_analysis_done.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2024-02-09 15:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0019_candidatecampaign_profile_image_background_color'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='candidate_analysis_done', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0021_auto_20240210_1816.py b/candidate/migrations/0021_auto_20240210_1816.py new file mode 100644 index 000000000..9e33981db --- /dev/null +++ b/candidate/migrations/0021_auto_20240210_1816.py @@ -0,0 +1,112 @@ +# Generated by Django 3.2.23 on 2024-02-11 02:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0020_candidatecampaign_candidate_analysis_done'), + ] + + operations = [ + migrations.CreateModel( + name='CandidateChangeLog', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, null=True)), + ('candidate_we_vote_id', models.CharField(max_length=255)), + ('changed_by_name', models.CharField(default=None, max_length=255, null=True)), + ('changed_by_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('change_description', models.TextField(blank=True, null=True)), + ('log_datetime', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True)), + ('is_from_twitter', models.BooleanField(db_index=True, default=False, null=True)), + ('kind_of_log_entry', models.CharField(db_index=True, default=None, max_length=50, null=True)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ], + ), + migrations.DeleteModel( + name='CandidateLogEntry', + ), + migrations.AddField( + model_name='candidatecampaign', + name='linkedin_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached candidate profile image from linkedin'), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_ballotpedia_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_ballotpedia_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_ballotpedia_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_linkedin_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_linkedin_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_linkedin_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_wikipedia_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_wikipedia_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='we_vote_hosted_profile_wikipedia_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='wikipedia_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached candidate profile image from wikipedia'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='ballotpedia_photo_url', + field=models.TextField(blank=True, null=True, verbose_name='url of remote ballotpedia profile photo'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='ballotpedia_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached profile image from ballotpedia'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='linkedin_photo_url', + field=models.TextField(blank=True, null=True, verbose_name='url of remote linkedin profile photo'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('BALLOTPEDIA', 'Ballotpedia'), ('FACEBOOK', 'Facebook'), ('LINKEDIN', 'LinkedIn'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA'), ('WIKIPEDIA', 'Wikipedia')], default='UNKNOWN', max_length=11), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='wikipedia_photo_url', + field=models.TextField(blank=True, null=True, verbose_name='url of remote wikipedia profile photo'), + ), + ] diff --git a/candidate/migrations/0022_auto_20240214_2151.py b/candidate/migrations/0022_auto_20240214_2151.py new file mode 100644 index 000000000..de195081f --- /dev/null +++ b/candidate/migrations/0022_auto_20240214_2151.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.23 on 2024-02-15 05:51 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0021_auto_20240210_1816'), + ] + + operations = [ + migrations.AddField( + model_name='candidatechangelog', + name='is_ballotpedia_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_candidate_analysis_done', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_facebook_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_linkedin_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_twitter_handle_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_wikipedia_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AlterField( + model_name='candidatechangelog', + name='is_from_twitter', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/candidate/migrations/0023_candidatecampaign_race_office_level.py b/candidate/migrations/0023_candidatecampaign_race_office_level.py new file mode 100644 index 000000000..387fc3dd2 --- /dev/null +++ b/candidate/migrations/0023_candidatecampaign_race_office_level.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.24 on 2024-02-24 02:07 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0022_auto_20240214_2151'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='race_office_level', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='race office level'), + ), + ] diff --git a/candidate/migrations/0024_auto_20240407_1401.py b/candidate/migrations/0024_auto_20240407_1401.py new file mode 100644 index 000000000..91a0e0fe9 --- /dev/null +++ b/candidate/migrations/0024_auto_20240407_1401.py @@ -0,0 +1,88 @@ +# Generated by Django 3.2.25 on 2024-04-07 21:01 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0023_candidatecampaign_race_office_level'), + ] + + operations = [ + migrations.AddField( + model_name='candidatechangelog', + name='is_ballotpedia_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_candidate_url_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_candidate_url_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_facebook_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_linkedin_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_official_statement_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_official_statement_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_photo_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_photo_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_twitter_handle_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_website_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_website_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_wikipedia_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_withdrawal_date_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_withdrawal_date_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/candidate/migrations/0025_auto_20240409_0659.py b/candidate/migrations/0025_auto_20240409_0659.py new file mode 100644 index 000000000..f701bd637 --- /dev/null +++ b/candidate/migrations/0025_auto_20240409_0659.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.25 on 2024-04-09 13:59 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0024_auto_20240407_1401'), + ] + + operations = [ + migrations.AddField( + model_name='candidatechangelog', + name='is_link_to_office_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_link_to_office_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/candidate/migrations/0026_candidatecampaign_profile_image_background_color_needed.py b/candidate/migrations/0026_candidatecampaign_profile_image_background_color_needed.py new file mode 100644 index 000000000..46004e1c7 --- /dev/null +++ b/candidate/migrations/0026_candidatecampaign_profile_image_background_color_needed.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-04-23 19:03 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0025_auto_20240409_0659'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='profile_image_background_color_needed', + field=models.BooleanField(null=True), + ), + ] diff --git a/candidate/migrations/0027_candidatecampaign_ballotpedia_photo_url_is_broken.py b/candidate/migrations/0027_candidatecampaign_ballotpedia_photo_url_is_broken.py new file mode 100644 index 000000000..403d84b8d --- /dev/null +++ b/candidate/migrations/0027_candidatecampaign_ballotpedia_photo_url_is_broken.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-09 20:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0026_candidatecampaign_profile_image_background_color_needed'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='ballotpedia_photo_url_is_broken', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0028_candidatecampaign_ballotpedia_photo_url_is_placeholder.py b/candidate/migrations/0028_candidatecampaign_ballotpedia_photo_url_is_placeholder.py new file mode 100644 index 000000000..0946a5d61 --- /dev/null +++ b/candidate/migrations/0028_candidatecampaign_ballotpedia_photo_url_is_placeholder.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-11 15:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0027_candidatecampaign_ballotpedia_photo_url_is_broken'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='ballotpedia_photo_url_is_placeholder', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0029_candidatecampaign_facebook_photo_url_and_more.py b/candidate/migrations/0029_candidatecampaign_facebook_photo_url_and_more.py new file mode 100644 index 000000000..ff852061e --- /dev/null +++ b/candidate/migrations/0029_candidatecampaign_facebook_photo_url_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-05-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0028_candidatecampaign_ballotpedia_photo_url_is_placeholder'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='facebook_photo_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='facebook_photo_url_is_placeholder', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0030_candidatecampaign_facebook_photo_url_is_broken.py b/candidate/migrations/0030_candidatecampaign_facebook_photo_url_is_broken.py new file mode 100644 index 000000000..bac50d718 --- /dev/null +++ b/candidate/migrations/0030_candidatecampaign_facebook_photo_url_is_broken.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-16 17:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0029_candidatecampaign_facebook_photo_url_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='facebook_photo_url_is_broken', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0031_candidatecampaign_wikipedia_photo_does_not_exist.py b/candidate/migrations/0031_candidatecampaign_wikipedia_photo_does_not_exist.py new file mode 100644 index 000000000..ca7b16b63 --- /dev/null +++ b/candidate/migrations/0031_candidatecampaign_wikipedia_photo_does_not_exist.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-30 01:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0030_candidatecampaign_facebook_photo_url_is_broken'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='wikipedia_photo_does_not_exist', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0032_alter_candidatecampaign_candidate_contact_form_url_and_more.py b/candidate/migrations/0032_alter_candidatecampaign_candidate_contact_form_url_and_more.py new file mode 100644 index 000000000..445214416 --- /dev/null +++ b/candidate/migrations/0032_alter_candidatecampaign_candidate_contact_form_url_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0031_candidatecampaign_wikipedia_photo_does_not_exist'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_contact_form_url', + field=models.TextField(null=True, verbose_name='website url of candidate contact form'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_url', + field=models.TextField(null=True, verbose_name='website url of candidate'), + ), + ] diff --git a/candidate/migrations/0033_candidatecampaign_ballotpedia_candidate_links_retrieved.py b/candidate/migrations/0033_candidatecampaign_ballotpedia_candidate_links_retrieved.py new file mode 100644 index 000000000..f4c3d3ccd --- /dev/null +++ b/candidate/migrations/0033_candidatecampaign_ballotpedia_candidate_links_retrieved.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-11 05:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0032_alter_candidatecampaign_candidate_contact_form_url_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='ballotpedia_candidate_links_retrieved', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0034_candidatesarepossibleduplicates.py b/candidate/migrations/0034_candidatesarepossibleduplicates.py new file mode 100644 index 000000000..2cff23f31 --- /dev/null +++ b/candidate/migrations/0034_candidatesarepossibleduplicates.py @@ -0,0 +1,22 @@ +# Generated by Django 5.0.3 on 2024-06-17 02:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0033_candidatecampaign_ballotpedia_candidate_links_retrieved'), + ] + + operations = [ + migrations.CreateModel( + name='CandidatesArePossibleDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('candidate1_we_vote_id', models.CharField(max_length=255, null=True)), + ('candidate2_we_vote_id', models.CharField(max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True)), + ], + ), + ] diff --git a/candidate/migrations/0035_alter_candidatecampaign_politician_id_and_more.py b/candidate/migrations/0035_alter_candidatecampaign_politician_id_and_more.py new file mode 100644 index 000000000..81b8da682 --- /dev/null +++ b/candidate/migrations/0035_alter_candidatecampaign_politician_id_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-10 16:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0034_candidatesarepossibleduplicates'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='politician_id', + field=models.BigIntegerField(db_index=True, null=True, verbose_name='politician unique identifier'), + ), + migrations.AlterField( + model_name='candidatecampaign', + name='politician_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='we vote politician id'), + ), + ] diff --git a/candidate/migrations/0036_alter_candidatecampaign_ctcl_uuid.py b/candidate/migrations/0036_alter_candidatecampaign_ctcl_uuid.py new file mode 100644 index 000000000..6961d304c --- /dev/null +++ b/candidate/migrations/0036_alter_candidatecampaign_ctcl_uuid.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0035_alter_candidatecampaign_politician_id_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='ctcl_uuid', + field=models.CharField(blank=True, db_index=True, max_length=36, null=True, verbose_name='ctcl uuid'), + ), + ] diff --git a/candidate/migrations/0037_candidatecampaign_candidate_c_seo_fri_694764_idx.py b/candidate/migrations/0037_candidatecampaign_candidate_c_seo_fri_694764_idx.py new file mode 100644 index 000000000..6b6df0610 --- /dev/null +++ b/candidate/migrations/0037_candidatecampaign_candidate_c_seo_fri_694764_idx.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-13 14:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0036_alter_candidatecampaign_ctcl_uuid'), + ] + + operations = [ + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['seo_friendly_path', 'politician_we_vote_id'], name='candidate_c_seo_fri_694764_idx'), + ), + ] diff --git a/candidate/migrations/0038_remove_candidatecampaign_candidate_c_seo_fri_694764_idx_and_more.py b/candidate/migrations/0038_remove_candidatecampaign_candidate_c_seo_fri_694764_idx_and_more.py new file mode 100644 index 000000000..3304a7855 --- /dev/null +++ b/candidate/migrations/0038_remove_candidatecampaign_candidate_c_seo_fri_694764_idx_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-07-16 01:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0037_candidatecampaign_candidate_c_seo_fri_694764_idx'), + ] + + operations = [ + migrations.RemoveIndex( + model_name='candidatecampaign', + name='candidate_c_seo_fri_694764_idx', + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['seo_friendly_path', 'politician_we_vote_id', '-id'], name='candidate_seo_friendly_path1'), + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['politician_we_vote_id', 'seo_friendly_path', '-id'], name='candidate_seo_friendly_path2'), + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['politician_we_vote_id', 'candidate_name', 'candidate_twitter_handle', 'candidate_twitter_handle2', 'candidate_twitter_handle3'], name='candidate_list_for_politician'), + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['politician_we_vote_id', 'linked_campaignx_we_vote_id', '-id'], name='politician_linked_campaignx'), + ), + ] diff --git a/candidate/migrations/0039_candidatecampaign_list_politician_and_name_and_more.py b/candidate/migrations/0039_candidatecampaign_list_politician_and_name_and_more.py new file mode 100644 index 000000000..f399119a5 --- /dev/null +++ b/candidate/migrations/0039_candidatecampaign_list_politician_and_name_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.3 on 2024-07-16 17:45 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0038_remove_candidatecampaign_candidate_c_seo_fri_694764_idx_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['politician_we_vote_id', 'candidate_name'], name='list_politician_and_name'), + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['candidate_twitter_handle', 'candidate_twitter_handle2', 'candidate_twitter_handle3'], name='candidate_list_twitter'), + ), + ] diff --git a/candidate/migrations/0040_remove_candidatecampaign_candidate_list_for_politician_and_more.py b/candidate/migrations/0040_remove_candidatecampaign_candidate_list_for_politician_and_more.py new file mode 100644 index 000000000..458fc2a17 --- /dev/null +++ b/candidate/migrations/0040_remove_candidatecampaign_candidate_list_for_politician_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.3 on 2024-07-17 01:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0039_candidatecampaign_list_politician_and_name_and_more'), + ] + + operations = [ + migrations.RemoveIndex( + model_name='candidatecampaign', + name='candidate_list_for_politician', + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['candidate_name', 'politician_we_vote_id', 'candidate_twitter_handle', 'candidate_twitter_handle2', 'candidate_twitter_handle3'], name='candidate_list_for_politician'), + ), + ] diff --git a/candidate/migrations/0041_alter_candidatecampaign_candidate_year_and_more.py b/candidate/migrations/0041_alter_candidatecampaign_candidate_year_and_more.py new file mode 100644 index 000000000..41d6aeb64 --- /dev/null +++ b/candidate/migrations/0041_alter_candidatecampaign_candidate_year_and_more.py @@ -0,0 +1,26 @@ +# Generated by Django 5.0.8 on 2024-09-02 13:19 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0040_remove_candidatecampaign_candidate_list_for_politician_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='candidatecampaign', + name='candidate_year', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['candidate_year'], name='candidate_year_index'), + ), + migrations.AddIndex( + model_name='candidatecampaign', + index=models.Index(fields=['we_vote_id', 'candidate_year'], name='candidate_id_year'), + ), + ] diff --git a/candidate/migrations/0042_candidatectclalternatemap_and_more.py b/candidate/migrations/0042_candidatectclalternatemap_and_more.py new file mode 100644 index 000000000..f8dccaf1c --- /dev/null +++ b/candidate/migrations/0042_candidatectclalternatemap_and_more.py @@ -0,0 +1,26 @@ +# Generated by Django 5.0.8 on 2024-10-03 22:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0041_alter_candidatecampaign_candidate_year_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='CandidateCTCLAlternateMap', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('ctcl_uuid_primary', models.CharField(max_length=36, null=True)), + ('ctcl_uuid_alternate', models.CharField(max_length=36, null=True)), + ], + ), + migrations.AlterField( + model_name='candidatecampaign', + name='crowdpac_candidate_id', + field=models.PositiveIntegerField(blank=True, null=True), + ), + ] diff --git a/candidate/migrations/0043_candidatecampaign_bluesky_handle_and_more.py b/candidate/migrations/0043_candidatecampaign_bluesky_handle_and_more.py new file mode 100644 index 000000000..aa47a943b --- /dev/null +++ b/candidate/migrations/0043_candidatecampaign_bluesky_handle_and_more.py @@ -0,0 +1,43 @@ +# Generated by Django 5.0.13 on 2025-06-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0042_candidatectclalternatemap_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='bluesky_handle', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='tiktok_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_bluesky_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_bluesky_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_tiktok_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_tiktok_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/candidate/migrations/0044_candidatecampaign_is_claimed_profile.py b/candidate/migrations/0044_candidatecampaign_is_claimed_profile.py new file mode 100644 index 000000000..f2ba93925 --- /dev/null +++ b/candidate/migrations/0044_candidatecampaign_is_claimed_profile.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-10-25 23:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0043_candidatecampaign_bluesky_handle_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='is_claimed_profile', + field=models.BooleanField(default=False), + ), + ] diff --git a/candidate/migrations/0045_candidatecampaign_candidate_ultimate_election_date_calculated_and_more.py b/candidate/migrations/0045_candidatecampaign_candidate_ultimate_election_date_calculated_and_more.py new file mode 100644 index 000000000..cf53b69be --- /dev/null +++ b/candidate/migrations/0045_candidatecampaign_candidate_ultimate_election_date_calculated_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.13 on 2025-11-05 18:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0044_candidatecampaign_is_claimed_profile'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='candidate_ultimate_election_date_calculated', + field=models.BooleanField(db_index=True, default=False), + ), + migrations.AddField( + model_name='candidatecampaign', + name='contest_office_name_calculated', + field=models.BooleanField(db_index=True, default=False), + ), + ] diff --git a/candidate/migrations/0046_candidatecampaign_threads_handle_and_more.py b/candidate/migrations/0046_candidatecampaign_threads_handle_and_more.py new file mode 100644 index 000000000..54fc2c4a5 --- /dev/null +++ b/candidate/migrations/0046_candidatecampaign_threads_handle_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.13 on 2025-11-14 06:30 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0045_candidatecampaign_candidate_ultimate_election_date_calculated_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='threads_handle', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_threads_handle_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='candidatechangelog', + name='is_threads_handle_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/candidate/migrations/0047_deduplicationneededforstatetoday_and_more.py b/candidate/migrations/0047_deduplicationneededforstatetoday_and_more.py new file mode 100644 index 000000000..d8948178a --- /dev/null +++ b/candidate/migrations/0047_deduplicationneededforstatetoday_and_more.py @@ -0,0 +1,93 @@ +# Generated by Django 5.0.13 on 2025-11-24 15:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0046_candidatecampaign_threads_handle_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='DeduplicationNeededForStateToday', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_now_as_integer', models.PositiveIntegerField(db_index=True, null=True, unique=True)), + ('ak_deduplication_needed', models.BooleanField(default=True)), + ('al_deduplication_needed', models.BooleanField(default=True)), + ('ar_deduplication_needed', models.BooleanField(default=True)), + ('az_deduplication_needed', models.BooleanField(default=True)), + ('ca_deduplication_needed', models.BooleanField(default=True)), + ('co_deduplication_needed', models.BooleanField(default=True)), + ('ct_deduplication_needed', models.BooleanField(default=True)), + ('dc_deduplication_needed', models.BooleanField(default=True)), + ('de_deduplication_needed', models.BooleanField(default=True)), + ('fl_deduplication_needed', models.BooleanField(default=True)), + ('ga_deduplication_needed', models.BooleanField(default=True)), + ('hi_deduplication_needed', models.BooleanField(default=True)), + ('ia_deduplication_needed', models.BooleanField(default=True)), + ('id_deduplication_needed', models.BooleanField(default=True)), + ('il_deduplication_needed', models.BooleanField(default=True)), + ('in_deduplication_needed', models.BooleanField(default=True)), + ('ks_deduplication_needed', models.BooleanField(default=True)), + ('ky_deduplication_needed', models.BooleanField(default=True)), + ('la_deduplication_needed', models.BooleanField(default=True)), + ('ma_deduplication_needed', models.BooleanField(default=True)), + ('md_deduplication_needed', models.BooleanField(default=True)), + ('me_deduplication_needed', models.BooleanField(default=True)), + ('mi_deduplication_needed', models.BooleanField(default=True)), + ('mn_deduplication_needed', models.BooleanField(default=True)), + ('mo_deduplication_needed', models.BooleanField(default=True)), + ('ms_deduplication_needed', models.BooleanField(default=True)), + ('mt_deduplication_needed', models.BooleanField(default=True)), + ('na_deduplication_needed', models.BooleanField(default=True)), + ('nc_deduplication_needed', models.BooleanField(default=True)), + ('nd_deduplication_needed', models.BooleanField(default=True)), + ('ne_deduplication_needed', models.BooleanField(default=True)), + ('nh_deduplication_needed', models.BooleanField(default=True)), + ('nj_deduplication_needed', models.BooleanField(default=True)), + ('nm_deduplication_needed', models.BooleanField(default=True)), + ('nv_deduplication_needed', models.BooleanField(default=True)), + ('ny_deduplication_needed', models.BooleanField(default=True)), + ('oh_deduplication_needed', models.BooleanField(default=True)), + ('ok_deduplication_needed', models.BooleanField(default=True)), + ('or_deduplication_needed', models.BooleanField(default=True)), + ('pa_deduplication_needed', models.BooleanField(default=True)), + ('pr_deduplication_needed', models.BooleanField(default=True)), + ('ri_deduplication_needed', models.BooleanField(default=True)), + ('sc_deduplication_needed', models.BooleanField(default=True)), + ('sd_deduplication_needed', models.BooleanField(default=True)), + ('tn_deduplication_needed', models.BooleanField(default=True)), + ('tx_deduplication_needed', models.BooleanField(default=True)), + ('ut_deduplication_needed', models.BooleanField(default=True)), + ('va_deduplication_needed', models.BooleanField(default=True)), + ('vt_deduplication_needed', models.BooleanField(default=True)), + ('wa_deduplication_needed', models.BooleanField(default=True)), + ('wi_deduplication_needed', models.BooleanField(default=True)), + ('wv_deduplication_needed', models.BooleanField(default=True)), + ('wy_deduplication_needed', models.BooleanField(default=True)), + ], + ), + migrations.AddField( + model_name='candidatecampaign', + name='duplicate_check_last_completed', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='updated_from_politician_completed_first', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='updated_from_politician_completed_second', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='candidatecampaign', + name='updates_to_politician_completed', + field=models.DateTimeField(null=True), + ), + ] diff --git a/candidate/migrations/0048_candidatecampaign_opposers_count.py b/candidate/migrations/0048_candidatecampaign_opposers_count.py new file mode 100644 index 000000000..d8b49be41 --- /dev/null +++ b/candidate/migrations/0048_candidatecampaign_opposers_count.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2026-02-26 17:51 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('candidate', '0047_deduplicationneededforstatetoday_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='candidatecampaign', + name='opposers_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/challenge/migrations/0001_initial.py b/challenge/migrations/0001_initial.py new file mode 100644 index 000000000..7ba2f87b5 --- /dev/null +++ b/challenge/migrations/0001_initial.py @@ -0,0 +1,167 @@ +# Generated by Django 5.0.8 on 2024-08-28 00:53 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Challenge', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('challenge_description', models.TextField(blank=True, null=True)), + ('challenge_title', models.CharField(max_length=255, verbose_name='title of challenge')), + ('date_last_updated_from_politician', models.DateTimeField(default=None, null=True)), + ('final_election_date_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('in_draft_mode', models.BooleanField(db_index=True, default=True)), + ('is_ok_to_promote_on_we_vote', models.BooleanField(db_index=True, default=True)), + ('is_blocked_by_we_vote', models.BooleanField(db_index=True, default=False)), + ('is_blocked_by_we_vote_reason', models.TextField(blank=True, null=True)), + ('is_in_team_review_mode', models.BooleanField(db_index=True, default=False)), + ('is_not_promoted_by_we_vote', models.BooleanField(db_index=True, default=False)), + ('is_not_promoted_by_we_vote_reason', models.TextField(blank=True, null=True)), + ('is_still_active', models.BooleanField(db_index=True, default=True)), + ('is_victorious', models.BooleanField(db_index=True, default=False)), + ('politician_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('politician_we_vote_id_verified', models.BooleanField(default=False)), + ('opposers_count', models.PositiveIntegerField(default=0)), + ('organization_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('politician_starter_list_serialized', models.TextField(blank=True, null=True)), + ('profile_image_background_color', models.CharField(blank=True, max_length=7, null=True)), + ('seo_friendly_path', models.CharField(db_index=True, max_length=255, null=True)), + ('started_by_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True)), + ('supporters_count', models.PositiveIntegerField(default=0)), + ('supporters_count_to_update_with_bulk_script', models.BooleanField(default=True)), + ('supporters_count_minimum_ignored', models.BooleanField(db_index=True, default=False)), + ('supporters_count_victory_goal', models.PositiveIntegerField(default=0)), + ('we_vote_hosted_challenge_photo_original_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_challenge_photo_large_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_challenge_photo_medium_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_challenge_photo_small_url', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('date_challenge_started', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='ChallengeListedByOrganization', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('site_owner_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('listing_requested_by_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('visible_to_public', models.BooleanField(default=False)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='ChallengeNewsItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('speaker_name', models.CharField(max_length=255, null=True)), + ('challenge_news_subject', models.TextField(null=True)), + ('challenge_news_text', models.TextField(null=True)), + ('in_draft_mode', models.BooleanField(db_index=True, default=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ('visibility_blocked_by_we_vote', models.BooleanField(default=False)), + ('visible_to_public', models.BooleanField(default=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('date_posted', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('date_sent_to_email', models.DateTimeField(db_index=True, null=True)), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='ChallengeOwner', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ('feature_this_profile_image', models.BooleanField(default=True)), + ('order_in_list', models.PositiveIntegerField(null=True)), + ('organization_name', models.CharField(max_length=255)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('visible_to_public', models.BooleanField(default=False)), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='ChallengePolitician', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('next_election_date_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('candidate_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('politician_name', models.CharField(max_length=255)), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='politician home state')), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='ChallengesAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge1_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, verbose_name='first challenge we are tracking')), + ('challenge2_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, verbose_name='second challenge we are tracking')), + ], + ), + migrations.CreateModel( + name='ChallengesArePossibleDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge1_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('challenge2_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True)), + ], + ), + migrations.CreateModel( + name='ChallengeSEOFriendlyPath', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_we_vote_id', models.CharField(max_length=255, null=True)), + ('challenge_title', models.CharField(max_length=255)), + ('base_pathname_string', models.CharField(max_length=255, null=True)), + ('pathname_modifier', models.CharField(max_length=10, null=True)), + ('final_pathname_string', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='ChallengeSupporter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_supported', models.BooleanField(db_index=True, default=True)), + ('challenge_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('date_supported', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('is_subscribed_by_email', models.BooleanField(default=None, null=True)), + ('linked_position_we_vote_id', models.CharField(max_length=255, null=True)), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('supporter_name', models.CharField(max_length=255, null=True)), + ('supporter_endorsement', models.TextField(null=True)), + ('visibility_blocked_by_we_vote', models.BooleanField(default=False)), + ('visible_to_public', models.BooleanField(default=False)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ], + ), + ] diff --git a/challenge/migrations/0002_challengeparticipant_delete_challengesupporter_and_more.py b/challenge/migrations/0002_challengeparticipant_delete_challengesupporter_and_more.py new file mode 100644 index 000000000..897984324 --- /dev/null +++ b/challenge/migrations/0002_challengeparticipant_delete_challengesupporter_and_more.py @@ -0,0 +1,55 @@ +# Generated by Django 5.0.8 on 2024-09-17 14:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='ChallengeParticipant', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('date_joined', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('is_subscribed_by_email', models.BooleanField(default=None, null=True)), + ('linked_position_we_vote_id', models.CharField(max_length=255, null=True)), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('participant_name', models.CharField(max_length=255, null=True)), + ('participant_endorsement', models.TextField(null=True)), + ('visibility_blocked_by_we_vote', models.BooleanField(default=False)), + ('visible_to_public', models.BooleanField(default=True)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ], + ), + migrations.DeleteModel( + name='ChallengeSupporter', + ), + migrations.RenameField( + model_name='challenge', + old_name='supporters_count', + new_name='participants_count', + ), + migrations.RenameField( + model_name='challenge', + old_name='supporters_count_minimum_ignored', + new_name='participants_count_minimum_ignored', + ), + migrations.RenameField( + model_name='challenge', + old_name='supporters_count_to_update_with_bulk_script', + new_name='participants_count_to_update_with_bulk_script', + ), + migrations.RenameField( + model_name='challenge', + old_name='supporters_count_victory_goal', + new_name='participants_count_victory_goal', + ), + ] diff --git a/challenge/migrations/0003_remove_challengeparticipant_is_subscribed_by_email_and_more.py b/challenge/migrations/0003_remove_challengeparticipant_is_subscribed_by_email_and_more.py new file mode 100644 index 000000000..ce3c4f657 --- /dev/null +++ b/challenge/migrations/0003_remove_challengeparticipant_is_subscribed_by_email_and_more.py @@ -0,0 +1,60 @@ +# Generated by Django 5.0.8 on 2024-09-21 14:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0002_challengeparticipant_delete_challengesupporter_and_more'), + ] + + operations = [ + migrations.RemoveField( + model_name='challengeparticipant', + name='is_subscribed_by_email', + ), + migrations.RemoveField( + model_name='challengeparticipant', + name='linked_position_we_vote_id', + ), + migrations.RemoveField( + model_name='challengeparticipant', + name='participant_endorsement', + ), + migrations.AddField( + model_name='challengeparticipant', + name='custom_message_for_friends', + field=models.TextField(null=True), + ), + migrations.AddField( + model_name='challengeparticipant', + name='friends_invited', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='challengeparticipant', + name='friends_who_joined', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='challengeparticipant', + name='friends_who_viewed', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='challengeparticipant', + name='friends_who_viewed_plus', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='challengeparticipant', + name='points', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='challengeparticipant', + name='rank', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/challenge/migrations/0004_challengeinvitee_and_more.py b/challenge/migrations/0004_challengeinvitee_and_more.py new file mode 100644 index 000000000..1d48e6525 --- /dev/null +++ b/challenge/migrations/0004_challengeinvitee_and_more.py @@ -0,0 +1,83 @@ +# Generated by Django 5.0.8 on 2024-09-26 17:56 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0003_remove_challengeparticipant_is_subscribed_by_email_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='ChallengeInvitee', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('challenge_joined', models.BooleanField(default=False)), + ('challenge_we_vote_id', models.CharField(max_length=255)), + ('custom_message_from_inviter', models.TextField(null=True)), + ('date_accepted_invite', models.DateTimeField(null=True)), + ('date_invited', models.DateTimeField(auto_now_add=True, null=True)), + ('invitee_name', models.CharField(max_length=255, null=True)), + ('invitee_url_code', models.CharField(max_length=50, null=True)), + ('inviter_name', models.CharField(max_length=255, null=True)), + ('inviter_voter_we_vote_id', models.CharField(max_length=255, null=True)), + ('invite_sent', models.BooleanField(default=False)), + ('invite_viewed', models.BooleanField(default=False)), + ('invite_viewed_count', models.PositiveIntegerField(default=0)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ], + ), + migrations.RemoveField( + model_name='challenge', + name='date_challenge_started', + ), + migrations.AddField( + model_name='challenge', + name='challenge_ends_date_as_integer', + field=models.PositiveIntegerField(null=True), + ), + migrations.AddField( + model_name='challenge', + name='challenge_starts_date_as_integer', + field=models.PositiveIntegerField(null=True), + ), + migrations.AlterField( + model_name='challengeparticipant', + name='challenge_we_vote_id', + field=models.CharField(max_length=255), + ), + migrations.AlterField( + model_name='challengeparticipant', + name='date_joined', + field=models.DateTimeField(auto_now_add=True, null=True), + ), + migrations.AlterField( + model_name='challengeparticipant', + name='date_last_changed', + field=models.DateTimeField(auto_now=True, null=True), + ), + migrations.AlterField( + model_name='challengeparticipant', + name='voter_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddIndex( + model_name='challengeparticipant', + index=models.Index(fields=['challenge_we_vote_id', '-points'], name='challenge_points'), + ), + migrations.AddIndex( + model_name='challengeparticipant', + index=models.Index(fields=['voter_we_vote_id', 'challenge_we_vote_id'], name='voter_challenge_participant'), + ), + migrations.AddIndex( + model_name='challengeinvitee', + index=models.Index(fields=['invitee_url_code'], name='invitee_url_code_index'), + ), + migrations.AddIndex( + model_name='challengeinvitee', + index=models.Index(fields=['inviter_voter_we_vote_id', 'challenge_we_vote_id'], name='inviter_challenge_list'), + ), + ] diff --git a/challenge/migrations/0005_rename_custom_message_from_inviter_challengeinvitee_invite_text_from_inviter_and_more.py b/challenge/migrations/0005_rename_custom_message_from_inviter_challengeinvitee_invite_text_from_inviter_and_more.py new file mode 100644 index 000000000..7edc74a17 --- /dev/null +++ b/challenge/migrations/0005_rename_custom_message_from_inviter_challengeinvitee_invite_text_from_inviter_and_more.py @@ -0,0 +1,32 @@ +# Generated by Django 5.0.8 on 2024-09-30 03:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0004_challengeinvitee_and_more'), + ] + + operations = [ + migrations.RenameField( + model_name='challengeinvitee', + old_name='custom_message_from_inviter', + new_name='invite_text_from_inviter', + ), + migrations.RenameField( + model_name='challengeparticipant', + old_name='custom_message_for_friends', + new_name='invite_text_for_friends', + ), + migrations.AddField( + model_name='challenge', + name='challenge_invite_text_default', + field=models.TextField(blank=True, null=True), + ), + migrations.AddIndex( + model_name='challengeparticipant', + index=models.Index(fields=['challenge_we_vote_id'], name='challenge_we_vote_id'), + ), + ] diff --git a/challenge/migrations/0006_rename_date_accepted_invite_challengeinvitee_date_challenge_joined_and_more.py b/challenge/migrations/0006_rename_date_accepted_invite_challengeinvitee_date_challenge_joined_and_more.py new file mode 100644 index 000000000..113f9ce45 --- /dev/null +++ b/challenge/migrations/0006_rename_date_accepted_invite_challengeinvitee_date_challenge_joined_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.8 on 2024-10-01 17:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0005_rename_custom_message_from_inviter_challengeinvitee_invite_text_from_inviter_and_more'), + ] + + operations = [ + migrations.RenameField( + model_name='challengeinvitee', + old_name='date_accepted_invite', + new_name='date_challenge_joined', + ), + migrations.RenameField( + model_name='challengeinvitee', + old_name='date_invited', + new_name='date_invite_sent', + ), + migrations.AddField( + model_name='challengeinvitee', + name='date_invite_viewed', + field=models.DateTimeField(null=True), + ), + ] diff --git a/challenge/migrations/0007_rename_friends_invited_challengeparticipant_invitees_count_and_more.py b/challenge/migrations/0007_rename_friends_invited_challengeparticipant_invitees_count_and_more.py new file mode 100644 index 000000000..c3fc0c8ea --- /dev/null +++ b/challenge/migrations/0007_rename_friends_invited_challengeparticipant_invitees_count_and_more.py @@ -0,0 +1,38 @@ +# Generated by Django 5.0.8 on 2024-10-03 22:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0006_rename_date_accepted_invite_challengeinvitee_date_challenge_joined_and_more'), + ] + + operations = [ + migrations.RenameField( + model_name='challengeparticipant', + old_name='friends_invited', + new_name='invitees_count', + ), + migrations.RenameField( + model_name='challengeparticipant', + old_name='friends_who_joined', + new_name='invitees_who_joined', + ), + migrations.RenameField( + model_name='challengeparticipant', + old_name='friends_who_viewed', + new_name='invitees_who_viewed', + ), + migrations.RenameField( + model_name='challengeparticipant', + old_name='friends_who_viewed_plus', + new_name='invitees_who_viewed_plus', + ), + migrations.AddField( + model_name='challenge', + name='invitees_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/challenge/migrations/0008_challengeparticipant_invites_sent_count.py b/challenge/migrations/0008_challengeparticipant_invites_sent_count.py new file mode 100644 index 000000000..7ff6bdef9 --- /dev/null +++ b/challenge/migrations/0008_challengeparticipant_invites_sent_count.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.8 on 2024-10-07 21:24 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0007_rename_friends_invited_challengeparticipant_invitees_count_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='challengeparticipant', + name='invites_sent_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/challenge/migrations/0009_challengeinvitee_invitee_voter_name_and_more.py b/challenge/migrations/0009_challengeinvitee_invitee_voter_name_and_more.py new file mode 100644 index 000000000..986ac9048 --- /dev/null +++ b/challenge/migrations/0009_challengeinvitee_invitee_voter_name_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.9 on 2024-10-13 17:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0008_challengeparticipant_invites_sent_count'), + ] + + operations = [ + migrations.AddField( + model_name='challengeinvitee', + name='invitee_voter_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='challengeinvitee', + name='invitee_voter_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='challengeinvitee', + name='parent_invitee_id', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='challengeparticipant', + name='inviter_voter_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/challenge/migrations/0010_remove_challenge_opposers_count.py b/challenge/migrations/0010_remove_challenge_opposers_count.py new file mode 100644 index 000000000..1c6f24171 --- /dev/null +++ b/challenge/migrations/0010_remove_challenge_opposers_count.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.9 on 2024-10-14 20:11 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('challenge', '0009_challengeinvitee_invitee_voter_name_and_more'), + ] + + operations = [ + migrations.RemoveField( + model_name='challenge', + name='opposers_count', + ), + ] diff --git a/election/migrations/0001_initial.py b/election/migrations/0001_initial.py new file mode 100644 index 000000000..dcef574ab --- /dev/null +++ b/election/migrations/0001_initial.py @@ -0,0 +1,64 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BallotpediaElection', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('ballotpedia_election_id', models.PositiveIntegerField(null=True, unique=True, verbose_name='ballotpedia election id')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('election_description', models.CharField(max_length=255, null=True, verbose_name='election description')), + ('election_type', models.CharField(blank=True, max_length=255, null=True, verbose_name='election type')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('district_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='district name')), + ('district_type', models.CharField(blank=True, max_length=255, null=True, verbose_name='district type')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state code for the election')), + ('is_general_election', models.BooleanField(default=False)), + ('is_general_runoff_election', models.BooleanField(default=False)), + ('is_primary_election', models.BooleanField(default=False)), + ('is_primary_runoff_election', models.BooleanField(default=False)), + ('is_partisan', models.BooleanField(default=False)), + ('candidate_lists_complete', models.BooleanField(default=False)), + ('internal_notes', models.TextField(blank=True, default=None, null=True)), + ], + ), + migrations.CreateModel( + name='Election', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('google_civic_election_id', models.CharField(max_length=20, null=True, unique=True, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('ballotpedia_election_id', models.PositiveIntegerField(null=True, unique=True, verbose_name='ballotpedia election id')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('election_name', models.CharField(max_length=255, verbose_name='election name')), + ('election_day_text', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='election day')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('ballotpedia_kind_of_election', models.CharField(blank=True, max_length=255, null=True, verbose_name='election filter')), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='state code for the election')), + ('state_code_list_raw', models.CharField(blank=True, max_length=255, null=True)), + ('include_in_list_for_voters', models.BooleanField(default=False)), + ('internal_notes', models.TextField(blank=True, default=None, null=True)), + ('ignore_this_election', models.BooleanField(default=False)), + ('election_preparation_finished', models.BooleanField(default=False)), + ('candidate_photos_finished', models.BooleanField(default=False)), + ('is_national_election', models.BooleanField(default=False)), + ('use_ballotpedia_as_data_source', models.BooleanField(default=False)), + ('use_ctcl_as_data_source', models.BooleanField(default=False)), + ('use_ctcl_as_data_source_by_state_code', models.CharField(blank=True, max_length=255, null=True)), + ('use_google_civic_as_data_source', models.BooleanField(default=False)), + ('use_vote_usa_as_data_source', models.BooleanField(default=False)), + ('vote_usa_election_id', models.CharField(max_length=255, null=True)), + ], + ), + ] diff --git a/election/migrations/0002_election_vote_usa_same_day_election_suffix_list.py b/election/migrations/0002_election_vote_usa_same_day_election_suffix_list.py new file mode 100644 index 000000000..fafed8e72 --- /dev/null +++ b/election/migrations/0002_election_vote_usa_same_day_election_suffix_list.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.13 on 2022-05-23 00:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('election', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='election', + name='vote_usa_same_day_election_suffix_list', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/election/migrations/0003_auto_20220727_1420.py b/election/migrations/0003_auto_20220727_1420.py new file mode 100644 index 000000000..e119f06a7 --- /dev/null +++ b/election/migrations/0003_auto_20220727_1420.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.14 on 2022-07-27 21:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('election', '0002_election_vote_usa_same_day_election_suffix_list'), + ] + + operations = [ + migrations.AlterField( + model_name='election', + name='google_civic_election_id', + field=models.CharField(db_index=True, max_length=20, null=True, unique=True, verbose_name='google civic election id'), + ), + migrations.AlterField( + model_name='election', + name='ignore_this_election', + field=models.BooleanField(db_index=True, default=False), + ), + migrations.AlterField( + model_name='election', + name='include_in_list_for_voters', + field=models.BooleanField(db_index=True, default=False), + ), + ] diff --git a/election/migrations/0004_auto_20230616_0717.py b/election/migrations/0004_auto_20230616_0717.py new file mode 100644 index 000000000..b3e95da2d --- /dev/null +++ b/election/migrations/0004_auto_20230616_0717.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.19 on 2023-06-16 14:17 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('election', '0003_auto_20220727_1420'), + ] + + operations = [ + migrations.AddField( + model_name='election', + name='ctcl_uuid2', + field=models.CharField(blank=True, max_length=36, null=True), + ), + migrations.AddField( + model_name='election', + name='ctcl_uuid3', + field=models.CharField(blank=True, max_length=36, null=True), + ), + ] diff --git a/electoral_district/migrations/0001_initial.py b/electoral_district/migrations/0001_initial.py new file mode 100644 index 000000000..0a6fc43ba --- /dev/null +++ b/electoral_district/migrations/0001_initial.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='ElectoralDistrict', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('ctcl_id_temp', models.CharField(max_length=255, null=True, unique=True, verbose_name='temporary ctcl id')), + ('we_vote_id', models.CharField(max_length=255, null=True, unique=True, verbose_name='permanent we vote id')), + ('electoral_district_name', models.CharField(max_length=255, null=True, verbose_name='electoral district name')), + ('electoral_district_type', models.CharField(choices=[('borough', 'borough'), ('city', 'city'), ('city_council', 'city-council'), ('congressional', 'congressional'), ('county', 'county'), ('county-council', 'county-council'), ('judicial', 'judicial'), ('municipality', 'municipality'), ('national', 'national'), ('school', 'school'), ('special', 'special'), ('state', 'state'), ('state-house', 'state-house'), ('state-senate', 'state-senate'), ('town', 'town'), ('township', 'township'), ('utility', 'utility'), ('village', 'village'), ('ward', 'ward'), ('water', 'water'), ('other', 'other')], default='state', max_length=16, verbose_name='electoral district type')), + ('electoral_district_number', models.PositiveIntegerField(blank=True, null=True, verbose_name='electoral district number')), + ('electoral_district_other_type', models.CharField(blank=True, max_length=255, null=True, verbose_name='Allows for cataloging a new DistrictType option when Type is specified as other')), + ('ocd_id_external_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd id external identifier')), + ('ballotpedia_district_id', models.PositiveIntegerField(blank=True, null=True)), + ('ballotpedia_district_kml', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of kml file on ballotpedia')), + ('ballotpedia_district_latitude', models.FloatField(null=True, verbose_name='latitude')), + ('ballotpedia_district_longitude', models.FloatField(null=True, verbose_name='longitude')), + ('ballotpedia_district_type', models.CharField(blank=True, max_length=255, null=True)), + ('ballotpedia_district_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of district on ballotpedia')), + ('ballotpedia_district_ocd_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd id identifier')), + ('geo_id', models.CharField(blank=True, max_length=50, null=True, verbose_name='us census geo id')), + ('nces_id', models.CharField(blank=True, max_length=50, null=True, verbose_name='school nces id')), + ('state_code', models.CharField(blank=True, max_length=3, null=True, verbose_name='state code')), + ], + ), + migrations.CreateModel( + name='ElectoralDistrictLinkToPollingLocation', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('polling_location_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('electoral_district_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('ballotpedia_district_id', models.PositiveIntegerField(blank=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('state_code', models.CharField(blank=True, max_length=3, null=True, verbose_name='state code')), + ], + ), + ] diff --git a/email_outbound/migrations/0001_initial.py b/email_outbound/migrations/0001_initial.py new file mode 100644 index 000000000..e5ed6699c --- /dev/null +++ b/email_outbound/migrations/0001_initial.py @@ -0,0 +1,96 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='EmailAddress', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote id of this email address')), + ('voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the email owner')), + ('normalized_email_address', models.EmailField(max_length=255, verbose_name='email address')), + ('email_ownership_is_verified', models.BooleanField(default=False)), + ('email_permanent_bounce', models.BooleanField(default=False)), + ('secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to verify ownership of email')), + ('subscription_secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='EmailOutboundDescription', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('kind_of_email_template', models.CharField(choices=[('GENERIC_EMAIL_TEMPLATE', 'Generic Email'), ('FRIEND_ACCEPTED_INVITATION_TEMPLATE', 'Accept an invitation to be a Friend'), ('FRIEND_INVITATION_TEMPLATE', 'Invite Friend'), ('LINK_TO_SIGN_IN_TEMPLATE', 'Link to sign in.'), ('NOTICE_FRIEND_ENDORSEMENTS_TEMPLATE', 'New opinion from Friend.'), ('NOTICE_VOTER_DAILY_SUMMARY_TEMPLATE', 'Daily summary of activity for the voter.'), ('VERIFY_EMAIL_ADDRESS_TEMPLATE', 'Verify Senders Email Address'), ('SEND_BALLOT_TO_SELF', 'Send ballot to self'), ('SEND_BALLOT_TO_FRIENDS', 'Send ballot to friends'), ('SIGN_IN_CODE_EMAIL_TEMPLATE', 'Send code to verify sign in.')], default='GENERIC_EMAIL_TEMPLATE', max_length=50)), + ('sender_voter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='sender full name')), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('sender_voter_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='email address for sender')), + ('recipient_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the recipient if we have it')), + ('recipient_email_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='email we vote id for recipient')), + ('recipient_voter_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='email address for recipient')), + ('template_variables_in_json', models.TextField(blank=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='EmailScheduled', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('subject', models.CharField(blank=True, max_length=255, null=True, verbose_name='email subject')), + ('message_text', models.TextField(blank=True, null=True)), + ('message_html', models.TextField(blank=True, null=True)), + ('sender_voter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='sender full name')), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('sender_voter_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='sender email address')), + ('recipient_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the recipient')), + ('recipient_email_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the email')), + ('recipient_voter_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='recipient email address')), + ('send_status', models.CharField(choices=[('TO_BE_PROCESSED', 'Message to be processed'), ('BEING_SENT', 'Message being sent'), ('SENT', 'Message sent')], default='TO_BE_PROCESSED', max_length=50)), + ('email_outbound_description_id', models.PositiveIntegerField(default=0, verbose_name='the internal id of EmailOutboundDescription')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='SendGridApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True)), + ('number_of_items_sent_in_query', models.PositiveIntegerField(db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='SendGridApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='SendGridApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='SendGridApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + ] diff --git a/email_outbound/migrations/0002_alter_emailoutbounddescription_kind_of_email_template.py b/email_outbound/migrations/0002_alter_emailoutbounddescription_kind_of_email_template.py new file mode 100644 index 000000000..0fbd83bdc --- /dev/null +++ b/email_outbound/migrations/0002_alter_emailoutbounddescription_kind_of_email_template.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.13 on 2022-05-19 19:17 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='emailoutbounddescription', + name='kind_of_email_template', + field=models.CharField(choices=[('GENERIC_EMAIL_TEMPLATE', 'Generic Email'), ('FRIEND_ACCEPTED_INVITATION_TEMPLATE', 'Accept an invitation to be a Friend'), ('FRIEND_INVITATION_TEMPLATE', 'Invite Friend'), ('LINK_TO_SIGN_IN_TEMPLATE', 'Link to sign in.'), ('MESSAGE_TO_FRIEND_TEMPLATE', 'Message to friend'), ('NOTICE_FRIEND_ENDORSEMENTS_TEMPLATE', 'New opinion from Friend.'), ('NOTICE_VOTER_DAILY_SUMMARY_TEMPLATE', 'Daily summary of activity for the voter.'), ('VERIFY_EMAIL_ADDRESS_TEMPLATE', 'Verify Senders Email Address'), ('SEND_BALLOT_TO_SELF', 'Send ballot to self'), ('SEND_BALLOT_TO_FRIENDS', 'Send ballot to friends'), ('SIGN_IN_CODE_EMAIL_TEMPLATE', 'Send code to verify sign in.')], default='GENERIC_EMAIL_TEMPLATE', max_length=50), + ), + ] diff --git a/email_outbound/migrations/0003_auto_20220720_1721.py b/email_outbound/migrations/0003_auto_20220720_1721.py new file mode 100644 index 000000000..3d5042891 --- /dev/null +++ b/email_outbound/migrations/0003_auto_20220720_1721.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.13 on 2022-07-21 00:21 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0002_alter_emailoutbounddescription_kind_of_email_template'), + ] + + operations = [ + migrations.AddField( + model_name='emailoutbounddescription', + name='list_unsubscribe_mailto', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailoutbounddescription', + name='list_unsubscribe_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailscheduled', + name='list_unsubscribe_mailto', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailscheduled', + name='list_unsubscribe_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/email_outbound/migrations/0004_alter_emailoutbounddescription_kind_of_email_template.py b/email_outbound/migrations/0004_alter_emailoutbounddescription_kind_of_email_template.py new file mode 100644 index 000000000..e3ca02d4e --- /dev/null +++ b/email_outbound/migrations/0004_alter_emailoutbounddescription_kind_of_email_template.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.15 on 2022-10-25 03:26 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0003_auto_20220720_1721'), + ] + + operations = [ + migrations.AlterField( + model_name='emailoutbounddescription', + name='kind_of_email_template', + field=models.CharField(choices=[('GENERIC_EMAIL_TEMPLATE', 'Generic Email'), ('FRIEND_ACCEPTED_INVITATION_TEMPLATE', 'Accept an invitation to be a Friend'), ('FRIEND_INVITATION_TEMPLATE', 'Invite Friend'), ('LINK_TO_SIGN_IN_TEMPLATE', 'Link to sign in.'), ('MESSAGE_TO_FRIEND_TEMPLATE', 'Message to friend'), ('NOTICE_FRIEND_ENDORSEMENTS_TEMPLATE', 'New opinion from Friend.'), ('NOTICE_VOTER_DAILY_SUMMARY_TEMPLATE', 'Daily summary of activity for the voter.'), ('REMIND_CONTACT', 'Remind contact to vote'), ('VERIFY_EMAIL_ADDRESS_TEMPLATE', 'Verify Senders Email Address'), ('SEND_BALLOT_TO_SELF', 'Send ballot to self'), ('SEND_BALLOT_TO_FRIENDS', 'Send ballot to friends'), ('SIGN_IN_CODE_EMAIL_TEMPLATE', 'Send code to verify sign in.')], default='GENERIC_EMAIL_TEMPLATE', max_length=50), + ), + ] diff --git a/email_outbound/migrations/0005_alter_emailaddress_voter_we_vote_id_and_more.py b/email_outbound/migrations/0005_alter_emailaddress_voter_we_vote_id_and_more.py new file mode 100644 index 000000000..76cf71c38 --- /dev/null +++ b/email_outbound/migrations/0005_alter_emailaddress_voter_we_vote_id_and_more.py @@ -0,0 +1,53 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0004_alter_emailoutbounddescription_kind_of_email_template'), + ] + + operations = [ + migrations.AlterField( + model_name='emailaddress', + name='voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the email owner'), + ), + migrations.AlterField( + model_name='emailaddress', + name='we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote id of this email address'), + ), + migrations.AlterField( + model_name='emailoutbounddescription', + name='recipient_email_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='email we vote id for recipient'), + ), + migrations.AlterField( + model_name='emailoutbounddescription', + name='recipient_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the recipient if we have it'), + ), + migrations.AlterField( + model_name='emailoutbounddescription', + name='sender_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender'), + ), + migrations.AlterField( + model_name='emailscheduled', + name='recipient_email_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the email'), + ), + migrations.AlterField( + model_name='emailscheduled', + name='recipient_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the recipient'), + ), + migrations.AlterField( + model_name='emailscheduled', + name='sender_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender'), + ), + ] diff --git a/email_outbound/migrations/0006_emailcampaign_emailcampaignlabel_and_more.py b/email_outbound/migrations/0006_emailcampaign_emailcampaignlabel_and_more.py new file mode 100644 index 000000000..bf26c3e50 --- /dev/null +++ b/email_outbound/migrations/0006_emailcampaign_emailcampaignlabel_and_more.py @@ -0,0 +1,83 @@ +# Generated by Django 5.0.13 on 2025-10-22 16:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0005_alter_emailaddress_voter_we_vote_id_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='EmailCampaign', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email_campaign_name', models.CharField(db_index=True, max_length=255, null=True)), + ('deleted', models.BooleanField(default=False)), + ('email_body_template_raw', models.TextField(blank=True, null=True)), + ('email_subject_template_raw', models.CharField(blank=True, max_length=255, null=True)), + ('email_template_id', models.PositiveIntegerField(default=0)), + ('emails_sent', models.BooleanField(default=False)), + ('is_for_politician', models.BooleanField(default=False)), + ('is_for_staff', models.BooleanField(default=False)), + ('is_for_voter', models.BooleanField(default=False)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='EmailCampaignLabel', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('label_name', models.CharField(db_index=True, max_length=255, null=True)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='EmailCampaignLabelLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email_campaign_id', models.PositiveIntegerField(default=0)), + ('email_campaign_label_id', models.PositiveIntegerField(default=0)), + ], + ), + migrations.CreateModel( + name='EmailCampaignRecipient', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email_body_assembled', models.TextField(blank=True, null=True)), + ('email_campaign_id', models.PositiveIntegerField(default=0)), + ('email_scheduled', models.BooleanField(default=False)), + ('email_subject_assembled', models.CharField(blank=True, max_length=255, null=True)), + ('recipient_name', models.CharField(db_index=True, max_length=255, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='EmailTemplate', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('archived', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ('email_template_folder_id', models.PositiveIntegerField(default=0)), + ('email_template_name', models.CharField(db_index=True, max_length=255, null=True)), + ('message', models.TextField(blank=True, null=True)), + ('subject', models.CharField(max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='EmailTemplateFolder', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email_template_name', models.CharField(db_index=True, max_length=255, null=True)), + ('archived', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.AlterField( + model_name='emailoutbounddescription', + name='kind_of_email_template', + field=models.CharField(choices=[('GENERIC_EMAIL_TEMPLATE', 'Generic Email'), ('FROM_TEMPLATE_SYSTEM', 'From Dynamic Email Template'), ('FRIEND_ACCEPTED_INVITATION_TEMPLATE', 'Accept an invitation to be a Friend'), ('FRIEND_INVITATION_TEMPLATE', 'Invite Friend'), ('LINK_TO_SIGN_IN_TEMPLATE', 'Link to sign in.'), ('MESSAGE_TO_FRIEND_TEMPLATE', 'Message to friend'), ('NOTICE_FRIEND_ENDORSEMENTS_TEMPLATE', 'New opinion from Friend.'), ('NOTICE_VOTER_DAILY_SUMMARY_TEMPLATE', 'Daily summary of activity for the voter.'), ('REMIND_CONTACT', 'Remind contact to vote'), ('VERIFY_EMAIL_ADDRESS_TEMPLATE', 'Verify Senders Email Address'), ('SEND_BALLOT_TO_SELF', 'Send ballot to self'), ('SEND_BALLOT_TO_FRIENDS', 'Send ballot to friends'), ('SIGN_IN_CODE_EMAIL_TEMPLATE', 'Send code to verify sign in.')], default='GENERIC_EMAIL_TEMPLATE', max_length=50), + ), + ] diff --git a/email_outbound/migrations/0007_alter_emailtemplate_email_template_folder_id.py b/email_outbound/migrations/0007_alter_emailtemplate_email_template_folder_id.py new file mode 100644 index 000000000..0e89eee14 --- /dev/null +++ b/email_outbound/migrations/0007_alter_emailtemplate_email_template_folder_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-11-14 06:30 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0006_emailcampaign_emailcampaignlabel_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='emailtemplate', + name='email_template_folder_id', + field=models.PositiveIntegerField(default=0, null=True), + ), + ] diff --git a/email_outbound/migrations/0008_emailrecipienttemplate_emailrecipienttemplatefolder_and_more.py b/email_outbound/migrations/0008_emailrecipienttemplate_emailrecipienttemplatefolder_and_more.py new file mode 100644 index 000000000..c6c122076 --- /dev/null +++ b/email_outbound/migrations/0008_emailrecipienttemplate_emailrecipienttemplatefolder_and_more.py @@ -0,0 +1,72 @@ +# Generated by Django 5.0.13 on 2025-12-03 15:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0007_alter_emailtemplate_email_template_folder_id'), + ] + + operations = [ + migrations.CreateModel( + name='EmailRecipientTemplate', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('archived', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ('has_email', models.BooleanField(default=None, null=True)), + ('has_no_email', models.BooleanField(default=None, null=True)), + ('has_no_sms', models.BooleanField(default=None, null=True)), + ('has_sms', models.BooleanField(default=None, null=True)), + ('include_candidates_from_prior_elections', models.BooleanField(default=None, null=True)), + ('is_candidate', models.BooleanField(default=None, null=True)), + ('is_organization', models.BooleanField(default=None, null=True)), + ('is_politician', models.BooleanField(default=None, null=True)), + ('is_voter', models.BooleanField(default=None, null=True)), + ('parent_template_operator', models.CharField(db_index=True, max_length=16, null=True)), + ('parent_recipient_template_id', models.PositiveIntegerField(default=0, null=True)), + ('recipient_template_folder_id', models.PositiveIntegerField(default=0, null=True)), + ('recipient_template_name', models.CharField(db_index=True, max_length=255, null=True)), + ('search_google_civic_election_id', models.PositiveIntegerField(default=0, null=True)), + ('search_term_candidate', models.CharField(max_length=255, null=True)), + ('search_term_organization', models.CharField(max_length=255, null=True)), + ('search_term_politician', models.CharField(max_length=255, null=True)), + ('search_term_political_party', models.CharField(max_length=255, null=True)), + ('search_term_state_code', models.CharField(max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='EmailRecipientTemplateFolder', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('recipient_template_name', models.CharField(db_index=True, max_length=255, null=True)), + ('archived', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='EmailRecipientTemplateLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email_campaign_id', models.PositiveIntegerField(default=0, null=True)), + ('recipient_template_id', models.PositiveIntegerField(default=0, null=True)), + ], + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='candidate_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='organization_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + ] diff --git a/email_outbound/migrations/0009_emailcampaign_scheduled_send_time_and_more.py b/email_outbound/migrations/0009_emailcampaign_scheduled_send_time_and_more.py new file mode 100644 index 000000000..a4237f960 --- /dev/null +++ b/email_outbound/migrations/0009_emailcampaign_scheduled_send_time_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.13 on 2025-12-12 18:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0008_emailrecipienttemplate_emailrecipienttemplatefolder_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='emailcampaign', + name='scheduled_send_time', + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='email_address', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/email_outbound/migrations/0010_emailcampaign_from_email_and_more.py b/email_outbound/migrations/0010_emailcampaign_from_email_and_more.py new file mode 100644 index 000000000..f1685d1fe --- /dev/null +++ b/email_outbound/migrations/0010_emailcampaign_from_email_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.13 on 2026-01-08 20:45 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0009_emailcampaign_scheduled_send_time_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='emailcampaign', + name='from_email', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailcampaign', + name='from_email_name', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaign', + name='reply_to_email', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/email_outbound/migrations/0011_remove_emailcampaignrecipient_recipient_name_and_more.py b/email_outbound/migrations/0011_remove_emailcampaignrecipient_recipient_name_and_more.py new file mode 100644 index 000000000..dda61ce70 --- /dev/null +++ b/email_outbound/migrations/0011_remove_emailcampaignrecipient_recipient_name_and_more.py @@ -0,0 +1,152 @@ +# Generated by Django 5.0.13 on 2026-01-13 02:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0010_emailcampaign_from_email_and_more'), + ] + + operations = [ + migrations.RemoveField( + model_name='emailcampaignrecipient', + name='recipient_name', + ), + migrations.AddField( + model_name='emailcampaign', + name='scheduled_by_voter_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='list_unsubscribe_mailto', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='list_unsubscribe_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='manually_added', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='political_party', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_first_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_full_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_last_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_passkey', + field=models.CharField(max_length=25, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_seo_friendly_path', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='politician_state_code', + field=models.CharField(max_length=2, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='recipient_email_subscription_secret_key', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='recipient_email_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='recipient_first_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='recipient_full_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='recipient_last_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='recipient_voter_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='sender_email', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='sender_email_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='sender_first_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='sender_full_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='sender_last_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='sender_voter_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='supporters_count', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='emailscheduled', + name='email_campaign_id', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AddField( + model_name='emailscheduled', + name='email_campaign_recipient_id', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AlterField( + model_name='emailscheduled', + name='email_outbound_description_id', + field=models.PositiveIntegerField(default=None, null=True), + ), + ] diff --git a/email_outbound/migrations/0012_emailaudiencebuilder_emailaudiencebuilderfolder_and_more.py b/email_outbound/migrations/0012_emailaudiencebuilder_emailaudiencebuilderfolder_and_more.py new file mode 100644 index 000000000..9c9fa173b --- /dev/null +++ b/email_outbound/migrations/0012_emailaudiencebuilder_emailaudiencebuilderfolder_and_more.py @@ -0,0 +1,76 @@ +# Generated by Django 5.0.13 on 2026-01-18 15:32 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0011_remove_emailcampaignrecipient_recipient_name_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='EmailAudienceBuilder', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('archived', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ('has_email', models.BooleanField(default=None, null=True)), + ('has_no_email', models.BooleanField(default=None, null=True)), + ('has_no_sms', models.BooleanField(default=None, null=True)), + ('has_sms', models.BooleanField(default=None, null=True)), + ('include_candidates_from_prior_elections', models.BooleanField(default=None, null=True)), + ('is_candidate', models.BooleanField(default=None, null=True)), + ('is_organization', models.BooleanField(default=None, null=True)), + ('is_politician', models.BooleanField(default=None, null=True)), + ('is_voter', models.BooleanField(default=None, null=True)), + ('parent_template_operator', models.CharField(db_index=True, max_length=16, null=True)), + ('parent_audience_builder_id', models.PositiveIntegerField(default=0, null=True)), + ('audience_builder_folder_id', models.PositiveIntegerField(default=0, null=True)), + ('audience_builder_name', models.CharField(db_index=True, max_length=255, null=True)), + ('search_google_civic_election_id', models.PositiveIntegerField(default=0, null=True)), + ('search_term_candidate', models.CharField(max_length=255, null=True)), + ('search_term_organization', models.CharField(max_length=255, null=True)), + ('search_term_politician', models.CharField(max_length=255, null=True)), + ('search_term_political_party', models.CharField(max_length=255, null=True)), + ('search_term_state_code', models.CharField(max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='EmailAudienceBuilderFolder', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('audience_builder_name', models.CharField(db_index=True, max_length=255, null=True)), + ('archived', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='EmailAudienceBuilderLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email_campaign_id', models.PositiveIntegerField(default=0, null=True)), + ('audience_builder_id', models.PositiveIntegerField(default=0, null=True)), + ], + ), + migrations.DeleteModel( + name='EmailRecipientTemplate', + ), + migrations.DeleteModel( + name='EmailRecipientTemplateFolder', + ), + migrations.DeleteModel( + name='EmailRecipientTemplateLink', + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='office_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='office_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + ] diff --git a/email_outbound/migrations/0013_emailcampaignrecipient_open_tracking_code_and_more.py b/email_outbound/migrations/0013_emailcampaignrecipient_open_tracking_code_and_more.py new file mode 100644 index 000000000..e6377d6be --- /dev/null +++ b/email_outbound/migrations/0013_emailcampaignrecipient_open_tracking_code_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.13 on 2026-02-02 18:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0012_emailaudiencebuilder_emailaudiencebuilderfolder_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='emailcampaignrecipient', + name='open_tracking_code', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='open_tracking_count', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='open_tracking_first_open', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='emailcampaignrecipient', + name='open_tracking_last_open', + field=models.DateTimeField(null=True), + ), + ] diff --git a/email_outbound/migrations/0014_audiencebuilder_audiencefilter_audiencefilterchain_and_more.py b/email_outbound/migrations/0014_audiencebuilder_audiencefilter_audiencefilterchain_and_more.py new file mode 100644 index 000000000..5e7fe74b0 --- /dev/null +++ b/email_outbound/migrations/0014_audiencebuilder_audiencefilter_audiencefilterchain_and_more.py @@ -0,0 +1,118 @@ +# Generated by Django 5.0.13 on 2026-02-13 04:00 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0013_emailcampaignrecipient_open_tracking_code_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='AudienceBuilder', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('archived', models.BooleanField(default=False)), + ('audience_builder_folder_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_builder_name', models.CharField(db_index=True, max_length=255, null=True)), + ('audience_filter_chain1_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain2_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain3_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain4_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain5_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain6_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain7_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain8_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_chain9_id', models.PositiveIntegerField(default=None, null=True)), + ('chain1_to_chain2_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain2_to_chain3_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain3_to_chain4_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain4_to_chain5_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain5_to_chain6_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain6_to_chain7_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain7_to_chain8_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('chain8_to_chain9_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=8, null=True)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='AudienceFilter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('audience_builder_id', models.PositiveIntegerField(default=None, null=True)), + ('audience_filter_type', models.CharField(choices=[('AUDIENCE_TYPE_FILTER_TYPE', 'Audience type'), ('ELECTION_DATE_FILTER_TYPE', 'Election date'), ('EMAIL_ADDRESS_FILTER_TYPE', 'Email address'), ('HAS_BEEN_CONTACTED_FILTER_TYPE', 'Has been contacted'), ('HAS_CLAIMED_FILTER_TYPE', 'Has claimed profile'), ('HAS_BEEN_CONTACTED_FILTER_TYPE', 'Has opened'), ('HAS_SIGNED_IN_FILTER_TYPE', 'Has signed in'), ('PHONE_NUMBER_FILTER_TYPE', 'Phone number'), ('POLITICAL_PARTY_FILTER_TYPE', 'Political party'), ('STATE_CODE_FILTER_TYPE', 'State code')], default=None, max_length=50, null=True)), + ('audience_type_candidate', models.BooleanField(default=False)), + ('audience_type_organization', models.BooleanField(default=False)), + ('audience_type_politician', models.BooleanField(default=False)), + ('audience_type_voter', models.BooleanField(default=False)), + ('boolean_contact_contains', models.BooleanField(default=False)), + ('boolean_contact_exists', models.BooleanField(default=False)), + ('boolean_contact_is_missing', models.BooleanField(default=False)), + ('boolean_date_is_after', models.BooleanField(default=False)), + ('boolean_date_is_before', models.BooleanField(default=False)), + ('boolean_date_is_on', models.BooleanField(default=False)), + ('boolean_date_is_on_or_after', models.BooleanField(default=False)), + ('boolean_date_is_on_or_before', models.BooleanField(default=False)), + ('boolean_is', models.BooleanField(default=False)), + ('boolean_is_not', models.BooleanField(default=False)), + ('boolean_party_green', models.BooleanField(default=False)), + ('boolean_party_democrat', models.BooleanField(default=False)), + ('boolean_party_republican', models.BooleanField(default=False)), + ('boolean_party_independent', models.BooleanField(default=False)), + ('boolean_party_no_preference', models.BooleanField(default=False)), + ('boolean_party_working_families', models.BooleanField(default=False)), + ('boolean_relative_never', models.BooleanField(default=False)), + ('boolean_relative_at_least_once', models.BooleanField(default=False)), + ('boolean_relative_last_24_hours', models.BooleanField(default=False)), + ('boolean_relative_last_3_days', models.BooleanField(default=False)), + ('boolean_relative_last_week', models.BooleanField(default=False)), + ('boolean_relative_last_month', models.BooleanField(default=False)), + ('boolean_relative_last_year', models.BooleanField(default=False)), + ('google_civic_election_id', models.PositiveIntegerField(default=None, null=True)), + ('state_code_list', models.CharField(max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='AudienceFilterChain', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('audience_builder_id', models.PositiveIntegerField(default=None, null=True)), + ('chain_operator', models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default='AND', max_length=24)), + ('filter1_id', models.PositiveIntegerField(default=None, null=True)), + ('filter2_id', models.PositiveIntegerField(default=None, null=True)), + ('filter3_id', models.PositiveIntegerField(default=None, null=True)), + ('filter4_id', models.PositiveIntegerField(default=None, null=True)), + ('filter5_id', models.PositiveIntegerField(default=None, null=True)), + ('filter6_id', models.PositiveIntegerField(default=None, null=True)), + ('filter7_id', models.PositiveIntegerField(default=None, null=True)), + ('filter8_id', models.PositiveIntegerField(default=None, null=True)), + ('filter9_id', models.PositiveIntegerField(default=None, null=True)), + ('filter1_to_filter2_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter2_to_filter3_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter3_to_filter4_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter4_to_filter5_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter5_to_filter6_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter6_to_filter7_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter7_to_filter8_operator', models.CharField(default=None, max_length=16, null=True)), + ('filter8_to_filter9_operator', models.CharField(default=None, max_length=16, null=True)), + ], + ), + migrations.RenameModel( + old_name='EmailAudienceBuilderFolder', + new_name='AudienceBuilderFolder', + ), + migrations.RenameModel( + old_name='EmailAudienceBuilderLink', + new_name='AudienceBuilderLink', + ), + migrations.DeleteModel( + name='EmailAudienceBuilder', + ), + migrations.AlterField( + model_name='emailcampaignrecipient', + name='open_tracking_code', + field=models.CharField(db_index=True, default=None, max_length=255, null=True, unique=True), + ), + ] diff --git a/email_outbound/migrations/0015_alter_audiencefilterchain_filter1_to_filter2_operator_and_more.py b/email_outbound/migrations/0015_alter_audiencefilterchain_filter1_to_filter2_operator_and_more.py new file mode 100644 index 000000000..39753aec4 --- /dev/null +++ b/email_outbound/migrations/0015_alter_audiencefilterchain_filter1_to_filter2_operator_and_more.py @@ -0,0 +1,53 @@ +# Generated by Django 5.0.13 on 2026-02-17 13:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0014_audiencebuilder_audiencefilter_audiencefilterchain_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='audiencefilterchain', + name='filter1_to_filter2_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter2_to_filter3_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter3_to_filter4_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter4_to_filter5_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter5_to_filter6_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter6_to_filter7_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter7_to_filter8_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + migrations.AlterField( + model_name='audiencefilterchain', + name='filter8_to_filter9_operator', + field=models.CharField(choices=[('AND', 'AND'), ('EXCLUDE', 'EXCLUDE'), ('INCLUDE', 'INCLUDE'), ('OR', 'OR')], default=None, max_length=24, null=True), + ), + ] diff --git a/email_outbound/migrations/0016_remove_audiencefilter_boolean_contact_contains_and_more.py b/email_outbound/migrations/0016_remove_audiencefilter_boolean_contact_contains_and_more.py new file mode 100644 index 000000000..ae7ee56b9 --- /dev/null +++ b/email_outbound/migrations/0016_remove_audiencefilter_boolean_contact_contains_and_more.py @@ -0,0 +1,156 @@ +# Generated by Django 5.0.13 on 2026-02-23 21:01 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0015_alter_audiencefilterchain_filter1_to_filter2_operator_and_more'), + ] + + operations = [ + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_contact_contains', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_contact_exists', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_contact_is_missing', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_date_is_after', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_date_is_before', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_date_is_on', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_date_is_on_or_after', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_date_is_on_or_before', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_is', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_is_not', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_at_least_once', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_last_24_hours', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_last_3_days', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_last_month', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_last_week', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_last_year', + ), + migrations.RemoveField( + model_name='audiencefilter', + name='boolean_relative_never', + ), + migrations.AddField( + model_name='audiencefilter', + name='audience_type_modifier', + field=models.CharField(choices=[('AUDIENCE_TYPE_IS', 'is'), ('AUDIENCE_TYPE_IS_NOT', 'is not')], default=None, max_length=20, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='election_modifier', + field=models.CharField(choices=[('ELECTION_IS_AFTER', 'is after'), ('ELECTION_IS_BEFORE', 'is before'), ('ELECTION_IS_ON', 'is on'), ('ELECTION_IS_ON_OR_AFTER', 'is on or after'), ('ELECTION_IS_ON_OR_BEFORE', 'is on or before')], default=None, max_length=24, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='email_address_contains_list', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='email_address_modifier', + field=models.CharField(choices=[('EMAIL_ADDRESS_CONTAINS', 'contains'), ('EMAIL_ADDRESS_EXISTS', 'exists'), ('EMAIL_ADDRESS_IS_MISSING', 'is missing')], default=None, max_length=24, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='email_campaign_id_list', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='has_been_contacted_modifier', + field=models.CharField(choices=[('HAS_BEEN_CONTACTED_AT_LEAST_ONCE', 'at least once'), ('HAS_BEEN_CONTACTED_LAST_DAY', 'in last day'), ('HAS_BEEN_CONTACTED_LAST_3_DAYS', 'in last 3 days'), ('HAS_BEEN_CONTACTED_LAST_WEEK', 'in last week'), ('HAS_BEEN_CONTACTED_LAST_MONTH', 'in last month'), ('HAS_BEEN_CONTACTED_LAST_YEAR', 'in last year'), ('HAS_BEEN_CONTACTED_NEVER', 'never')], default=None, max_length=32, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='has_claimed_politician_modifier', + field=models.CharField(choices=[('HAS_CLAIMED_POLITICIAN_AT_LEAST_ONCE', 'at least once'), ('HAS_CLAIMED_POLITICIAN_LAST_DAY', 'in last day'), ('HAS_CLAIMED_POLITICIAN_LAST_3_DAYS', 'in last 3 days'), ('HAS_CLAIMED_POLITICIAN_LAST_WEEK', 'in last week'), ('HAS_CLAIMED_POLITICIAN_LAST_MONTH', 'in last month'), ('HAS_CLAIMED_POLITICIAN_LAST_YEAR', 'in last year'), ('HAS_CLAIMED_POLITICIAN_NEVER', 'never')], default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='has_opened_list', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='has_opened_modifier', + field=models.CharField(choices=[('HAS_OPENED_ANY', 'any'), ('HAS_OPENED_ALL', 'all'), ('HAS_NOT_OPENED_ANY', 'none'), ('HAS_NOT_OPENED_AT_LEAST_ONE', 'not all (missed at least one)')], default=None, max_length=27, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='has_signed_in_modifier', + field=models.CharField(choices=[('HAS_SIGNED_IN_AT_LEAST_ONCE', 'at least once'), ('HAS_SIGNED_IN_LAST_DAY', 'in last day'), ('HAS_SIGNED_IN_LAST_3_DAYS', 'in last 3 days'), ('HAS_SIGNED_IN_LAST_WEEK', 'in last week'), ('HAS_SIGNED_IN_LAST_MONTH', 'in last month'), ('HAS_SIGNED_IN_LAST_YEAR', 'in last year'), ('HAS_SIGNED_IN_NEVER', 'never')], default=None, max_length=30, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='phone_number_modifier', + field=models.CharField(choices=[('PHONE_NUMBER_CONTAINS', 'contains area code'), ('PHONE_NUMBER_EXISTS', 'exists'), ('PHONE_NUMBER_IS_MISSING', 'is missing')], default=None, max_length=23, null=True), + ), + migrations.AddField( + model_name='audiencefilter', + name='state_modifier', + field=models.CharField(choices=[('STATE_IS', 'is'), ('STATE_IS_NOT', 'is not')], default=None, max_length=12, null=True), + ), + migrations.AddField( + model_name='emailcampaign', + name='date_last_updated', + field=models.DateTimeField(auto_now=True, db_index=True), + ), + migrations.AlterField( + model_name='audiencefilter', + name='audience_filter_type', + field=models.CharField(choices=[('FILTER_TYPE_AUDIENCE_TYPE', 'Audience type'), ('FILTER_TYPE_ELECTION_DATE', 'Election date'), ('FILTER_TYPE_EMAIL_ADDRESS', 'Email address'), ('FILTER_TYPE_HAS_BEEN_CONTACTED', 'Has been contacted'), ('FILTER_TYPE_HAS_CLAIMED_POLITICIAN', 'Has claimed profile'), ('FILTER_TYPE_HAS_OPENED', 'Has opened'), ('FILTER_TYPE_HAS_SIGNED_IN', 'Has signed in'), ('FILTER_TYPE_PHONE_NUMBER', 'Phone number'), ('FILTER_TYPE_POLITICAL_PARTY', 'Political party'), ('FILTER_TYPE_STATE_CODE', 'State code')], default=None, max_length=50, null=True), + ), + migrations.AlterField( + model_name='audiencefilter', + name='state_code_list', + field=models.CharField(default=None, max_length=255, null=True), + ), + ] diff --git a/email_outbound/migrations/0017_emailcampaign_audience_builder_id.py b/email_outbound/migrations/0017_emailcampaign_audience_builder_id.py new file mode 100644 index 000000000..1d6f6c26f --- /dev/null +++ b/email_outbound/migrations/0017_emailcampaign_audience_builder_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2026-03-03 18:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('email_outbound', '0016_remove_audiencefilter_boolean_contact_contains_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='emailcampaign', + name='audience_builder_id', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/follow/migrations/0001_initial.py b/follow/migrations/0001_initial.py new file mode 100644 index 000000000..6dd85b57f --- /dev/null +++ b/follow/migrations/0001_initial.py @@ -0,0 +1,83 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='FollowCampaignX', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('campaignx_id', models.PositiveIntegerField(blank=True, null=True)), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='FollowIssue', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('issue_id', models.PositiveIntegerField(blank=True, null=True)), + ('issue_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('following_status', models.CharField(choices=[('FOLLOWING', 'Following'), ('STOP_FOLLOWING', 'Not Following'), ('FOLLOW_IGNORE', 'Ignoring'), ('STOP_IGNORING', 'Not Ignoring')], db_index=True, default='FOLLOWING', max_length=15)), + ('is_follow_visible_publicly', models.BooleanField(default=False, verbose_name='')), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='FollowIssueList', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ], + ), + migrations.CreateModel( + name='FollowOrganization', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_id', models.BigIntegerField(blank=True, db_index=True, null=True)), + ('organization_id', models.BigIntegerField(blank=True, db_index=True, null=True)), + ('voter_linked_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='organization we vote permanent id')), + ('organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('following_status', models.CharField(choices=[('FOLLOWING', 'Following'), ('STOP_FOLLOWING', 'Not Following'), ('FOLLOW_IGNORE', 'Ignoring'), ('STOP_IGNORING', 'Not Ignoring')], db_index=True, default='FOLLOWING', max_length=15)), + ('auto_followed_from_twitter_suggestion', models.BooleanField(default=False, verbose_name='')), + ('is_follow_visible_publicly', models.BooleanField(default=False, verbose_name='')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='FollowOrganizationList', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ], + ), + migrations.CreateModel( + name='SuggestedIssueToFollow', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('viewer_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter we vote id')), + ('issue_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='issue we vote id')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='SuggestedOrganizationToFollow', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('viewer_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter we vote id person 1')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization we vote id person 2')), + ('from_twitter', models.BooleanField(default=False, verbose_name='from twitter')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/follow/migrations/0002_alter_followissue_following_status_and_more.py b/follow/migrations/0002_alter_followissue_following_status_and_more.py new file mode 100644 index 000000000..89cdd9622 --- /dev/null +++ b/follow/migrations/0002_alter_followissue_following_status_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-08 01:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('follow', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='followissue', + name='following_status', + field=models.CharField(choices=[('FOLLOWING', 'Following'), ('STOP_FOLLOWING', 'Not Following'), ('FOLLOW_DISLIKE', 'Disliking'), ('STOP_DISLIKING', 'Not Disliking'), ('FOLLOW_IGNORE', 'Ignoring'), ('STOP_IGNORING', 'Not Ignoring')], db_index=True, default='FOLLOWING', max_length=15), + ), + migrations.AlterField( + model_name='followorganization', + name='following_status', + field=models.CharField(choices=[('FOLLOWING', 'Following'), ('STOP_FOLLOWING', 'Not Following'), ('FOLLOW_DISLIKE', 'Disliking'), ('STOP_DISLIKING', 'Not Disliking'), ('FOLLOW_IGNORE', 'Ignoring'), ('STOP_IGNORING', 'Not Ignoring')], db_index=True, default='FOLLOWING', max_length=15), + ), + ] diff --git a/follow/migrations/0003_alter_followcampaignx_campaignx_id_and_more.py b/follow/migrations/0003_alter_followcampaignx_campaignx_id_and_more.py new file mode 100644 index 000000000..4851ebd2b --- /dev/null +++ b/follow/migrations/0003_alter_followcampaignx_campaignx_id_and_more.py @@ -0,0 +1,58 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('follow', '0002_alter_followissue_following_status_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='followcampaignx', + name='campaignx_id', + field=models.PositiveIntegerField(blank=True, db_index=True, null=True), + ), + migrations.AlterField( + model_name='followcampaignx', + name='campaignx_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='followcampaignx', + name='organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='followissue', + name='issue_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='followissue', + name='organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='suggestedissuetofollow', + name='issue_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='issue we vote id'), + ), + migrations.AlterField( + model_name='suggestedissuetofollow', + name='viewer_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='voter we vote id'), + ), + migrations.AlterField( + model_name='suggestedorganizationtofollow', + name='organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='organization we vote id person 2'), + ), + migrations.AlterField( + model_name='suggestedorganizationtofollow', + name='viewer_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='voter we vote id person 1'), + ), + ] diff --git a/follow/migrations/0004_alter_followorganization_organization_we_vote_id_and_more.py b/follow/migrations/0004_alter_followorganization_organization_we_vote_id_and_more.py new file mode 100644 index 000000000..3843ac430 --- /dev/null +++ b/follow/migrations/0004_alter_followorganization_organization_we_vote_id_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-16 01:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('follow', '0003_alter_followcampaignx_campaignx_id_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='followorganization', + name='organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='followorganization', + name='voter_linked_organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + ] diff --git a/follow/migrations/0005_rename_voter_linked_organization_we_vote_id_followorganization_organization_we_vote_id_that_is_follo.py b/follow/migrations/0005_rename_voter_linked_organization_we_vote_id_followorganization_organization_we_vote_id_that_is_follo.py new file mode 100644 index 000000000..52579aa74 --- /dev/null +++ b/follow/migrations/0005_rename_voter_linked_organization_we_vote_id_followorganization_organization_we_vote_id_that_is_follo.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-20 17:27 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('follow', '0004_alter_followorganization_organization_we_vote_id_and_more'), + ] + + operations = [ + migrations.RenameField( + model_name='followorganization', + old_name='voter_linked_organization_we_vote_id', + new_name='organization_we_vote_id_that_is_following', + ), + ] diff --git a/friend/migrations/0001_initial.py b/friend/migrations/0001_initial.py new file mode 100644 index 000000000..0363b7aad --- /dev/null +++ b/friend/migrations/0001_initial.py @@ -0,0 +1,102 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='CurrentFriend', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('viewer_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='voter we vote id person 1')), + ('viewer_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('viewee_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='voter we vote id person 2')), + ('viewee_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='FriendInvitationEmailLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('sender_email_ownership_is_verified', models.BooleanField(default=False)), + ('recipient_email_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='email we vote id for recipient')), + ('recipient_voter_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='email address for recipient')), + ('recipient_first_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='first name')), + ('recipient_last_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='last name')), + ('secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to accept invite')), + ('invitation_message', models.TextField(blank=True, null=True)), + ('invitation_status', models.CharField(choices=[('PENDING_EMAIL_VERIFICATION', 'Pending verification of your email'), ('NO_RESPONSE', 'No response yet'), ('ACCEPTED', 'Invitation accepted'), ('IGNORED', 'Voter invited chose to ignore the invitation')], default='NO_RESPONSE', max_length=50)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('merge_by_secret_key_allowed', models.BooleanField(default=True)), + ('invitation_table', models.CharField(default='EMAIL', max_length=8)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='FriendInvitationFacebookLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('sender_facebook_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook user id of sender')), + ('recipient_facebook_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook user id of recipient')), + ('recipient_facebook_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='recipient facebook full name')), + ('facebook_request_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='facebook app request id')), + ('invitation_status', models.CharField(choices=[('PENDING_EMAIL_VERIFICATION', 'Pending verification of your email'), ('NO_RESPONSE', 'No response yet'), ('ACCEPTED', 'Invitation accepted'), ('IGNORED', 'Voter invited chose to ignore the invitation')], default='NO_RESPONSE', max_length=50)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('invitation_table', models.CharField(default='FACEBOOK', max_length=8)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='FriendInvitationTwitterLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('recipient_twitter_handle', models.CharField(max_length=255, verbose_name='twitter screen_name')), + ('secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to accept invite')), + ('invitation_message', models.TextField(blank=True, null=True)), + ('invitation_status', models.CharField(choices=[('PENDING_EMAIL_VERIFICATION', 'Pending verification of your email'), ('NO_RESPONSE', 'No response yet'), ('ACCEPTED', 'Invitation accepted'), ('IGNORED', 'Voter invited chose to ignore the invitation')], default='NO_RESPONSE', max_length=50)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('merge_by_secret_key_allowed', models.BooleanField(default=True)), + ('invitation_table', models.CharField(default='TWITTER', max_length=8)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='FriendInvitationVoterLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('sender_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('sender_email_ownership_is_verified', models.BooleanField(default=False)), + ('recipient_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the recipient if we have it')), + ('secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to accept invite')), + ('invitation_message', models.TextField(blank=True, null=True)), + ('invitation_status', models.CharField(choices=[('PENDING_EMAIL_VERIFICATION', 'Pending verification of your email'), ('NO_RESPONSE', 'No response yet'), ('ACCEPTED', 'Invitation accepted'), ('IGNORED', 'Voter invited chose to ignore the invitation')], default='NO_RESPONSE', max_length=50)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ('merge_by_secret_key_allowed', models.BooleanField(default=True)), + ('invitation_table', models.CharField(default='VOTER', max_length=8)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='SuggestedFriend', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('viewer_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter we vote id person 1')), + ('viewee_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter we vote id person 2')), + ('voter_we_vote_id_deleted_first', models.CharField(blank=True, max_length=255, null=True, verbose_name='first voter to remove suggested friend')), + ('voter_we_vote_id_deleted_second', models.CharField(blank=True, max_length=255, null=True, verbose_name='second voter to remove suggested friend')), + ('friend_invite_sent', models.BooleanField(default=False)), + ('current_friends', models.BooleanField(default=False)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/friend/migrations/0002_auto_20220619_0823.py b/friend/migrations/0002_auto_20220619_0823.py new file mode 100644 index 000000000..621b00869 --- /dev/null +++ b/friend/migrations/0002_auto_20220619_0823.py @@ -0,0 +1,69 @@ +# Generated by Django 3.2.13 on 2022-06-19 15:23 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('friend', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='MutualFriend', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('viewer_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='voter we vote id person 1')), + ('viewee_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='voter we vote id person 2')), + ('mutual_friend_voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('mutual_friend_display_name', models.CharField(blank=True, max_length=255, null=True)), + ('mutual_friend_display_name_exists', models.BooleanField(db_index=True, default=False)), + ('mutual_friend_we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('mutual_friend_profile_image_exists', models.BooleanField(db_index=True, default=False)), + ('viewer_to_mutual_friend_friend_count', models.PositiveSmallIntegerField(null=True)), + ('viewee_to_mutual_friend_friend_count', models.PositiveSmallIntegerField(null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True)), + ], + ), + migrations.AddField( + model_name='currentfriend', + name='mutual_friend_count', + field=models.PositiveSmallIntegerField(null=True), + ), + migrations.AddField( + model_name='currentfriend', + name='mutual_friend_count_last_updated', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='currentfriend', + name='mutual_friend_preview_list_serialized', + field=models.TextField(default=None, null=True), + ), + migrations.AddField( + model_name='currentfriend', + name='mutual_friend_preview_list_update_needed', + field=models.BooleanField(default=True), + ), + migrations.AddField( + model_name='suggestedfriend', + name='mutual_friend_count', + field=models.PositiveSmallIntegerField(null=True), + ), + migrations.AddField( + model_name='suggestedfriend', + name='mutual_friend_count_last_updated', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='suggestedfriend', + name='mutual_friend_preview_list_serialized', + field=models.TextField(default=None, null=True), + ), + migrations.AddField( + model_name='suggestedfriend', + name='mutual_friend_preview_list_update_needed', + field=models.BooleanField(default=True), + ), + ] diff --git a/friend/migrations/0003_auto_20220623_1210.py b/friend/migrations/0003_auto_20220623_1210.py new file mode 100644 index 000000000..bf68b9736 --- /dev/null +++ b/friend/migrations/0003_auto_20220623_1210.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.13 on 2022-06-23 19:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('friend', '0002_auto_20220619_0823'), + ] + + operations = [ + migrations.AddField( + model_name='friendinvitationvoterlink', + name='mutual_friend_count', + field=models.PositiveSmallIntegerField(null=True), + ), + migrations.AddField( + model_name='friendinvitationvoterlink', + name='mutual_friend_count_last_updated', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='friendinvitationvoterlink', + name='mutual_friend_preview_list_serialized', + field=models.TextField(default=None, null=True), + ), + migrations.AddField( + model_name='friendinvitationvoterlink', + name='mutual_friend_preview_list_update_needed', + field=models.BooleanField(default=True), + ), + ] diff --git a/friend/migrations/0004_auto_20220707_0808.py b/friend/migrations/0004_auto_20220707_0808.py new file mode 100644 index 000000000..2db4f31eb --- /dev/null +++ b/friend/migrations/0004_auto_20220707_0808.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.13 on 2022-07-07 15:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('friend', '0003_auto_20220623_1210'), + ] + + operations = [ + migrations.AddField( + model_name='friendinvitationemaillink', + name='invited_friend_accepted_notification_sent', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='friendinvitationvoterlink', + name='invited_friend_accepted_notification_sent', + field=models.BooleanField(default=False), + ), + ] diff --git a/friend/migrations/0005_alter_friendinvitationtwitterlink_recipient_twitter_handle.py b/friend/migrations/0005_alter_friendinvitationtwitterlink_recipient_twitter_handle.py new file mode 100644 index 000000000..eaa09417b --- /dev/null +++ b/friend/migrations/0005_alter_friendinvitationtwitterlink_recipient_twitter_handle.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2024-01-29 13:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('friend', '0004_auto_20220707_0808'), + ] + + operations = [ + migrations.AlterField( + model_name='friendinvitationtwitterlink', + name='recipient_twitter_handle', + field=models.CharField(max_length=255, verbose_name='twitter username'), + ), + ] diff --git a/friend/migrations/0006_alter_friendinvitationemaillink_recipient_email_we_vote_id_and_more.py b/friend/migrations/0006_alter_friendinvitationemaillink_recipient_email_we_vote_id_and_more.py new file mode 100644 index 000000000..2ad425473 --- /dev/null +++ b/friend/migrations/0006_alter_friendinvitationemaillink_recipient_email_we_vote_id_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('friend', '0005_alter_friendinvitationtwitterlink_recipient_twitter_handle'), + ] + + operations = [ + migrations.AlterField( + model_name='friendinvitationemaillink', + name='recipient_email_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='email we vote id for recipient'), + ), + migrations.AlterField( + model_name='friendinvitationemaillink', + name='secret_key', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True, verbose_name='secret key to accept invite'), + ), + migrations.AlterField( + model_name='friendinvitationemaillink', + name='sender_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender'), + ), + migrations.AlterField( + model_name='friendinvitationtwitterlink', + name='sender_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender'), + ), + ] diff --git a/friend/migrations/0007_currentfriend_curr_viewer_viewee_and_more.py b/friend/migrations/0007_currentfriend_curr_viewer_viewee_and_more.py new file mode 100644 index 000000000..d968518d3 --- /dev/null +++ b/friend/migrations/0007_currentfriend_curr_viewer_viewee_and_more.py @@ -0,0 +1,29 @@ +# Generated by Django 5.0.8 on 2024-09-02 15:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('friend', '0006_alter_friendinvitationemaillink_recipient_email_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='currentfriend', + index=models.Index(fields=['viewer_voter_we_vote_id', 'viewee_voter_we_vote_id'], name='curr_viewer_viewee'), + ), + migrations.AddIndex( + model_name='friendinvitationvoterlink', + index=models.Index(fields=['recipient_voter_we_vote_id', 'invitation_status', 'deleted'], name='recipient_index'), + ), + migrations.AddIndex( + model_name='friendinvitationvoterlink', + index=models.Index(fields=['sender_voter_we_vote_id', 'invitation_status', 'deleted'], name='sender_index'), + ), + migrations.AddIndex( + model_name='suggestedfriend', + index=models.Index(fields=['viewer_voter_we_vote_id', 'viewee_voter_we_vote_id'], name='sugg_viewer_viewee'), + ), + ] diff --git a/google_custom_search/migrations/0001_initial.py b/google_custom_search/migrations/0001_initial.py new file mode 100644 index 000000000..2c437da94 --- /dev/null +++ b/google_custom_search/migrations/0001_initial.py @@ -0,0 +1,54 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='GoogleSearchUser', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('candidate_campaign_we_vote_id', models.CharField(max_length=255, verbose_name='candidate we vote id')), + ('search_term_used', models.CharField(max_length=255, verbose_name='')), + ('item_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='searched item title')), + ('item_link', models.URLField(blank=True, null=True, verbose_name='url where searched item pointing')), + ('item_snippet', models.CharField(blank=True, max_length=1024, null=True, verbose_name='searched item snippet')), + ('item_image', models.URLField(blank=True, null=True, verbose_name='image url for searched item')), + ('item_formatted_url', models.URLField(blank=True, null=True, verbose_name='item formatted url')), + ('item_meta_tags_description', models.CharField(blank=True, max_length=1000, null=True, verbose_name='searched item meta tags description')), + ('search_request_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='search request url')), + ('from_ballotpedia', models.BooleanField(default=False, verbose_name='searched link from ballotpedia')), + ('from_facebook', models.BooleanField(default=False, verbose_name='searched link from facebook')), + ('from_linkedin', models.BooleanField(default=False, verbose_name='searched link from linkedin')), + ('from_twitter', models.BooleanField(default=False, verbose_name='searched link from twitter')), + ('from_wikipedia', models.BooleanField(default=False, verbose_name='searched link from wikipedia')), + ('not_a_match', models.BooleanField(default=False, verbose_name='this candidate does not match')), + ('likelihood_score', models.IntegerField(null=True, verbose_name='score for a match')), + ('chosen_and_updated', models.BooleanField(default=False, verbose_name='when search detail updated in candidate table')), + ('facebook_search_found', models.BooleanField(default=False, verbose_name='user found from facebook search')), + ('facebook_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name from facebook search')), + ('facebook_emails', models.CharField(blank=True, max_length=255, null=True, verbose_name='emails from facebook')), + ('facebook_about', models.CharField(blank=True, max_length=255, null=True, verbose_name='about from facebook')), + ('facebook_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='location from facebook')), + ('facebook_photos', models.CharField(blank=True, max_length=1024, null=True, verbose_name='photos from facebook')), + ('facebook_bio', models.CharField(blank=True, max_length=1024, null=True, verbose_name='bio from facebook')), + ('facebook_general_info', models.CharField(blank=True, max_length=1024, null=True, verbose_name='general information from facebook')), + ('facebook_description', models.CharField(blank=True, max_length=1024, null=True, verbose_name='description from facebook')), + ('facebook_features', models.CharField(blank=True, max_length=255, null=True, verbose_name='features from facebook')), + ('facebook_contact_address', models.CharField(blank=True, max_length=255, null=True, verbose_name='contact address from facebook')), + ('facebook_mission', models.CharField(blank=True, max_length=1024, null=True, verbose_name='mission from facebook')), + ('facebook_category', models.CharField(blank=True, max_length=255, null=True, verbose_name='category from facebook')), + ('facebook_website', models.URLField(blank=True, null=True, verbose_name='website from facebook')), + ('facebook_personal_info', models.CharField(blank=True, max_length=1024, null=True, verbose_name='personal information from facebook')), + ('facebook_personal_interests', models.CharField(blank=True, max_length=255, null=True, verbose_name='personal interests from facebook')), + ('facebook_posts', models.CharField(blank=True, max_length=1024, null=True, verbose_name='posts from facebook')), + ], + ), + ] diff --git a/google_custom_search/migrations/0002_auto_20240211_0925.py b/google_custom_search/migrations/0002_auto_20240211_0925.py new file mode 100644 index 000000000..a55b5423c --- /dev/null +++ b/google_custom_search/migrations/0002_auto_20240211_0925.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.23 on 2024-02-11 17:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('google_custom_search', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='googlesearchuser', + name='item_formatted_url', + field=models.TextField(blank=True, null=True, verbose_name='item formatted url'), + ), + migrations.AlterField( + model_name='googlesearchuser', + name='item_image', + field=models.TextField(blank=True, null=True, verbose_name='image url for searched item'), + ), + migrations.AlterField( + model_name='googlesearchuser', + name='item_link', + field=models.TextField(blank=True, null=True, verbose_name='url where searched item pointing'), + ), + migrations.AlterField( + model_name='googlesearchuser', + name='item_meta_tags_description', + field=models.TextField(blank=True, null=True, verbose_name='searched item meta tags description'), + ), + migrations.AlterField( + model_name='googlesearchuser', + name='item_snippet', + field=models.TextField(blank=True, null=True, verbose_name='searched item snippet'), + ), + migrations.AlterField( + model_name='googlesearchuser', + name='item_title', + field=models.TextField(blank=True, null=True, verbose_name='searched item title'), + ), + migrations.AlterField( + model_name='googlesearchuser', + name='search_request_url', + field=models.TextField(blank=True, null=True, verbose_name='search request url'), + ), + ] diff --git a/googlebot_site_map/migrations/0001_initial.py b/googlebot_site_map/migrations/0001_initial.py new file mode 100644 index 000000000..fd3dd6182 --- /dev/null +++ b/googlebot_site_map/migrations/0001_initial.py @@ -0,0 +1,26 @@ +# Generated by Django 3.2.23 on 2024-01-12 00:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='GooglebotRequest', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_requested', models.DateTimeField(auto_now_add=True, verbose_name='date requested')), + ('request_url_type', models.CharField(blank=True, max_length=255, null=True, verbose_name='Request URL end string')), + ('is_from_google', models.BooleanField(default=False, verbose_name="is remote address registered as Google's")), + ('remote_address', models.CharField(blank=True, max_length=255, null=True, verbose_name='Remote Address')), + ('remote_dns', models.CharField(blank=True, max_length=255, null=True, verbose_name='Remote reverse DNS')), + ('user_agent', models.TextField(blank=True, null=True)), + ], + ), + ] diff --git a/image/migrations/0001_initial.py b/image/migrations/0001_initial.py new file mode 100644 index 000000000..76ee6d90e --- /dev/null +++ b/image/migrations/0001_initial.py @@ -0,0 +1,84 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='WeVoteImage', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter we vote permanent id')), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('candidate_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate we vote permanent id')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization we vote permanent id')), + ('issue_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='issue we vote permanent id')), + ('google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('facebook_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook big integer id')), + ('facebook_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of profile image from facebook')), + ('facebook_background_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of background image from facebook')), + ('facebook_background_image_offset_x', models.IntegerField(blank=True, default=0, null=True, verbose_name='x offset of facebook cover image')), + ('facebook_background_image_offset_y', models.IntegerField(blank=True, default=0, null=True, verbose_name='y offset of facebook cover image')), + ('maplight_id', models.BigIntegerField(blank=True, null=True, verbose_name='maplight big integer id')), + ('maplight_image_url_https', models.TextField(blank=True, null=True, verbose_name='image url from maplight')), + ('vote_smart_id', models.BigIntegerField(blank=True, null=True, verbose_name='vote smart big integer id')), + ('vote_smart_image_url_https', models.TextField(blank=True, null=True, verbose_name='image url from vote smart')), + ('twitter_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter big integer id')), + ('twitter_profile_banner_url_https', models.TextField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('twitter_profile_background_image_url_https', models.TextField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('issue_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of issue image')), + ('ballotpedia_profile_image_url', models.TextField(blank=True, null=True, verbose_name='profile image from ballotpedia')), + ('campaignx_photo_url_https', models.TextField(blank=True, null=True)), + ('chosen_favicon_image_url_https', models.URLField(blank=True, null=True, verbose_name='org favicon image')), + ('chosen_logo_image_url_https', models.URLField(blank=True, null=True, verbose_name='org logo image')), + ('chosen_social_share_master_image_url_https', models.URLField(blank=True, null=True, verbose_name='org master share image')), + ('linkedin_profile_image_url', models.TextField(blank=True, null=True, verbose_name='profile image from linkedin')), + ('photo_url_from_ctcl', models.TextField(blank=True, null=True)), + ('photo_url_from_vote_usa', models.TextField(blank=True, null=True)), + ('voter_uploaded_profile_image_url_https', models.TextField(blank=True, null=True)), + ('wikipedia_profile_image_url', models.TextField(blank=True, null=True, verbose_name='profile image from wikipedia')), + ('other_source', models.TextField(blank=True, null=True, verbose_name='other source of image')), + ('other_source_image_url', models.TextField(blank=True, null=True, verbose_name='other source url of image')), + ('source_image_still_valid', models.BooleanField(default=False, verbose_name='is the url of source image still valid')), + ('image_height', models.BigIntegerField(blank=True, null=True, verbose_name='height of image in pixel')), + ('image_width', models.BigIntegerField(blank=True, null=True, verbose_name='width of image in pixel')), + ('we_vote_image_url', models.TextField(blank=True, null=True, verbose_name='url of image on AWS')), + ('we_vote_image_file_location', models.TextField(blank=True, null=True, verbose_name='image file path on AWS')), + ('we_vote_parent_image_id', models.BigIntegerField(blank=True, null=True, verbose_name='Local id of parent image')), + ('date_image_saved', models.DateTimeField(auto_now_add=True, verbose_name='date when image saved on wevote')), + ('same_day_image_version', models.BigIntegerField(blank=True, null=True, verbose_name='image version on same day')), + ('is_active_version', models.BooleanField(default=False, verbose_name='True if image is newest')), + ('kind_of_image_ballotpedia_profile', models.BooleanField(default=False, verbose_name='image is ballotpedia')), + ('kind_of_image_ctcl_profile', models.BooleanField(default=False)), + ('kind_of_image_campaignx_photo', models.BooleanField(default=False)), + ('kind_of_image_chosen_favicon', models.BooleanField(default=False, verbose_name='image is for favicon')), + ('kind_of_image_chosen_logo', models.BooleanField(default=False, verbose_name='image is for header')), + ('kind_of_image_chosen_social_share_master', models.BooleanField(default=False, verbose_name='image is for sharing')), + ('kind_of_image_facebook_profile', models.BooleanField(default=False, verbose_name='image is facebook profile')), + ('kind_of_image_facebook_background', models.BooleanField(default=False, verbose_name='image is facebook background')), + ('kind_of_image_issue', models.BooleanField(default=False, verbose_name='image is for issue')), + ('kind_of_image_linkedin_profile', models.BooleanField(default=False, verbose_name='image is linkedin')), + ('kind_of_image_maplight', models.BooleanField(default=False, verbose_name='image is maplight')), + ('kind_of_image_other_source', models.BooleanField(default=False, verbose_name='image is from other sources')), + ('kind_of_image_twitter_background', models.BooleanField(default=False, verbose_name='image is twitter background')), + ('kind_of_image_twitter_banner', models.BooleanField(default=False, verbose_name='image is twitter banner')), + ('kind_of_image_twitter_profile', models.BooleanField(default=False, verbose_name='image is twitter profile')), + ('kind_of_image_vote_smart', models.BooleanField(default=False, verbose_name='image is vote smart')), + ('kind_of_image_vote_usa_profile', models.BooleanField(default=False)), + ('kind_of_image_voter_uploaded_profile', models.BooleanField(default=False, verbose_name='image was uploaded')), + ('kind_of_image_wikipedia_profile', models.BooleanField(default=False, verbose_name='image is wikipedia')), + ('kind_of_image_original', models.BooleanField(default=False, verbose_name='is image size original')), + ('kind_of_image_large', models.BooleanField(default=False, verbose_name='is image size large')), + ('kind_of_image_medium', models.BooleanField(default=False, verbose_name='is image size medium')), + ('kind_of_image_tiny', models.BooleanField(default=False, verbose_name='is image size tiny')), + ], + ), + ] diff --git a/image/migrations/0002_wevoteimage_representative_we_vote_id.py b/image/migrations/0002_wevoteimage_representative_we_vote_id.py new file mode 100644 index 000000000..173aed8a3 --- /dev/null +++ b/image/migrations/0002_wevoteimage_representative_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.17 on 2023-02-08 22:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('image', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='wevoteimage', + name='representative_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/image/migrations/0003_wevoteimage_politician_we_vote_id.py b/image/migrations/0003_wevoteimage_politician_we_vote_id.py new file mode 100644 index 000000000..324976be8 --- /dev/null +++ b/image/migrations/0003_wevoteimage_politician_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.17 on 2023-02-11 15:33 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('image', '0002_wevoteimage_representative_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='wevoteimage', + name='politician_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/image/migrations/0004_auto_20230606_1749.py b/image/migrations/0004_auto_20230606_1749.py new file mode 100644 index 000000000..98b436827 --- /dev/null +++ b/image/migrations/0004_auto_20230606_1749.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-06-07 00:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('image', '0003_wevoteimage_politician_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='wevoteimage', + name='kind_of_image_politician_uploaded_profile', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='wevoteimage', + name='politician_uploaded_profile_image_url_https', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/image/migrations/0005_auto_20230806_1012.py b/image/migrations/0005_auto_20230806_1012.py new file mode 100644 index 000000000..bafb40820 --- /dev/null +++ b/image/migrations/0005_auto_20230806_1012.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.20 on 2023-08-06 17:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('image', '0004_auto_20230606_1749'), + ] + + operations = [ + migrations.AddField( + model_name='wevoteimage', + name='kind_of_image_organization_uploaded_profile', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='wevoteimage', + name='organization_uploaded_profile_image_url_https', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/image/migrations/0006_alter_wevoteimage_is_active_version_and_more.py b/image/migrations/0006_alter_wevoteimage_is_active_version_and_more.py new file mode 100644 index 000000000..77f24a274 --- /dev/null +++ b/image/migrations/0006_alter_wevoteimage_is_active_version_and_more.py @@ -0,0 +1,22 @@ +# Generated by Django 5.0.3 on 2024-07-16 17:45 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('image', '0005_auto_20230806_1012'), + ] + + operations = [ + migrations.AlterField( + model_name='wevoteimage', + name='is_active_version', + field=models.BooleanField(db_index=True, default=False, verbose_name='True if image is newest'), + ), + migrations.AddIndex( + model_name='wevoteimage', + index=models.Index(fields=['campaignx_we_vote_id', 'candidate_we_vote_id', 'organization_we_vote_id', 'politician_we_vote_id', 'representative_we_vote_id', 'issue_we_vote_id', 'voter_we_vote_id'], name='image_we_vote_ids_index'), + ), + ] diff --git a/image/migrations/0007_alter_wevoteimage_is_active_version_and_more.py b/image/migrations/0007_alter_wevoteimage_is_active_version_and_more.py new file mode 100644 index 000000000..08399935e --- /dev/null +++ b/image/migrations/0007_alter_wevoteimage_is_active_version_and_more.py @@ -0,0 +1,26 @@ +# Generated by Django 5.0.3 on 2024-07-16 20:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('image', '0006_alter_wevoteimage_is_active_version_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='wevoteimage', + name='is_active_version', + field=models.BooleanField(default=False, verbose_name='True if image is newest'), + ), + migrations.AddIndex( + model_name='wevoteimage', + index=models.Index(fields=['candidate_we_vote_id', '-date_image_saved'], name='candidate_index'), + ), + migrations.AddIndex( + model_name='wevoteimage', + index=models.Index(fields=['is_active_version'], name='is_active_version'), + ), + ] diff --git a/import_export_ballotpedia/migrations/0001_initial.py b/import_export_ballotpedia/migrations/0001_initial.py new file mode 100644 index 000000000..57253d180 --- /dev/null +++ b/import_export_ballotpedia/migrations/0001_initial.py @@ -0,0 +1,56 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BallotpediaApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to ballotpedia')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('ballotpedia_election_id', models.PositiveIntegerField(null=True, verbose_name='ballotpedia election id')), + ], + ), + migrations.CreateModel( + name='BallotpediaApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to ballotpedia')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('ballotpedia_election_id', models.PositiveIntegerField(null=True, verbose_name='ballotpedia election id')), + ], + ), + migrations.CreateModel( + name='BallotpediaApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to ballotpedia')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('ballotpedia_election_id', models.PositiveIntegerField(null=True, verbose_name='ballotpedia election id')), + ], + ), + migrations.CreateModel( + name='BallotpediaApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to ballotpedia')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('ballotpedia_election_id', models.PositiveIntegerField(null=True, verbose_name='ballotpedia election id')), + ], + ), + ] diff --git a/import_export_batches/migrations/0001_initial.py b/import_export_batches/migrations/0001_initial.py new file mode 100644 index 000000000..4933acb61 --- /dev/null +++ b/import_export_batches/migrations/0001_initial.py @@ -0,0 +1,743 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +import django.core.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BatchDescription', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, unique=True, verbose_name='unique id of header row')), + ('batch_set_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='unique id of batch set row')), + ('batch_header_map_id', models.PositiveIntegerField(unique=True, verbose_name='unique id of header map')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, db_index=True, default=0, null=True, verbose_name='google civic election id')), + ('batch_name', models.CharField(max_length=255)), + ('kind_of_batch', models.CharField(choices=[('MEASURE', 'Measure'), ('ELECTED_OFFICE', 'ElectedOffice'), ('CONTEST_OFFICE', 'ContestOffice'), ('CANDIDATE', 'Candidate'), ('IMPORT_BALLOT_ITEM', 'Ballot Returned'), ('IMPORT_POLLING_LOCATION', 'Map Point'), ('ORGANIZATION', 'Organization'), ('POSITION', 'Position'), ('POLITICIAN', 'Politician')], db_index=True, default='MEASURE', max_length=32)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name="if for positions, the organization's we vote id")), + ('polling_location_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='if for ballot items, the map point we vote id')), + ('voter_id', models.IntegerField(blank=True, null=True)), + ('batch_description_text', models.CharField(max_length=255)), + ('batch_description_analyzed', models.BooleanField(db_index=True, default=False)), + ('source_uri', models.URLField(blank=True, max_length=255, null=True, verbose_name='uri where data is coming from')), + ('date_created', models.DateTimeField(auto_now=True, null=True, verbose_name='date first saved')), + ], + ), + migrations.CreateModel( + name='BatchHeader', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_header_column_000', models.TextField(blank=True, null=True)), + ('batch_header_column_001', models.TextField(blank=True, null=True)), + ('batch_header_column_002', models.TextField(blank=True, null=True)), + ('batch_header_column_003', models.TextField(blank=True, null=True)), + ('batch_header_column_004', models.TextField(blank=True, null=True)), + ('batch_header_column_005', models.TextField(blank=True, null=True)), + ('batch_header_column_006', models.TextField(blank=True, null=True)), + ('batch_header_column_007', models.TextField(blank=True, null=True)), + ('batch_header_column_008', models.TextField(blank=True, null=True)), + ('batch_header_column_009', models.TextField(blank=True, null=True)), + ('batch_header_column_010', models.TextField(blank=True, null=True)), + ('batch_header_column_011', models.TextField(blank=True, null=True)), + ('batch_header_column_012', models.TextField(blank=True, null=True)), + ('batch_header_column_013', models.TextField(blank=True, null=True)), + ('batch_header_column_014', models.TextField(blank=True, null=True)), + ('batch_header_column_015', models.TextField(blank=True, null=True)), + ('batch_header_column_016', models.TextField(blank=True, null=True)), + ('batch_header_column_017', models.TextField(blank=True, null=True)), + ('batch_header_column_018', models.TextField(blank=True, null=True)), + ('batch_header_column_019', models.TextField(blank=True, null=True)), + ('batch_header_column_020', models.TextField(blank=True, null=True)), + ('batch_header_column_021', models.TextField(blank=True, null=True)), + ('batch_header_column_022', models.TextField(blank=True, null=True)), + ('batch_header_column_023', models.TextField(blank=True, null=True)), + ('batch_header_column_024', models.TextField(blank=True, null=True)), + ('batch_header_column_025', models.TextField(blank=True, null=True)), + ('batch_header_column_026', models.TextField(blank=True, null=True)), + ('batch_header_column_027', models.TextField(blank=True, null=True)), + ('batch_header_column_028', models.TextField(blank=True, null=True)), + ('batch_header_column_029', models.TextField(blank=True, null=True)), + ('batch_header_column_030', models.TextField(blank=True, null=True)), + ('batch_header_column_031', models.TextField(blank=True, null=True)), + ('batch_header_column_032', models.TextField(blank=True, null=True)), + ('batch_header_column_033', models.TextField(blank=True, null=True)), + ('batch_header_column_034', models.TextField(blank=True, null=True)), + ('batch_header_column_035', models.TextField(blank=True, null=True)), + ('batch_header_column_036', models.TextField(blank=True, null=True)), + ('batch_header_column_037', models.TextField(blank=True, null=True)), + ('batch_header_column_038', models.TextField(blank=True, null=True)), + ('batch_header_column_039', models.TextField(blank=True, null=True)), + ('batch_header_column_040', models.TextField(blank=True, null=True)), + ('batch_header_column_041', models.TextField(blank=True, null=True)), + ('batch_header_column_042', models.TextField(blank=True, null=True)), + ('batch_header_column_043', models.TextField(blank=True, null=True)), + ('batch_header_column_044', models.TextField(blank=True, null=True)), + ('batch_header_column_045', models.TextField(blank=True, null=True)), + ('batch_header_column_046', models.TextField(blank=True, null=True)), + ('batch_header_column_047', models.TextField(blank=True, null=True)), + ('batch_header_column_048', models.TextField(blank=True, null=True)), + ('batch_header_column_049', models.TextField(blank=True, null=True)), + ('batch_header_column_050', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='BatchHeaderMap', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, unique=True, verbose_name='unique id of header row')), + ('batch_header_map_000', models.TextField(blank=True, null=True)), + ('batch_header_map_001', models.TextField(blank=True, null=True)), + ('batch_header_map_002', models.TextField(blank=True, null=True)), + ('batch_header_map_003', models.TextField(blank=True, null=True)), + ('batch_header_map_004', models.TextField(blank=True, null=True)), + ('batch_header_map_005', models.TextField(blank=True, null=True)), + ('batch_header_map_006', models.TextField(blank=True, null=True)), + ('batch_header_map_007', models.TextField(blank=True, null=True)), + ('batch_header_map_008', models.TextField(blank=True, null=True)), + ('batch_header_map_009', models.TextField(blank=True, null=True)), + ('batch_header_map_010', models.TextField(blank=True, null=True)), + ('batch_header_map_011', models.TextField(blank=True, null=True)), + ('batch_header_map_012', models.TextField(blank=True, null=True)), + ('batch_header_map_013', models.TextField(blank=True, null=True)), + ('batch_header_map_014', models.TextField(blank=True, null=True)), + ('batch_header_map_015', models.TextField(blank=True, null=True)), + ('batch_header_map_016', models.TextField(blank=True, null=True)), + ('batch_header_map_017', models.TextField(blank=True, null=True)), + ('batch_header_map_018', models.TextField(blank=True, null=True)), + ('batch_header_map_019', models.TextField(blank=True, null=True)), + ('batch_header_map_020', models.TextField(blank=True, null=True)), + ('batch_header_map_021', models.TextField(blank=True, null=True)), + ('batch_header_map_022', models.TextField(blank=True, null=True)), + ('batch_header_map_023', models.TextField(blank=True, null=True)), + ('batch_header_map_024', models.TextField(blank=True, null=True)), + ('batch_header_map_025', models.TextField(blank=True, null=True)), + ('batch_header_map_026', models.TextField(blank=True, null=True)), + ('batch_header_map_027', models.TextField(blank=True, null=True)), + ('batch_header_map_028', models.TextField(blank=True, null=True)), + ('batch_header_map_029', models.TextField(blank=True, null=True)), + ('batch_header_map_030', models.TextField(blank=True, null=True)), + ('batch_header_map_031', models.TextField(blank=True, null=True)), + ('batch_header_map_032', models.TextField(blank=True, null=True)), + ('batch_header_map_033', models.TextField(blank=True, null=True)), + ('batch_header_map_034', models.TextField(blank=True, null=True)), + ('batch_header_map_035', models.TextField(blank=True, null=True)), + ('batch_header_map_036', models.TextField(blank=True, null=True)), + ('batch_header_map_037', models.TextField(blank=True, null=True)), + ('batch_header_map_038', models.TextField(blank=True, null=True)), + ('batch_header_map_039', models.TextField(blank=True, null=True)), + ('batch_header_map_040', models.TextField(blank=True, null=True)), + ('batch_header_map_041', models.TextField(blank=True, null=True)), + ('batch_header_map_042', models.TextField(blank=True, null=True)), + ('batch_header_map_043', models.TextField(blank=True, null=True)), + ('batch_header_map_044', models.TextField(blank=True, null=True)), + ('batch_header_map_045', models.TextField(blank=True, null=True)), + ('batch_header_map_046', models.TextField(blank=True, null=True)), + ('batch_header_map_047', models.TextField(blank=True, null=True)), + ('batch_header_map_048', models.TextField(blank=True, null=True)), + ('batch_header_map_049', models.TextField(blank=True, null=True)), + ('batch_header_map_050', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='BatchHeaderTranslationSuggestion', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('kind_of_batch', models.CharField(choices=[('MEASURE', 'Measure'), ('ELECTED_OFFICE', 'ElectedOffice'), ('CONTEST_OFFICE', 'ContestOffice'), ('CANDIDATE', 'Candidate'), ('IMPORT_BALLOT_ITEM', 'Ballot Returned'), ('IMPORT_POLLING_LOCATION', 'Map Point'), ('ORGANIZATION', 'Organization'), ('POSITION', 'Position'), ('POLITICIAN', 'Politician')], default='MEASURE', max_length=32)), + ('header_value_recognized_by_we_vote', models.TextField(blank=True, null=True)), + ('incoming_alternate_header_value', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='BatchProcess', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('kind_of_process', models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50)), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=0, verbose_name='google civic election id')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='state the ballot item is related to')), + ('analytics_date_as_integer', models.PositiveIntegerField(blank=True, null=True)), + ('voter_id', models.IntegerField(blank=True, null=True, verbose_name='the voter unique id')), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('api_name', models.CharField(max_length=255, null=True)), + ('election_id_list_serialized', models.CharField(max_length=255, null=True)), + ('date_added_to_queue', models.DateTimeField(null=True, verbose_name='start')), + ('date_started', models.DateTimeField(null=True, verbose_name='start')), + ('date_completed', models.DateTimeField(null=True, verbose_name='finished')), + ('date_checked_out', models.DateTimeField(null=True)), + ('batch_process_paused', models.BooleanField(default=False)), + ('completion_summary', models.TextField(blank=True, null=True)), + ('use_ballotpedia', models.BooleanField(default=False)), + ('use_ctcl', models.BooleanField(default=False)), + ('use_vote_usa', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='BatchProcessAnalyticsChunk', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, default=0)), + ('date_started', models.DateTimeField(default=None, null=True)), + ('timed_out', models.BooleanField(default=None, null=True)), + ('date_completed', models.DateTimeField(default=None, null=True)), + ('number_of_rows_being_reviewed', models.PositiveIntegerField(default=0, null=True)), + ('number_of_rows_successfully_reviewed', models.PositiveIntegerField(default=0, null=True)), + ], + ), + migrations.CreateModel( + name='BatchProcessBallotItemChunk', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, default=0)), + ('batch_set_id', models.PositiveIntegerField(db_index=True, default=0)), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=0)), + ('state_code', models.CharField(max_length=2, null=True)), + ('retrieve_date_started', models.DateTimeField(null=True)), + ('retrieve_date_completed', models.DateTimeField(null=True)), + ('retrieve_timed_out', models.BooleanField(default=None, null=True)), + ('retrieve_row_count', models.PositiveIntegerField(default=0)), + ('analyze_date_started', models.DateTimeField(null=True)), + ('analyze_date_completed', models.DateTimeField(null=True)), + ('analyze_timed_out', models.BooleanField(default=None, null=True)), + ('analyze_row_count', models.PositiveIntegerField(default=0)), + ('create_date_started', models.DateTimeField(null=True)), + ('create_date_completed', models.DateTimeField(null=True)), + ('create_timed_out', models.BooleanField(default=None, null=True)), + ('create_row_count', models.PositiveIntegerField(default=0)), + ], + ), + migrations.CreateModel( + name='BatchProcessLogEntry', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, default=0)), + ('batch_process_ballot_item_chunk_id', models.PositiveIntegerField(db_index=True, default=0)), + ('batch_set_id', models.PositiveIntegerField(db_index=True, default=0)), + ('google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='state the ballot item is related to')), + ('voter_id', models.IntegerField(blank=True, null=True, verbose_name='the voter unique id')), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('critical_failure', models.BooleanField(default=None, null=True)), + ('date_added', models.DateTimeField(auto_now_add=True, null=True)), + ('kind_of_process', models.CharField(default='', max_length=50)), + ('analytics_date_as_integer', models.PositiveIntegerField(default=None, null=True)), + ('status', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='BatchRow', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, db_index=True, default=0, null=True, verbose_name='election id')), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True)), + ('voter_id', models.IntegerField(blank=True, null=True)), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='state code for this data')), + ('batch_row_analyzed', models.BooleanField(db_index=True, default=False)), + ('batch_row_created', models.BooleanField(db_index=True, default=False)), + ('batch_row_000', models.TextField(blank=True, null=True)), + ('batch_row_001', models.TextField(blank=True, null=True)), + ('batch_row_002', models.TextField(blank=True, null=True)), + ('batch_row_003', models.TextField(blank=True, null=True)), + ('batch_row_004', models.TextField(blank=True, null=True)), + ('batch_row_005', models.TextField(blank=True, null=True)), + ('batch_row_006', models.TextField(blank=True, null=True)), + ('batch_row_007', models.TextField(blank=True, null=True)), + ('batch_row_008', models.TextField(blank=True, null=True)), + ('batch_row_009', models.TextField(blank=True, null=True)), + ('batch_row_010', models.TextField(blank=True, null=True)), + ('batch_row_011', models.TextField(blank=True, null=True)), + ('batch_row_012', models.TextField(blank=True, null=True)), + ('batch_row_013', models.TextField(blank=True, null=True)), + ('batch_row_014', models.TextField(blank=True, null=True)), + ('batch_row_015', models.TextField(blank=True, null=True)), + ('batch_row_016', models.TextField(blank=True, null=True)), + ('batch_row_017', models.TextField(blank=True, null=True)), + ('batch_row_018', models.TextField(blank=True, null=True)), + ('batch_row_019', models.TextField(blank=True, null=True)), + ('batch_row_020', models.TextField(blank=True, null=True)), + ('batch_row_021', models.TextField(blank=True, null=True)), + ('batch_row_022', models.TextField(blank=True, null=True)), + ('batch_row_023', models.TextField(blank=True, null=True)), + ('batch_row_024', models.TextField(blank=True, null=True)), + ('batch_row_025', models.TextField(blank=True, null=True)), + ('batch_row_026', models.TextField(blank=True, null=True)), + ('batch_row_027', models.TextField(blank=True, null=True)), + ('batch_row_028', models.TextField(blank=True, null=True)), + ('batch_row_029', models.TextField(blank=True, null=True)), + ('batch_row_030', models.TextField(blank=True, null=True)), + ('batch_row_031', models.TextField(blank=True, null=True)), + ('batch_row_032', models.TextField(blank=True, null=True)), + ('batch_row_033', models.TextField(blank=True, null=True)), + ('batch_row_034', models.TextField(blank=True, null=True)), + ('batch_row_035', models.TextField(blank=True, null=True)), + ('batch_row_036', models.TextField(blank=True, null=True)), + ('batch_row_037', models.TextField(blank=True, null=True)), + ('batch_row_038', models.TextField(blank=True, null=True)), + ('batch_row_039', models.TextField(blank=True, null=True)), + ('batch_row_040', models.TextField(blank=True, null=True)), + ('batch_row_041', models.TextField(blank=True, null=True)), + ('batch_row_042', models.TextField(blank=True, null=True)), + ('batch_row_043', models.TextField(blank=True, null=True)), + ('batch_row_044', models.TextField(blank=True, null=True)), + ('batch_row_045', models.TextField(blank=True, null=True)), + ('batch_row_046', models.TextField(blank=True, null=True)), + ('batch_row_047', models.TextField(blank=True, null=True)), + ('batch_row_048', models.TextField(blank=True, null=True)), + ('batch_row_049', models.TextField(blank=True, null=True)), + ('batch_row_050', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='BatchRowActionBallotItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, default=None, null=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('ballot_item_id', models.PositiveIntegerField(db_index=True, default=None, null=True, verbose_name='ballot item unique id')), + ('voter_id', models.IntegerField(default=0, verbose_name='the voter unique id')), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('google_civic_election_id', models.CharField(db_index=True, max_length=20, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='state the ballot item is related to')), + ('google_ballot_placement', models.BigIntegerField(blank=True, null=True, verbose_name='the order this item should appear on the ballot')), + ('local_ballot_order', models.IntegerField(blank=True, null=True, verbose_name='locally calculated order this item should appear on the ballot')), + ('contest_office_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='local id for this contest office')), + ('contest_office_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this office')), + ('contest_measure_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='contest_measure unique id')), + ('contest_measure_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this measure')), + ('ballot_item_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='a label we can sort by')), + ('measure_subtitle', models.TextField(blank=True, default='', null=True, verbose_name='google civic referendum subtitle')), + ('measure_text', models.TextField(blank=True, default='', null=True, verbose_name='measure text')), + ('measure_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of measure')), + ('yes_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a yes vote means')), + ('no_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a no vote means')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action ballot item status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionCandidate', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('candidate_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of this candidate')), + ('maplight_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='maplight candidate id')), + ('vote_smart_id', models.CharField(blank=True, default=None, max_length=15, null=True, verbose_name='vote smart candidate id')), + ('vote_usa_office_id', models.CharField(blank=True, default=None, max_length=64, null=True)), + ('vote_usa_politician_id', models.CharField(blank=True, default=None, max_length=64, null=True)), + ('vote_usa_profile_image_url_https', models.TextField(blank=True, default=None, null=True)), + ('contest_office_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='contest_office_id id')), + ('contest_office_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for the office this candidate is running for')), + ('contest_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the office')), + ('politician_id', models.BigIntegerField(blank=True, null=True, verbose_name='politician unique identifier')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote politician id')), + ('candidate_name', models.CharField(max_length=255, verbose_name='candidate name')), + ('google_civic_candidate_name', models.CharField(max_length=255, verbose_name='candidate name exactly as received from google civic')), + ('candidate_gender', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate gender')), + ('birth_day_text', models.CharField(blank=True, max_length=10, null=True, verbose_name='birth day')), + ('party', models.CharField(blank=True, max_length=255, null=True, verbose_name='party')), + ('photo_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='photoUrl')), + ('photo_url_from_ctcl', models.TextField(blank=True, default=None, null=True)), + ('photo_url_from_maplight', models.URLField(blank=True, max_length=255, null=True, verbose_name='candidate portrait url of candidate from maplight')), + ('photo_url_from_vote_smart', models.URLField(blank=True, max_length=255, null=True, verbose_name='candidate portrait url of candidate from vote smart')), + ('photo_url_from_vote_usa', models.TextField(blank=True, default=None, null=True)), + ('order_on_ballot', models.CharField(blank=True, max_length=255, null=True, verbose_name='order on ballot')), + ('google_civic_election_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this candidate serves')), + ('candidate_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of candidate')), + ('candidate_contact_form_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of candidate contact form')), + ('facebook_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='facebook url of candidate')), + ('twitter_url', models.URLField(blank=True, null=True, verbose_name='twitter url of candidate')), + ('twitter_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter id')), + ('candidate_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='candidate twitter screen_name')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='org name from twitter')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='org location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('twitter_profile_background_image_url_https', models.URLField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_banner_url_https', models.URLField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('google_plus_url', models.URLField(blank=True, null=True, verbose_name='google plus url of candidate')), + ('youtube_url', models.URLField(blank=True, null=True, verbose_name='youtube url of candidate')), + ('candidate_email', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate email')), + ('candidate_phone', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate phone')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of wikipedia logo')), + ('ballotpedia_candidate_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia integer id')), + ('ballotpedia_candidate_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate name exactly as received from ballotpedia')), + ('ballotpedia_candidate_summary', models.TextField(blank=True, default=None, null=True, verbose_name='candidate summary from ballotpedia')), + ('ballotpedia_candidate_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of candidate on ballotpedia')), + ('ballotpedia_election_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia election id')), + ('ballotpedia_image_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia image id')), + ('ballotpedia_office_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia elected office integer id')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_person_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia person integer id')), + ('ballotpedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of ballotpedia logo')), + ('ballotpedia_race_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia race integer id')), + ('ballot_guide_official_statement', models.TextField(blank=True, default='', null=True, verbose_name='official candidate statement from ballot guide')), + ('batch_row_action_office_ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('crowdpac_candidate_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='crowdpac integer id')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('candidate_is_top_ticket', models.BooleanField(default=False, verbose_name='candidate is top ticket')), + ('candidate_is_incumbent', models.BooleanField(default=False, verbose_name='candidate is currently in the office')), + ('candidate_participation_status', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate participation status')), + ('candidate_ctcl_person_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate person id')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action candidate status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionContestOffice', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('contest_office_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this contest office')), + ('contest_office_name', models.CharField(max_length=255, verbose_name='name of the contest office')), + ('google_civic_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_election_id', models.CharField(db_index=True, max_length=255, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('maplight_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='maplight unique identifier')), + ('ballotpedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia unique identifier')), + ('ballotpedia_district_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia district id')), + ('ballotpedia_election_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia election id')), + ('ballotpedia_is_marquee', models.BooleanField(default=None, null=True)), + ('is_ballotpedia_general_election', models.BooleanField(default=False)), + ('is_ballotpedia_general_runoff_election', models.BooleanField(default=False)), + ('is_ballotpedia_primary_election', models.BooleanField(default=False)), + ('is_ballotpedia_primary_runoff_election', models.BooleanField(default=False)), + ('ballotpedia_office_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia integer id')), + ('ballotpedia_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='office name exactly as received from ballotpedia')), + ('ballotpedia_office_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of office on ballotpedia')), + ('ballotpedia_race_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia race integer id')), + ('ballotpedia_race_office_level', models.CharField(blank=True, max_length=255, null=True, verbose_name='race office level')), + ('wikipedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='wikipedia unique identifier')), + ('number_voting_for', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates to vote for')), + ('number_elected', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates who will be elected')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this office serves')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('district_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='district name')), + ('district_scope', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('contest_level0', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 0')), + ('contest_level1', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 1')), + ('contest_level2', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 2')), + ('electorate_specifications', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('special', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('elected_office_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the elected office')), + ('candidate_selection_id1', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 1')), + ('candidate_selection_id2', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 2')), + ('candidate_selection_id3', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 3')), + ('candidate_selection_id4', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 4')), + ('candidate_selection_id5', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 5')), + ('candidate_selection_id6', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 6')), + ('candidate_selection_id7', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 7')), + ('candidate_selection_id8', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 8')), + ('candidate_selection_id9', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 9')), + ('candidate_selection_id10', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='temporary id of candidate selection 10')), + ('vote_usa_office_id', models.CharField(blank=True, default=None, max_length=64, null=True, verbose_name='Vote USA permanent id for this candidate')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action contest office status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionElectedOffice', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('elected_office_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this elected office')), + ('elected_office_name', models.CharField(max_length=255, verbose_name='name of the elected office')), + ('elected_office_name_es', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the elected office in Spanish')), + ('google_civic_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_election_id', models.CharField(db_index=True, max_length=255, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('maplight_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='maplight unique identifier')), + ('ballotpedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia unique identifier')), + ('wikipedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='wikipedia unique identifier')), + ('number_elected', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates who will be elected')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this office serves')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('district_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='district name')), + ('district_scope', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('contest_level0', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 0')), + ('contest_level1', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 1')), + ('contest_level2', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 2')), + ('electorate_specifications', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('special', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('elected_office_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='office description')), + ('elected_office_description_es', models.CharField(blank=True, max_length=255, null=True, verbose_name='office description spanish')), + ('elected_office_is_partisan', models.BooleanField(default=False, verbose_name='office is_partisan')), + ('elected_office_ctcl_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this elected office')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action elected office status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionMeasure', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, unique=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('measure_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id')), + ('maplight_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='maplight unique identifier')), + ('vote_smart_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='votesmart unique identifier')), + ('measure_title', models.CharField(max_length=255, verbose_name='measure title')), + ('google_civic_measure_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure name exactly as received from google civic')), + ('measure_subtitle', models.TextField(blank=True, default='', null=True, verbose_name='google civic referendum subtitle')), + ('measure_text', models.TextField(null=True, verbose_name='measure text')), + ('measure_url', models.CharField(max_length=255, null=True, verbose_name='measure details url')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=0, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='primary party')), + ('district_name', models.CharField(max_length=255, verbose_name='district name')), + ('district_scope', models.CharField(max_length=255, verbose_name='district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this measure affects')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of wikipedia logo')), + ('ballotpedia_district_id', models.PositiveIntegerField(default=0, verbose_name='ballotpedia district id')), + ('ballotpedia_election_id', models.PositiveIntegerField(default=0, verbose_name='ballotpedia election id')), + ('ballotpedia_measure_id', models.PositiveIntegerField(default=0, verbose_name='ballotpedia measure id')), + ('ballotpedia_measure_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia measure name')), + ('ballotpedia_measure_status', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia measure status')), + ('ballotpedia_measure_summary', models.TextField(blank=True, default='', null=True, verbose_name='ballotpedia measure summary')), + ('ballotpedia_measure_text', models.TextField(blank=True, default='', null=True, verbose_name='ballotpedia measure text')), + ('ballotpedia_measure_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='ballotpedia url of measure')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of ballotpedia logo')), + ('ballotpedia_yes_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a yes vote means')), + ('ballotpedia_no_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a no vote means')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action measure status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionOrganization', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('organization_name', models.CharField(max_length=255, verbose_name='organization name')), + ('organization_website', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of the endorsing organization')), + ('organization_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='organization contact email address')), + ('organization_contact_form_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of the organization contact form')), + ('organization_contact_name', models.CharField(max_length=255, null=True)), + ('organization_facebook', models.URLField(blank=True, null=True, verbose_name='url of facebook page')), + ('organization_image', models.CharField(max_length=255, null=True, verbose_name='organization image')), + ('state_served_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this organization serves')), + ('vote_smart_id', models.BigIntegerField(blank=True, null=True, verbose_name='vote smart special interest group id')), + ('organization_description', models.TextField(blank=True, null=True, verbose_name='Text description of this organization.')), + ('organization_address', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization street address')), + ('organization_city', models.CharField(blank=True, max_length=255, null=True)), + ('organization_state', models.CharField(blank=True, max_length=2, null=True)), + ('organization_zip', models.CharField(blank=True, max_length=255, null=True)), + ('organization_phone1', models.CharField(blank=True, max_length=255, null=True)), + ('organization_phone2', models.CharField(blank=True, max_length=255, null=True)), + ('organization_fax', models.CharField(blank=True, max_length=255, null=True)), + ('facebook_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook big integer id')), + ('facebook_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='facebook email address')), + ('fb_username', models.CharField(max_length=50, null=True, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z]*$', message='Only alphanumeric characters are allowed.')])), + ('facebook_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of image from facebook')), + ('twitter_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter id')), + ('organization_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='organization twitter screen_name')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='org name from twitter')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='org location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of user logo from twitter')), + ('twitter_profile_background_image_url_https', models.URLField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_banner_url_https', models.URLField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('organization_instagram_handle', models.CharField(max_length=255, null=True, verbose_name='organization instagram screen_name')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_thumbnail_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of wikipedia logo thumbnail')), + ('wikipedia_thumbnail_width', models.IntegerField(blank=True, null=True, verbose_name='width of photo')), + ('wikipedia_thumbnail_height', models.IntegerField(blank=True, null=True, verbose_name='height of photo')), + ('wikipedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of wikipedia logo')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of ballotpedia logo')), + ('organization_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=8, verbose_name='type of org')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action organization status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionPolitician', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('politician_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of this politician')), + ('first_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='first name')), + ('middle_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='middle name')), + ('last_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='last name')), + ('politician_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='official full name')), + ('google_civic_candidate_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='full name from google civic')), + ('full_name_assembled', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='full name assembled from first_name + last_name')), + ('gender', models.CharField(choices=[('F', 'Female'), ('N', 'Gender Neutral'), ('M', 'Male'), ('U', 'Unknown')], default='U', max_length=1, verbose_name='gender')), + ('birth_date', models.DateField(blank=True, default=None, null=True, verbose_name='birth date')), + ('bioguide_id', models.CharField(max_length=200, null=True, verbose_name='bioguide unique identifier')), + ('thomas_id', models.CharField(max_length=200, null=True, verbose_name='thomas unique identifier')), + ('lis_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='lis unique identifier')), + ('govtrack_id', models.CharField(max_length=200, null=True, verbose_name='govtrack unique identifier')), + ('opensecrets_id', models.CharField(max_length=200, null=True, verbose_name='opensecrets unique identifier')), + ('vote_smart_id', models.CharField(max_length=200, null=True, verbose_name='votesmart unique identifier')), + ('fec_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='fec unique identifier')), + ('cspan_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='cspan unique identifier')), + ('wikipedia_id', models.CharField(blank=True, default=None, max_length=500, null=True, verbose_name='wikipedia url')), + ('ballotpedia_id', models.CharField(blank=True, default=None, max_length=500, null=True, verbose_name='ballotpedia unique id')), + ('house_history_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='house history unique identifier')), + ('maplight_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='maplight unique identifier')), + ('washington_post_id', models.CharField(max_length=200, null=True, verbose_name='washington post unique identifier')), + ('icpsr_id', models.CharField(max_length=200, null=True, verbose_name='icpsr unique identifier')), + ('political_party', models.CharField(max_length=255, null=True, verbose_name='politician political party')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='politician home state')), + ('politician_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='latest website url of politician')), + ('politician_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='politician twitter screen_name')), + ('we_vote_hosted_profile_image_url_large', models.URLField(blank=True, max_length=255, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_profile_image_url_medium', models.URLField(blank=True, max_length=255, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_profile_image_url_tiny', models.URLField(blank=True, max_length=255, null=True, verbose_name='we vote hosted tiny image url')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('politician_facebook_id', models.CharField(max_length=255, null=True, verbose_name='politician facebook user name')), + ('politician_phone_number', models.CharField(max_length=255, null=True, verbose_name='politician phone number')), + ('politician_googleplus_id', models.CharField(max_length=255, null=True, verbose_name='politician googleplus profile name')), + ('politician_youtube_id', models.CharField(max_length=255, null=True, verbose_name='politician youtube profile name')), + ('politician_email_address', models.CharField(max_length=80, null=True, verbose_name='politician email address')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action politician status')), + ], + ), + migrations.CreateModel( + name='BatchRowActionPollingLocation', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, default=None, null=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('polling_location_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('location_name', models.CharField(blank=True, max_length=255, null=True)), + ('polling_hours_text', models.CharField(blank=True, max_length=255, null=True)), + ('directions_text', models.TextField(blank=True, null=True)), + ('latitude', models.FloatField(default=None, null=True)), + ('longitude', models.FloatField(default=None, null=True)), + ('line1', models.CharField(blank=True, max_length=255, null=True)), + ('line2', models.CharField(blank=True, max_length=255, null=True)), + ('city', models.CharField(blank=True, max_length=255, null=True)), + ('source_code', models.CharField(blank=True, max_length=255, null=True)), + ('state', models.CharField(blank=True, max_length=255, null=True)), + ('county_name', models.CharField(default=None, max_length=255, null=True)), + ('polling_location_deleted', models.BooleanField(default=False)), + ('precinct_name', models.CharField(default=None, max_length=255, null=True)), + ('use_for_bulk_retrieve', models.BooleanField(default=False)), + ('zip_long', models.CharField(blank=True, max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='BatchRowActionPosition', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('position_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id')), + ('ballot_item_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='text name for ballot item')), + ('ballot_item_image_url_https', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https image for candidate, measure or office')), + ('ballot_item_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name for candidate, measure, or office')), + ('speaker_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the org or person with position')), + ('speaker_image_url_https', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https image for org or person with position')), + ('speaker_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name for org or person with position')), + ('date_entered', models.DateTimeField(auto_now=True, null=True, verbose_name='date entered')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('organization_id', models.BigIntegerField(blank=True, null=True)), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the organization')), + ('voter_id', models.BigIntegerField(blank=True, null=True)), + ('voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the voter expressing the opinion')), + ('public_figure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='public figure we vote id')), + ('google_civic_election_id', models.CharField(db_index=True, default=0, max_length=255, null=True, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='us state of the ballot item position is for')), + ('vote_smart_rating_id', models.BigIntegerField(blank=True, null=True)), + ('vote_smart_time_span', models.CharField(blank=True, max_length=255, null=True, verbose_name='the period in which the organization stated this position')), + ('vote_smart_rating', models.CharField(blank=True, max_length=255, null=True, verbose_name='vote smart value between 0-100')), + ('vote_smart_rating_name', models.CharField(blank=True, max_length=255, null=True)), + ('tweet_source_id', models.BigIntegerField(blank=True, null=True)), + ('contest_office_id', models.BigIntegerField(blank=True, null=True, verbose_name='id of contest_office')), + ('contest_office_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_office')), + ('contest_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the office')), + ('race_office_level', models.CharField(blank=True, max_length=255, null=True, verbose_name='race office level')), + ('candidate_campaign_id', models.BigIntegerField(blank=True, null=True, verbose_name='id of candidate')), + ('candidate_campaign_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the candidate')), + ('google_civic_candidate_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate name exactly as received from google civic')), + ('google_civic_measure_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure title exactly as received from google civic')), + ('politician_id', models.BigIntegerField(blank=True, null=True, verbose_name='')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for politician')), + ('political_party', models.CharField(max_length=255, null=True, verbose_name='political party')), + ('contest_measure_id', models.BigIntegerField(blank=True, null=True, verbose_name='id of contest_measure')), + ('contest_measure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_measure')), + ('stance', models.CharField(choices=[('SUPPORT', 'Supports'), ('STILL_DECIDING', 'Still deciding'), ('NO_STANCE', 'No stance'), ('INFO_ONLY', 'Information only'), ('OPPOSE', 'Opposes'), ('PERCENT_RATING', 'Percentage point rating')], default='NO_STANCE', max_length=15)), + ('statement_text', models.TextField(blank=True, null=True)), + ('statement_html', models.TextField(blank=True, null=True)), + ('more_info_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url with more info about this position')), + ('from_scraper', models.BooleanField(default=False)), + ('organization_certified', models.BooleanField(default=False)), + ('volunteer_certified', models.BooleanField(default=False)), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action position status')), + ], + ), + migrations.CreateModel( + name='BatchRowTranslationMap', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('kind_of_batch', models.CharField(choices=[('MEASURE', 'Measure'), ('ELECTED_OFFICE', 'ElectedOffice'), ('CONTEST_OFFICE', 'ContestOffice'), ('CANDIDATE', 'Candidate'), ('IMPORT_BALLOT_ITEM', 'Ballot Returned'), ('IMPORT_POLLING_LOCATION', 'Map Point'), ('ORGANIZATION', 'Organization'), ('POSITION', 'Position'), ('POLITICIAN', 'Politician')], default='MEASURE', max_length=32)), + ('batch_row_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the the row')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('row_value_recognized_by_we_vote', models.TextField(blank=True, null=True)), + ('incoming_alternate_row_value', models.TextField(blank=True, null=True)), + ], + ), + migrations.CreateModel( + name='BatchSet', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, db_index=True, default=0, null=True, verbose_name='google civic election id')), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='state code for this data')), + ('batch_set_name', models.CharField(max_length=255)), + ('batch_set_description_text', models.CharField(max_length=255)), + ('batch_set_source', models.CharField(max_length=255)), + ('batch_process_id', models.PositiveIntegerField(blank=True, db_index=True, default=0, null=True)), + ('batch_process_ballot_item_chunk_id', models.PositiveIntegerField(blank=True, db_index=True, default=0, null=True)), + ('source_uri', models.URLField(blank=True, max_length=255, null=True, verbose_name='uri where data is coming from')), + ('import_date', models.DateTimeField(auto_now=True, null=True, verbose_name='date when batch set was imported')), + ], + ), + ] diff --git a/import_export_batches/migrations/0002_auto_20220727_1420.py b/import_export_batches/migrations/0002_auto_20220727_1420.py new file mode 100644 index 000000000..aca617704 --- /dev/null +++ b/import_export_batches/migrations/0002_auto_20220727_1420.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.14 on 2022-07-27 21:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='batchprocess', + name='batch_process_paused', + field=models.BooleanField(db_index=True, default=False), + ), + migrations.AlterField( + model_name='batchprocess', + name='date_completed', + field=models.DateTimeField(db_index=True, null=True, verbose_name='finished'), + ), + migrations.AlterField( + model_name='batchprocess', + name='date_started', + field=models.DateTimeField(db_index=True, null=True, verbose_name='start'), + ), + migrations.AlterField( + model_name='batchprocess', + name='kind_of_process', + field=models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], db_index=True, default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50), + ), + ] diff --git a/import_export_batches/migrations/0003_alter_batchprocess_kind_of_process.py b/import_export_batches/migrations/0003_alter_batchprocess_kind_of_process.py new file mode 100644 index 000000000..57e22ee40 --- /dev/null +++ b/import_export_batches/migrations/0003_alter_batchprocess_kind_of_process.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.15 on 2022-09-13 03:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0002_auto_20220727_1420'), + ] + + operations = [ + migrations.AlterField( + model_name='batchprocess', + name='kind_of_process', + field=models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('GENERATE_VOTER_GUIDES', 'Generate voter guides'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], db_index=True, default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50), + ), + ] diff --git a/import_export_batches/migrations/0004_auto_20230104_0640.py b/import_export_batches/migrations/0004_auto_20230104_0640.py new file mode 100644 index 000000000..6975b9618 --- /dev/null +++ b/import_export_batches/migrations/0004_auto_20230104_0640.py @@ -0,0 +1,38 @@ +# Generated by Django 3.2.16 on 2023-01-04 14:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0003_alter_batchprocess_kind_of_process'), + ] + + operations = [ + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_twitter_handle2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_twitter_handle3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_twitter_handle4', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_twitter_handle5', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='batchrowactionpolitician', + name='politician_twitter_handle', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/import_export_batches/migrations/0005_auto_20230106_1130.py b/import_export_batches/migrations/0005_auto_20230106_1130.py new file mode 100644 index 000000000..3a6d77b26 --- /dev/null +++ b/import_export_batches/migrations/0005_auto_20230106_1130.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.16 on 2023-01-06 19:30 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0004_auto_20230104_0640'), + ] + + operations = [ + migrations.AddField( + model_name='batchrowactioncandidate', + name='candidate_twitter_handle2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactioncandidate', + name='candidate_twitter_handle3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='batchrowactioncandidate', + name='candidate_twitter_handle', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='batchrowactionpolitician', + name='gender', + field=models.CharField(choices=[('F', 'Female'), ('N', 'Nonbinary'), ('M', 'Male'), ('U', 'Unknown')], default='U', max_length=1, verbose_name='gender'), + ), + ] diff --git a/import_export_batches/migrations/0006_auto_20230110_0710.py b/import_export_batches/migrations/0006_auto_20230110_0710.py new file mode 100644 index 000000000..6aa5e80b0 --- /dev/null +++ b/import_export_batches/migrations/0006_auto_20230110_0710.py @@ -0,0 +1,82 @@ +# Generated by Django 3.2.16 on 2023-01-10 15:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0005_auto_20230106_1130'), + ] + + operations = [ + migrations.CreateModel( + name='BatchRowActionOfficeHeld', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(null=True, verbose_name='unique id of batch set')), + ('batch_header_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of header row')), + ('batch_row_id', models.PositiveIntegerField(db_index=True, verbose_name='unique id of batch row')), + ('kind_of_action', models.CharField(choices=[('IMPORT_TO_BE_DETERMINED', 'To Be Determined'), ('DO_NOT_PROCESS', 'Do not process'), ('IMPORT_CREATE', 'Create'), ('IMPORT_ADD_TO_EXISTING', 'Add to Existing')], db_index=True, default='IMPORT_TO_BE_DETERMINED', max_length=40)), + ('office_held_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this office held')), + ('office_held_name', models.CharField(max_length=255, verbose_name='name of the office held')), + ('office_held_name_es', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the office held in Spanish')), + ('google_civic_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_election_id', models.CharField(db_index=True, max_length=255, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('maplight_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='maplight unique identifier')), + ('ballotpedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia unique identifier')), + ('wikipedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='wikipedia unique identifier')), + ('number_elected', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates who will be elected')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this office serves')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('district_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='district name')), + ('district_scope', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('contest_level0', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 0')), + ('contest_level1', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 1')), + ('contest_level2', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 2')), + ('electorate_specifications', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('special', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('office_held_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='office description')), + ('office_held_description_es', models.CharField(blank=True, max_length=255, null=True, verbose_name='office description spanish')), + ('office_held_is_partisan', models.BooleanField(default=False, verbose_name='office is_partisan')), + ('office_held_ctcl_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for this office held')), + ('status', models.TextField(blank=True, default='', null=True, verbose_name='batch row action office held status')), + ], + ), + migrations.DeleteModel( + name='BatchRowActionElectedOffice', + ), + migrations.RemoveField( + model_name='batchrowactioncontestoffice', + name='elected_office_name', + ), + migrations.AddField( + model_name='batchrowactioncontestoffice', + name='office_held_name', + field=models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the office held'), + ), + migrations.AlterField( + model_name='batchdescription', + name='kind_of_batch', + field=models.CharField(choices=[('MEASURE', 'Measure'), ('OFFICE_HELD', 'OfficeHeld'), ('CONTEST_OFFICE', 'ContestOffice'), ('CANDIDATE', 'Candidate'), ('IMPORT_BALLOT_ITEM', 'Ballot Returned'), ('IMPORT_POLLING_LOCATION', 'Map Point'), ('ORGANIZATION', 'Organization'), ('POSITION', 'Position'), ('POLITICIAN', 'Politician')], db_index=True, default='MEASURE', max_length=32), + ), + migrations.AlterField( + model_name='batchheadertranslationsuggestion', + name='kind_of_batch', + field=models.CharField(choices=[('MEASURE', 'Measure'), ('OFFICE_HELD', 'OfficeHeld'), ('CONTEST_OFFICE', 'ContestOffice'), ('CANDIDATE', 'Candidate'), ('IMPORT_BALLOT_ITEM', 'Ballot Returned'), ('IMPORT_POLLING_LOCATION', 'Map Point'), ('ORGANIZATION', 'Organization'), ('POSITION', 'Position'), ('POLITICIAN', 'Politician')], default='MEASURE', max_length=32), + ), + migrations.AlterField( + model_name='batchrowactioncandidate', + name='ballotpedia_office_id', + field=models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia office held integer id'), + ), + migrations.AlterField( + model_name='batchrowtranslationmap', + name='kind_of_batch', + field=models.CharField(choices=[('MEASURE', 'Measure'), ('OFFICE_HELD', 'OfficeHeld'), ('CONTEST_OFFICE', 'ContestOffice'), ('CANDIDATE', 'Candidate'), ('IMPORT_BALLOT_ITEM', 'Ballot Returned'), ('IMPORT_POLLING_LOCATION', 'Map Point'), ('ORGANIZATION', 'Organization'), ('POSITION', 'Position'), ('POLITICIAN', 'Politician')], default='MEASURE', max_length=32), + ), + ] diff --git a/import_export_batches/migrations/0007_auto_20230201_1248.py b/import_export_batches/migrations/0007_auto_20230201_1248.py new file mode 100644 index 000000000..b92afccf9 --- /dev/null +++ b/import_export_batches/migrations/0007_auto_20230201_1248.py @@ -0,0 +1,44 @@ +# Generated by Django 3.2.16 on 2023-02-01 20:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0006_auto_20230110_0710'), + ] + + operations = [ + migrations.CreateModel( + name='BatchProcessRepresentativesChunk', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, default=0)), + ('batch_set_id', models.PositiveIntegerField(db_index=True, default=0)), + ('state_code', models.CharField(max_length=2, null=True)), + ('retrieve_date_started', models.DateTimeField(null=True)), + ('retrieve_date_completed', models.DateTimeField(null=True)), + ('retrieve_timed_out', models.BooleanField(default=None, null=True)), + ('retrieve_row_count', models.PositiveIntegerField(default=0)), + ('politician_matching_date_started', models.DateTimeField(null=True)), + ('politician_matching_date_completed', models.DateTimeField(null=True)), + ('politician_matching_timed_out', models.BooleanField(default=None, null=True)), + ('politician_matching_row_count', models.PositiveIntegerField(default=0)), + ('politician_deduplication_date_started', models.DateTimeField(null=True)), + ('politician_deduplication_date_completed', models.DateTimeField(null=True)), + ('politician_deduplication_timed_out', models.BooleanField(default=None, null=True)), + ('politician_deduplication_row_count', models.PositiveIntegerField(default=0)), + ], + ), + migrations.AddField( + model_name='batchprocesslogentry', + name='batch_process_representatives_chunk_id', + field=models.PositiveIntegerField(db_index=True, default=0), + ), + migrations.AddField( + model_name='batchset', + name='batch_process_representatives_chunk_id', + field=models.PositiveIntegerField(db_index=True, default=0, null=True), + ), + ] diff --git a/import_export_batches/migrations/0008_auto_20230203_0925.py b/import_export_batches/migrations/0008_auto_20230203_0925.py new file mode 100644 index 000000000..343975ab0 --- /dev/null +++ b/import_export_batches/migrations/0008_auto_20230203_0925.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.17 on 2023-02-03 17:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0007_auto_20230201_1248'), + ] + + operations = [ + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_email', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_email2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_email3', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/import_export_batches/migrations/0009_auto_20230203_1547.py b/import_export_batches/migrations/0009_auto_20230203_1547.py new file mode 100644 index 000000000..062c43dff --- /dev/null +++ b/import_export_batches/migrations/0009_auto_20230203_1547.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.17 on 2023-02-03 23:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0008_auto_20230203_0925'), + ] + + operations = [ + migrations.AddField( + model_name='batchrowactionpolitician', + name='facebook_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='facebook_url2', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='facebook_url3', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_phone_number2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='batchrowactionpolitician', + name='politician_phone_number3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='batchrowactionpolitician', + name='politician_phone_number', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='batchrowactionpolitician', + name='politician_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/import_export_batches/migrations/0010_alter_batchrowactionpolitician_gender.py b/import_export_batches/migrations/0010_alter_batchrowactionpolitician_gender.py new file mode 100644 index 000000000..805972534 --- /dev/null +++ b/import_export_batches/migrations/0010_alter_batchrowactionpolitician_gender.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-07-20 11:29 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0009_auto_20230203_1547'), + ] + + operations = [ + migrations.AlterField( + model_name='batchrowactionpolitician', + name='gender', + field=models.CharField(choices=[('M', 'Male'), ('F', 'Female'), ('N', 'Nonbinary'), ('U', 'Unknown')], default='U', max_length=1, verbose_name='gender'), + ), + ] diff --git a/import_export_batches/migrations/0011_auto_20240129_0555.py b/import_export_batches/migrations/0011_auto_20240129_0555.py new file mode 100644 index 000000000..c80ab233b --- /dev/null +++ b/import_export_batches/migrations/0011_auto_20240129_0555.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.23 on 2024-01-29 13:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0010_alter_batchrowactionpolitician_gender'), + ] + + operations = [ + migrations.AlterField( + model_name='batchrowactionorganization', + name='organization_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='organization twitter username'), + ), + migrations.AlterField( + model_name='batchrowactionposition', + name='ballot_item_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username for candidate, measure, or office'), + ), + migrations.AlterField( + model_name='batchrowactionposition', + name='speaker_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username for org or person with position'), + ), + ] diff --git a/import_export_batches/migrations/0012_batchrowactionorganization_organization_ballotpedia.py b/import_export_batches/migrations/0012_batchrowactionorganization_organization_ballotpedia.py new file mode 100644 index 000000000..17b638e82 --- /dev/null +++ b/import_export_batches/migrations/0012_batchrowactionorganization_organization_ballotpedia.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-09 20:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0011_auto_20240129_0555'), + ] + + operations = [ + migrations.AddField( + model_name='batchrowactionorganization', + name='organization_ballotpedia', + field=models.URLField(blank=True, null=True, verbose_name='url of ballotpedia page'), + ), + ] diff --git a/import_export_batches/migrations/0013_batchrowactionorganization_organization_wikipedia.py b/import_export_batches/migrations/0013_batchrowactionorganization_organization_wikipedia.py new file mode 100644 index 000000000..8823fc024 --- /dev/null +++ b/import_export_batches/migrations/0013_batchrowactionorganization_organization_wikipedia.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-30 01:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0012_batchrowactionorganization_organization_ballotpedia'), + ] + + operations = [ + migrations.AddField( + model_name='batchrowactionorganization', + name='organization_wikipedia', + field=models.URLField(blank=True, null=True, verbose_name='url of wikipedia page'), + ), + ] diff --git a/import_export_batches/migrations/0014_alter_batchrowactionposition_more_info_url.py b/import_export_batches/migrations/0014_alter_batchrowactionposition_more_info_url.py new file mode 100644 index 000000000..73451e91e --- /dev/null +++ b/import_export_batches/migrations/0014_alter_batchrowactionposition_more_info_url.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-02 15:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0013_batchrowactionorganization_organization_wikipedia'), + ] + + operations = [ + migrations.AlterField( + model_name='batchrowactionposition', + name='more_info_url', + field=models.TextField(null=True, verbose_name='url with more info about this position'), + ), + ] diff --git a/import_export_batches/migrations/0015_alter_batchdescription_source_uri_and_more.py b/import_export_batches/migrations/0015_alter_batchdescription_source_uri_and_more.py new file mode 100644 index 000000000..563bf4c1d --- /dev/null +++ b/import_export_batches/migrations/0015_alter_batchdescription_source_uri_and_more.py @@ -0,0 +1,48 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0014_alter_batchrowactionposition_more_info_url'), + ] + + operations = [ + migrations.AlterField( + model_name='batchdescription', + name='source_uri', + field=models.TextField(null=True, verbose_name='uri where data is coming from'), + ), + migrations.AlterField( + model_name='batchrowactionballotitem', + name='measure_url', + field=models.TextField(null=True, verbose_name='url of measure'), + ), + migrations.AlterField( + model_name='batchrowactioncandidate', + name='candidate_contact_form_url', + field=models.TextField(null=True, verbose_name='website url of candidate contact form'), + ), + migrations.AlterField( + model_name='batchrowactioncandidate', + name='candidate_url', + field=models.TextField(null=True, verbose_name='website url of candidate'), + ), + migrations.AlterField( + model_name='batchrowactionorganization', + name='organization_contact_form_url', + field=models.TextField(null=True, verbose_name='url of the organization contact form'), + ), + migrations.AlterField( + model_name='batchrowactionorganization', + name='organization_website', + field=models.TextField(null=True, verbose_name='url of the endorsing organization'), + ), + migrations.AlterField( + model_name='batchset', + name='source_uri', + field=models.TextField(null=True, verbose_name='uri where data is coming from'), + ), + ] diff --git a/import_export_batches/migrations/0016_alter_batchprocess_kind_of_process.py b/import_export_batches/migrations/0016_alter_batchprocess_kind_of_process.py new file mode 100644 index 000000000..ea202aa6f --- /dev/null +++ b/import_export_batches/migrations/0016_alter_batchprocess_kind_of_process.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-10 16:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0015_alter_batchdescription_source_uri_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='batchprocess', + name='kind_of_process', + field=models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('GENERATE_VOTER_GUIDES', 'Generate voter guides'), ('MATCH_POLITICIANS_TO_ORGANIZATIONS', 'Match politicians to organizations'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], db_index=True, default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50), + ), + ] diff --git a/import_export_batches/migrations/0017_alter_batchprocess_kind_of_process.py b/import_export_batches/migrations/0017_alter_batchprocess_kind_of_process.py new file mode 100644 index 000000000..f7fda3508 --- /dev/null +++ b/import_export_batches/migrations/0017_alter_batchprocess_kind_of_process.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-12 19:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0016_alter_batchprocess_kind_of_process'), + ] + + operations = [ + migrations.AlterField( + model_name='batchprocess', + name='kind_of_process', + field=models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('GENERATE_VOTER_GUIDES', 'Generate voter guides'), ('MATCH_POLITICIANS_TO_ORGANIZATIONS', 'Match politicians to organizations'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('RETRIEVE_FROM_BALLOTPEDIA', 'Retrieve Data from Ballotpedia'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], db_index=True, default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50), + ), + ] diff --git a/import_export_batches/migrations/0018_alter_batchprocess_kind_of_process.py b/import_export_batches/migrations/0018_alter_batchprocess_kind_of_process.py new file mode 100644 index 000000000..d004d8845 --- /dev/null +++ b/import_export_batches/migrations/0018_alter_batchprocess_kind_of_process.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-11-05 18:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0017_alter_batchprocess_kind_of_process'), + ] + + operations = [ + migrations.AlterField( + model_name='batchprocess', + name='kind_of_process', + field=models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('GENERATE_VOTER_GUIDES', 'Generate voter guides'), ('MAINTENANCE_SCRIPTS_CAMPAIGNX', 'Maintenance Scripts for CampaignX'), ('MAINTENANCE_SCRIPTS_CANDIDATE', 'Maintenance Scripts for Candidate'), ('MAINTENANCE_SCRIPTS_CHALLENGE', 'Maintenance Scripts for Challenge'), ('MAINTENANCE_SCRIPTS_OFFICE', 'Maintenance Scripts for Office'), ('MAINTENANCE_SCRIPTS_OFFICE_HELD', 'Maintenance Scripts for Office Held'), ('MAINTENANCE_SCRIPTS_POLITICIAN', 'Maintenance Scripts for Politician'), ('MAINTENANCE_SCRIPTS_POSITION', 'Maintenance Scripts for Position'), ('MAINTENANCE_SCRIPTS_REPRESENTATIVE', 'Maintenance Scripts for Representative'), ('MATCH_POLITICIANS_TO_ORGANIZATIONS', 'Match politicians to organizations'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('RETRIEVE_FROM_BALLOTPEDIA', 'Retrieve Data from Ballotpedia'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], db_index=True, default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50), + ), + ] diff --git a/import_export_batches/migrations/0019_alter_batchprocess_kind_of_process.py b/import_export_batches/migrations/0019_alter_batchprocess_kind_of_process.py new file mode 100644 index 000000000..d4cc38ef7 --- /dev/null +++ b/import_export_batches/migrations/0019_alter_batchprocess_kind_of_process.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-11-24 15:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_batches', '0018_alter_batchprocess_kind_of_process'), + ] + + operations = [ + migrations.AlterField( + model_name='batchprocess', + name='kind_of_process', + field=models.CharField(choices=[('ACTIVITY_NOTICE_PROCESS', 'Create, update, or schedule to send Activity Notices'), ('API_REFRESH_REQUEST', 'Make sure we have cached a recent return from a specific API'), ('AUGMENT_ANALYTICS_ACTION_WITH_ELECTION_ID', 'Add election id to AnalyticsAction'), ('AUGMENT_ANALYTICS_ACTION_WITH_FIRST_VISIT', 'Mark first AnalyticsAction per day'), ('CALCULATE_SITEWIDE_VOTER_METRICS', 'Sitewide voter metrics for all time'), ('CALCULATE_SITEWIDE_DAILY_METRICS', 'Sitewide daily metrics'), ('CALCULATE_SITEWIDE_ELECTION_METRICS', 'Sitewide election metrics'), ('CALCULATE_ORGANIZATION_DAILY_METRICS', 'Organization specific daily metrics'), ('CALCULATE_ORGANIZATION_ELECTION_METRICS', 'Organization specific election metrics'), ('DEDUPLICATION_SCRIPTS_CAMPAIGNX', 'Deduplication Scripts for CampaignX'), ('DEDUPLICATION_SCRIPTS_CANDIDATE', 'Deduplication Scripts for Candidate'), ('DEDUPLICATION_SCRIPTS_CHALLENGE', 'Deduplication Scripts for Challenge'), ('DEDUPLICATION_SCRIPTS_ORGANIZATION', 'Deduplication Scripts for Organization'), ('DEDUPLICATION_SCRIPTS_POLITICIAN', 'Deduplication Scripts for Politician'), ('GENERATE_VOTER_GUIDES', 'Generate voter guides'), ('MAINTENANCE_SCRIPTS_CAMPAIGNX', 'Maintenance Scripts for CampaignX'), ('MAINTENANCE_SCRIPTS_CANDIDATE', 'Maintenance Scripts for Candidate'), ('MAINTENANCE_SCRIPTS_CHALLENGE', 'Maintenance Scripts for Challenge'), ('MAINTENANCE_SCRIPTS_OFFICE', 'Maintenance Scripts for Office'), ('MAINTENANCE_SCRIPTS_OFFICE_HELD', 'Maintenance Scripts for Office Held'), ('MAINTENANCE_SCRIPTS_ORGANIZATION', 'Maintenance Scripts for Organization'), ('MAINTENANCE_SCRIPTS_POLITICIAN', 'Maintenance Scripts for Politician'), ('MAINTENANCE_SCRIPTS_POSITION', 'Maintenance Scripts for Position'), ('MAINTENANCE_SCRIPTS_REPRESENTATIVE', 'Maintenance Scripts for Representative'), ('MAINTENANCE_SCRIPTS_VOTER', 'Maintenance Scripts for Voter'), ('MATCH_POLITICIANS_TO_ORGANIZATIONS', 'Match politicians to organizations'), ('RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Retrieve Ballot Items from Map Points'), ('RETRIEVE_FROM_BALLOTPEDIA', 'Retrieve Data from Ballotpedia'), ('REFRESH_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', 'Refresh Ballot Items from BallotReturned Map Points'), ('REFRESH_BALLOT_ITEMS_FROM_VOTERS', 'Refresh Ballot Items from Voter Custom Addresses'), ('SEARCH_TWITTER_FOR_CANDIDATE_TWITTER_HANDLE', 'Search for Candidate Twitter Handles')], db_index=True, default='RETRIEVE_BALLOT_ITEMS_FROM_POLLING_LOCATIONS', max_length=50), + ), + ] diff --git a/import_export_bigquery/migrations/0001_initial.py b/import_export_bigquery/migrations/0001_initial.py new file mode 100644 index 000000000..6f48e9075 --- /dev/null +++ b/import_export_bigquery/migrations/0001_initial.py @@ -0,0 +1,35 @@ +# Generated by Django 5.0.9 on 2024-11-11 03:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BigQueryEvent', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('label', models.TextField(null=True)), + ('value', models.TextField(null=True)), + ('selector', models.TextField(null=True)), + ('type', models.CharField(max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='BigQuerySession', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('errors_count', models.PositiveIntegerField(null=True)), + ('events_count', models.PositiveIntegerField(null=True)), + ('pages_count', models.PositiveIntegerField(null=True)), + ('project_id', models.CharField(max_length=255, null=True)), + ('user_uuid', models.CharField(max_length=36, null=True)), + ], + ), + ] diff --git a/import_export_ctcl/migrations/0001_initial.py b/import_export_ctcl/migrations/0001_initial.py new file mode 100644 index 000000000..5029fad94 --- /dev/null +++ b/import_export_ctcl/migrations/0001_initial.py @@ -0,0 +1,61 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='CandidateSelection', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_set_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='batch set id')), + ('candidate_selection_id', models.CharField(default='', max_length=255, null=True, verbose_name='candidate selection id')), + ('contest_office_id', models.CharField(default='', max_length=255, null=True, verbose_name='contest office ctcl id')), + ], + ), + migrations.CreateModel( + name='CTCLApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True, verbose_name='kind of call to CTCL')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='CTCLApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to CTCL')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='CTCLApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to CTCL')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='CTCLApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to CTCL')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + ] diff --git a/import_export_facebook/migrations/0001_initial.py b/import_export_facebook/migrations/0001_initial.py new file mode 100644 index 000000000..bd2522357 --- /dev/null +++ b/import_export_facebook/migrations/0001_initial.py @@ -0,0 +1,92 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +import django.core.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='FacebookAuthResponse', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_device_id', models.CharField(max_length=255, unique=True, verbose_name='voter_device_id initiating Facebook Auth')), + ('datetime_of_authorization', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('facebook_access_token', models.CharField(blank=True, max_length=512, null=True, verbose_name='accessToken from Facebook')), + ('facebook_expires_in', models.IntegerField(blank=True, null=True, verbose_name='expiresIn from Facebook')), + ('facebook_signed_request', models.TextField(blank=True, null=True, verbose_name='signedRequest from Facebook')), + ('facebook_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook big integer id')), + ('facebook_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='facebook email address')), + ('facebook_first_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='first_name from Facebook')), + ('facebook_middle_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='first_name from Facebook')), + ('facebook_last_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='first_name from Facebook')), + ('facebook_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of voter's image from facebook')), + ('facebook_background_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of voter's background 'cover' image from facebook (like the twitter banner photo)')), + ('facebook_background_image_offset_x', models.IntegerField(blank=True, default=0, null=True, verbose_name='x offset of facebook cover image')), + ('facebook_background_image_offset_y', models.IntegerField(blank=True, default=0, null=True, verbose_name='y offset of facebook cover image')), + ], + ), + migrations.CreateModel( + name='FacebookFriendsUsingWeVote', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('facebook_id_of_me', models.BigIntegerField(verbose_name='facebook id of viewer')), + ('facebook_id_of_my_friend', models.BigIntegerField(verbose_name='facebook id of my friend')), + ], + ), + migrations.CreateModel( + name='FacebookLinkToVoter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(max_length=255, unique=True, verbose_name='we vote id for the email owner')), + ('facebook_user_id', models.BigIntegerField(unique=True, verbose_name='facebook big integer id')), + ('secret_key', models.CharField(max_length=255, unique=True, verbose_name='secret key to verify ownership facebook account')), + ('date_last_changed', models.DateTimeField(auto_now=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='FacebookMessageOutboundDescription', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('kind_of_send_template', models.CharField(choices=[('GENERIC_EMAIL_FACEBOOK_TEMPLATE', 'Generic Email'), ('FRIEND_INVITATION_FACEBOOK_TEMPLATE', 'Invite Friend')], default='GENERIC_EMAIL_FACEBOOK_TEMPLATE', max_length=50)), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('recipient_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the recipient if we have it')), + ('recipient_facebook_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook big integer id')), + ('recipient_facebook_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='facebook email address')), + ('recipient_fb_username', models.CharField(max_length=50, null=True, unique=True, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z]*$', message='Only alphanumeric characters are allowed.')])), + ('send_status', models.CharField(choices=[('TO_BE_PROCESSED', 'Message to be processed'), ('BEING_SENT', 'Message being sent'), ('SENT', 'Message sent')], default='TO_BE_PROCESSED', max_length=50)), + ], + ), + migrations.CreateModel( + name='FacebookUser', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('facebook_user_id', models.BigIntegerField(verbose_name='facebook id of user')), + ('facebook_user_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='User name from Facebook')), + ('facebook_user_first_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's first_name from Facebook")), + ('facebook_user_middle_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's middle_name from Facebook")), + ('facebook_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='facebook email address')), + ('facebook_user_location_id', models.BigIntegerField(null=True, verbose_name='location id of Facebook user')), + ('facebook_user_location_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's location name from Facebook")), + ('facebook_user_gender', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's gender from Facebook")), + ('facebook_user_birthday', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's birthday from Facebook")), + ('facebook_user_last_name', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's last_name from Facebook")), + ('facebook_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of voter image from facebook')), + ('facebook_background_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of cover image from facebook')), + ('facebook_background_image_offset_x', models.IntegerField(blank=True, default=0, null=True, verbose_name='x offset of facebook cover image')), + ('facebook_background_image_offset_y', models.IntegerField(blank=True, default=0, null=True, verbose_name='y offset of facebook cover image')), + ('we_vote_hosted_profile_image_url_large', models.URLField(blank=True, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_profile_image_url_medium', models.URLField(blank=True, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_profile_image_url_tiny', models.URLField(blank=True, null=True, verbose_name='we vote hosted tiny image url')), + ('facebook_user_about', models.CharField(blank=True, max_length=255, null=True, verbose_name="User's About from Facebook")), + ('facebook_user_is_verified', models.BooleanField(default=False, verbose_name='User is verfired from Facebook')), + ('facebook_user_friend_total_count', models.BigIntegerField(null=True, verbose_name='total count of friends from facebook')), + ], + ), + ] diff --git a/import_export_google_civic/migrations/0001_initial.py b/import_export_google_civic/migrations/0001_initial.py new file mode 100644 index 000000000..4595fcd69 --- /dev/null +++ b/import_export_google_civic/migrations/0001_initial.py @@ -0,0 +1,52 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='GoogleCivicApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to google')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='GoogleCivicApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to google')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='GoogleCivicApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to google')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='GoogleCivicApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to google')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + ] diff --git a/import_export_maplight/migrations/0001_initial.py b/import_export_maplight/migrations/0001_initial.py new file mode 100644 index 000000000..161eb4f24 --- /dev/null +++ b/import_export_maplight/migrations/0001_initial.py @@ -0,0 +1,47 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='MapLightCandidate', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('candidate_id', models.IntegerField(unique=True, verbose_name='candidate id')), + ('display_name', models.CharField(max_length=255, verbose_name='display name')), + ('first_name', models.CharField(blank=True, max_length=255, verbose_name='first name')), + ('gender', models.CharField(default='U', max_length=1, verbose_name='gender')), + ('last_funding_update', models.DateField(blank=True, default=None, null=True, verbose_name='last funding update date')), + ('last_name', models.CharField(blank=True, max_length=255, verbose_name='last name')), + ('middle_name', models.CharField(max_length=255, verbose_name='middle name')), + ('name_prefix', models.CharField(blank=True, max_length=255, verbose_name='name prefix')), + ('name_suffix', models.CharField(blank=True, max_length=255, verbose_name='name suffix')), + ('original_name', models.CharField(blank=True, max_length=255, verbose_name='original name')), + ('party', models.CharField(blank=True, max_length=255, verbose_name='political party')), + ('photo', models.CharField(blank=True, max_length=255, verbose_name='photo url')), + ('politician_id', models.IntegerField(unique=True, verbose_name='politician id')), + ('roster_name', models.CharField(blank=True, max_length=255, verbose_name='roster name')), + ('type', models.CharField(blank=True, max_length=255, verbose_name='type')), + ('url', models.CharField(blank=True, max_length=255, verbose_name='url')), + ], + ), + migrations.CreateModel( + name='MapLightContestOffice', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('election_date', models.DateField(blank=True, default=None, null=True, verbose_name='election date')), + ('contest_id', models.CharField(max_length=255, unique=True, verbose_name='contest id')), + ('title', models.CharField(max_length=255, verbose_name='title')), + ('type', models.CharField(max_length=255, verbose_name='type')), + ('url', models.CharField(max_length=255, verbose_name='url')), + ], + ), + ] diff --git a/import_export_open_people/migrations/0001_initial.py b/import_export_open_people/migrations/0001_initial.py new file mode 100644 index 000000000..db0ffe07e --- /dev/null +++ b/import_export_open_people/migrations/0001_initial.py @@ -0,0 +1,49 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='OpenPeopleApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True)), + ('number_of_items_sent_in_query', models.PositiveIntegerField(db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='OpenPeopleApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='OpenPeopleApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='OpenPeopleApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + ] diff --git a/import_export_openreplay/migrations/0001_initial.py b/import_export_openreplay/migrations/0001_initial.py new file mode 100644 index 000000000..d9a3bcacf --- /dev/null +++ b/import_export_openreplay/migrations/0001_initial.py @@ -0,0 +1,35 @@ +# Generated by Django 5.0.9 on 2024-11-11 03:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='OpenReplayEvent', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('label', models.TextField(null=True)), + ('value', models.TextField(null=True)), + ('selector', models.TextField(null=True)), + ('type', models.CharField(max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='OpenReplaySession', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('errors_count', models.PositiveIntegerField(null=True)), + ('events_count', models.PositiveIntegerField(null=True)), + ('pages_count', models.PositiveIntegerField(null=True)), + ('project_id', models.CharField(max_length=255, null=True)), + ('user_uuid', models.CharField(max_length=36, null=True)), + ], + ), + ] diff --git a/import_export_openreplay/migrations/0002_openreplayevent_base_referrer_and_more.py b/import_export_openreplay/migrations/0002_openreplayevent_base_referrer_and_more.py new file mode 100644 index 000000000..cf7315db0 --- /dev/null +++ b/import_export_openreplay/migrations/0002_openreplayevent_base_referrer_and_more.py @@ -0,0 +1,188 @@ +# Generated by Django 5.0.13 on 2025-03-28 22:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_openreplay', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='openreplayevent', + name='base_referrer', + field=models.URLField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='dom_building_time', + field=models.PositiveIntegerField(blank=True, help_text='DOM building time in milliseconds', null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='dom_content_loaded_time', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='duration', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='first_contentful_paint_time', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='first_paint_time', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='hesitation', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='host', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='load_time', + field=models.PositiveIntegerField(blank=True, help_text='Load time in milliseconds', null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='message_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='path', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='query', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='referrer', + field=models.URLField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='response_end', + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='response_time', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='speed_index', + field=models.PositiveIntegerField(blank=True, help_text='Speed index in milliseconds', null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='time_to_interactive', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='timestamp', + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='ttfb', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='url', + field=models.URLField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplayevent', + name='visually_complete', + field=models.PositiveIntegerField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='duration', + field=models.DurationField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='session_id', + field=models.UUIDField(editable=False, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='start_ts', + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='user_agent', + field=models.TextField(blank=True, help_text='Full User-Agent string', null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='user_browser', + field=models.CharField(blank=True, max_length=150, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='user_country', + field=models.CharField(blank=True, max_length=15, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='user_device', + field=models.CharField(blank=True, max_length=200, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='user_id', + field=models.CharField(max_length=25, null=True), + ), + migrations.AddField( + model_name='openreplaysession', + name='user_os', + field=models.CharField(blank=True, max_length=100, null=True), + ), + migrations.AlterField( + model_name='openreplayevent', + name='label', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='openreplayevent', + name='selector', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='openreplayevent', + name='type', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='openreplayevent', + name='value', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='openreplaysession', + name='user_uuid', + field=models.UUIDField(null=True), + ), + ] diff --git a/import_export_snovio/migrations/0001_initial.py b/import_export_snovio/migrations/0001_initial.py new file mode 100644 index 000000000..3304e48ba --- /dev/null +++ b/import_export_snovio/migrations/0001_initial.py @@ -0,0 +1,49 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='SnovIOApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True)), + ('number_of_items_sent_in_query', models.PositiveIntegerField(db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='SnovIOApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='SnovIOApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='SnovIOApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + ] diff --git a/import_export_targetsmart/migrations/0001_initial.py b/import_export_targetsmart/migrations/0001_initial.py new file mode 100644 index 000000000..47aed7dfd --- /dev/null +++ b/import_export_targetsmart/migrations/0001_initial.py @@ -0,0 +1,49 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='TargetSmartApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True)), + ('number_of_items_sent_in_query', models.PositiveIntegerField(db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='TargetSmartApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='TargetSmartApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + migrations.CreateModel( + name='TargetSmartApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call')), + ], + ), + ] diff --git a/import_export_twitter/migrations/0001_initial.py b/import_export_twitter/migrations/0001_initial.py new file mode 100644 index 000000000..ae28d325e --- /dev/null +++ b/import_export_twitter/migrations/0001_initial.py @@ -0,0 +1,31 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='TwitterAuthResponse', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_device_id', models.CharField(max_length=255, unique=True, verbose_name='voter_device_id initiating Twitter Auth')), + ('datetime_of_authorization', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('twitter_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter big integer id')), + ('twitter_screen_name', models.CharField(max_length=255, null=True, verbose_name='twitter screen name / handle')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='display name from twitter')), + ('twitter_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('twitter_profile_banner_url_https', models.URLField(blank=True, null=True, verbose_name='url of banner from twitter')), + ('twitter_request_token', models.TextField(blank=True, null=True, verbose_name='twitter request token')), + ('twitter_request_secret', models.TextField(blank=True, null=True, verbose_name='twitter request secret')), + ('twitter_access_token', models.TextField(blank=True, null=True, verbose_name='twitter access token')), + ('twitter_access_secret', models.TextField(blank=True, null=True, verbose_name='twitter access secret')), + ], + ), + ] diff --git a/import_export_twitter/migrations/0002_auto_20240303_1539.py b/import_export_twitter/migrations/0002_auto_20240303_1539.py new file mode 100644 index 000000000..fa5bb92df --- /dev/null +++ b/import_export_twitter/migrations/0002_auto_20240303_1539.py @@ -0,0 +1,43 @@ +# Generated by Django 3.2.24 on 2024-03-03 23:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_twitter', '0001_initial'), + ] + + operations = [ + migrations.RenameField( + model_name='twitterauthresponse', + old_name='twitter_access_secret', + new_name='twitter_voters_access_secret', + ), + migrations.RenameField( + model_name='twitterauthresponse', + old_name='twitter_access_token', + new_name='twitter_voters_access_token_secret', + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_description', + field=models.TextField(blank=True, null=True, verbose_name='twitter description'), + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_location', + field=models.TextField(blank=True, null=True, verbose_name='twitter location'), + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_verified', + field=models.BooleanField(default=False, verbose_name='twitter verified'), + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_verified_type', + field=models.TextField(default='', verbose_name='twitter verified type'), + ), + ] diff --git a/import_export_twitter/migrations/0003_remove_twitterauthresponse_twitter_voters_access_secret_and_more.py b/import_export_twitter/migrations/0003_remove_twitterauthresponse_twitter_voters_access_secret_and_more.py new file mode 100644 index 000000000..7528e08ac --- /dev/null +++ b/import_export_twitter/migrations/0003_remove_twitterauthresponse_twitter_voters_access_secret_and_more.py @@ -0,0 +1,37 @@ +# Generated by Django 5.0.3 on 2024-05-24 19:00 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('import_export_twitter', '0002_auto_20240303_1539'), + ] + + operations = [ + migrations.RemoveField( + model_name='twitterauthresponse', + name='twitter_voters_access_secret', + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_voters_access_token', + field=models.TextField(blank=True, null=True, verbose_name='twitter access token'), + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_voters_oauth_token', + field=models.TextField(blank=True, null=True, verbose_name='twitter voter client oauth_token'), + ), + migrations.AddField( + model_name='twitterauthresponse', + name='twitter_voters_oauth_verifier', + field=models.TextField(blank=True, null=True, verbose_name='twitter voter client oauth_verifier'), + ), + migrations.AlterField( + model_name='twitterauthresponse', + name='twitter_voters_access_token_secret', + field=models.TextField(blank=True, null=True, verbose_name='twitter access token secret'), + ), + ] diff --git a/import_export_vote_smart/migrations/0001_initial.py b/import_export_vote_smart/migrations/0001_initial.py new file mode 100644 index 000000000..29f62c043 --- /dev/null +++ b/import_export_vote_smart/migrations/0001_initial.py @@ -0,0 +1,230 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='VoteSmartApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to vote smart')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteSmartApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to vote smart')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteSmartApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to vote smart')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteSmartApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to vote smart')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteSmartCandidate', + fields=[ + ('candidateId', models.CharField(max_length=15, primary_key=True, serialize=False)), + ('firstName', models.CharField(max_length=255)), + ('nickName', models.CharField(max_length=255)), + ('middleName', models.CharField(max_length=255)), + ('preferredName', models.CharField(max_length=255)), + ('lastName', models.CharField(max_length=255)), + ('suffix', models.CharField(max_length=255)), + ('title', models.CharField(max_length=255)), + ('ballotName', models.CharField(max_length=255)), + ('electionParties', models.CharField(max_length=255)), + ('electionStatus', models.CharField(max_length=255)), + ('electionStage', models.CharField(max_length=255)), + ('electionDistrictId', models.CharField(max_length=255)), + ('electionDistrictName', models.CharField(max_length=255)), + ('electionOffice', models.CharField(max_length=255)), + ('electionOfficeId', models.CharField(max_length=255)), + ('electionStateId', models.CharField(max_length=255)), + ('electionOfficeTypeId', models.CharField(max_length=255)), + ('electionYear', models.CharField(max_length=255)), + ('electionSpecial', models.CharField(max_length=255)), + ('electionDate', models.CharField(max_length=255)), + ('officeParties', models.CharField(max_length=255)), + ('officeStatus', models.CharField(max_length=255)), + ('officeDistrictId', models.CharField(max_length=255)), + ('officeDistrictName', models.CharField(max_length=255)), + ('officeStateId', models.CharField(max_length=255)), + ('officeId', models.CharField(max_length=255)), + ('officeName', models.CharField(max_length=255)), + ('officeTypeId', models.CharField(max_length=255)), + ('runningMateId', models.CharField(max_length=255)), + ('runningMateName', models.CharField(max_length=255)), + ], + ), + migrations.CreateModel( + name='VoteSmartCandidateBio', + fields=[ + ('candidateId', models.CharField(max_length=15, primary_key=True, serialize=False)), + ('crpId', models.CharField(max_length=15)), + ('firstName', models.CharField(max_length=255)), + ('nickName', models.CharField(max_length=255)), + ('middleName', models.CharField(max_length=255)), + ('lastName', models.CharField(max_length=255)), + ('preferredName', models.CharField(max_length=255)), + ('suffix', models.CharField(max_length=255)), + ('birthDate', models.CharField(max_length=255)), + ('birthPlace', models.CharField(max_length=255)), + ('pronunciation', models.CharField(max_length=255)), + ('gender', models.CharField(max_length=255)), + ('family', models.CharField(max_length=255)), + ('photo', models.CharField(max_length=255)), + ('homeCity', models.CharField(max_length=255)), + ('homeState', models.CharField(max_length=255)), + ('religion', models.CharField(max_length=255)), + ('education', models.CharField(max_length=255)), + ], + ), + migrations.CreateModel( + name='VoteSmartCategory', + fields=[ + ('categoryId', models.CharField(max_length=15, primary_key=True, serialize=False)), + ('name', models.CharField(max_length=255)), + ], + ), + migrations.CreateModel( + name='VoteSmartOfficial', + fields=[ + ('candidateId', models.CharField(max_length=15, primary_key=True, serialize=False)), + ('firstName', models.CharField(max_length=255)), + ('nickName', models.CharField(max_length=255)), + ('middleName', models.CharField(max_length=255)), + ('lastName', models.CharField(max_length=255)), + ('suffix', models.CharField(max_length=255)), + ('title', models.CharField(max_length=255)), + ('electionParties', models.CharField(max_length=255)), + ('officeParties', models.CharField(max_length=255)), + ('officeStatus', models.CharField(max_length=255)), + ('officeDistrictId', models.CharField(max_length=255)), + ('officeDistrictName', models.CharField(max_length=255)), + ('officeTypeId', models.CharField(max_length=255)), + ('officeId', models.CharField(max_length=255)), + ('officeName', models.CharField(max_length=255)), + ('officeStateId', models.CharField(max_length=255)), + ], + ), + migrations.CreateModel( + name='VoteSmartRating', + fields=[ + ('ratingId', models.CharField(max_length=15, primary_key=True, serialize=False)), + ('sigId', models.CharField(max_length=15, verbose_name='special interest group id')), + ('timeSpan', models.CharField(max_length=255)), + ('ratingName', models.CharField(max_length=255)), + ('ratingText', models.TextField()), + ], + ), + migrations.CreateModel( + name='VoteSmartRatingCategoryLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('ratingId', models.CharField(max_length=15)), + ('sigId', models.CharField(max_length=15, verbose_name='group id for this rating')), + ('candidateId', models.CharField(max_length=15, verbose_name='vote smart candidate id for this rating')), + ('timeSpan', models.CharField(max_length=255)), + ('categoryId', models.CharField(max_length=15, verbose_name='category id for this rating')), + ('categoryName', models.CharField(max_length=255, verbose_name='category name')), + ], + ), + migrations.CreateModel( + name='VoteSmartRatingOneCandidate', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('ratingId', models.CharField(max_length=15)), + ('sigId', models.CharField(max_length=15, verbose_name='special interest group id')), + ('candidateId', models.CharField(max_length=15)), + ('timeSpan', models.CharField(max_length=255)), + ('rating', models.CharField(max_length=255)), + ('ratingName', models.CharField(max_length=255)), + ('ratingText', models.TextField()), + ], + ), + migrations.CreateModel( + name='VoteSmartSpecialInterestGroup', + fields=[ + ('sigId', models.CharField(max_length=15, primary_key=True, serialize=False, verbose_name='special interest group id')), + ('parentId', models.CharField(max_length=15)), + ('stateId', models.CharField(max_length=2)), + ('name', models.CharField(max_length=255, verbose_name='name of special interest group')), + ('description', models.TextField()), + ('address', models.TextField()), + ('city', models.CharField(max_length=255)), + ('state', models.CharField(max_length=255)), + ('zip', models.CharField(max_length=255)), + ('phone1', models.CharField(max_length=255)), + ('phone2', models.CharField(max_length=255)), + ('fax', models.CharField(max_length=255)), + ('email', models.CharField(max_length=255)), + ('url', models.CharField(max_length=255)), + ('contactName', models.CharField(max_length=255)), + ], + ), + migrations.CreateModel( + name='VoteSmartState', + fields=[ + ('stateId', models.CharField(max_length=2, primary_key=True, serialize=False)), + ('name', models.CharField(max_length=50)), + ('senators', models.CharField(max_length=255)), + ('billUrl', models.CharField(max_length=255)), + ('usCircuit', models.CharField(max_length=255)), + ('ltGov', models.CharField(max_length=255)), + ('rollLower', models.CharField(max_length=255)), + ('lowerLegis', models.CharField(max_length=255)), + ('voterReg', models.CharField(max_length=255)), + ('flower', models.CharField(max_length=255)), + ('area', models.CharField(max_length=255)), + ('upperLegis', models.CharField(max_length=255)), + ('termLength', models.CharField(max_length=255)), + ('bicameral', models.CharField(max_length=255)), + ('capital', models.CharField(max_length=255)), + ('voteUrl', models.CharField(max_length=255)), + ('nickName', models.CharField(max_length=255)), + ('bird', models.CharField(max_length=255)), + ('highPoint', models.CharField(max_length=255)), + ('termLimit', models.CharField(max_length=255)), + ('lowPoint', models.CharField(max_length=255)), + ('primaryDate', models.CharField(max_length=255)), + ('stateType', models.CharField(max_length=255)), + ('statehood', models.CharField(max_length=255)), + ('reps', models.CharField(max_length=255)), + ('motto', models.CharField(max_length=255)), + ('population', models.CharField(max_length=255)), + ('tree', models.CharField(max_length=255)), + ('generalDate', models.CharField(max_length=255)), + ('rollUpper', models.CharField(max_length=255)), + ('largestCity', models.CharField(max_length=255)), + ], + ), + ] diff --git a/import_export_vote_usa/migrations/0001_initial.py b/import_export_vote_usa/migrations/0001_initial.py new file mode 100644 index 000000000..0385f6a20 --- /dev/null +++ b/import_export_vote_usa/migrations/0001_initial.py @@ -0,0 +1,52 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='VoteUSAApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True, verbose_name='kind of call to Vote USA')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteUSAApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to Vote USA')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteUSAApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to Vote USA')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='VoteUSAApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to Vote USA')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + ] diff --git a/issue/migrations/0001_initial.py b/issue/migrations/0001_initial.py new file mode 100644 index 000000000..c216c5564 --- /dev/null +++ b/issue/migrations/0001_initial.py @@ -0,0 +1,46 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Issue', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this issue')), + ('issue_name', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='name of the issue')), + ('issue_description', models.TextField(blank=True, default='', null=True, verbose_name='description of the issue')), + ('issue_followers_count', models.PositiveIntegerField(blank=True, default=0, verbose_name='number of followers of this issue')), + ('linked_organization_count', models.PositiveIntegerField(blank=True, default=0, verbose_name='number of organizations linked to the issue')), + ('hide_issue', models.BooleanField(default=True)), + ('considered_left', models.BooleanField(default=False)), + ('considered_right', models.BooleanField(default=False)), + ('issue_icon_local_path', models.TextField(blank=True, default='', null=True, verbose_name='path in web app for the issue icon')), + ('we_vote_hosted_image_url_large', models.URLField(blank=True, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_image_url_medium', models.URLField(blank=True, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_image_url_tiny', models.URLField(blank=True, null=True, verbose_name='we vote hosted tiny image url')), + ], + ), + migrations.CreateModel( + name='OrganizationLinkToIssue', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('issue_id', models.PositiveIntegerField(blank=True, null=True)), + ('issue_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ('link_active', models.BooleanField(default=True, verbose_name='')), + ('reason_for_link', models.CharField(choices=[('NO_REASON', 'No reason'), ('LINKED_BY_ORGANIZATION', 'Linked by organization'), ('LINKED_BY_WE_VOTE', 'Linked by We Vote'), ('AUTO_LINKED_BY_HASHTAG', 'Auto-linked by hashtag'), ('AUTO_LINKED_BY_TEXT', 'Auto-linked by text')], default='NO_REASON', max_length=25)), + ('link_blocked', models.BooleanField(default=False, verbose_name='')), + ('reason_link_is_blocked', models.CharField(choices=[('NO_REASON', 'No reason'), ('BLOCKED_BY_ORGANIZATION', 'Blocked by organization'), ('BLOCKED_BY_WE_VOTE', 'Blocked by We Vote'), ('FLAGGED_BY_VOTERS', 'Flagged by voters')], default='NO_REASON', max_length=25)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/issue/migrations/0002_issue_forced_sort_order.py b/issue/migrations/0002_issue_forced_sort_order.py new file mode 100644 index 000000000..31396efe5 --- /dev/null +++ b/issue/migrations/0002_issue_forced_sort_order.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.17 on 2023-02-22 22:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('issue', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='issue', + name='forced_sort_order', + field=models.PositiveIntegerField(default=None, null=True), + ), + ] diff --git a/issue/migrations/0003_alter_organizationlinktoissue_link_active.py b/issue/migrations/0003_alter_organizationlinktoissue_link_active.py new file mode 100644 index 000000000..6117ab495 --- /dev/null +++ b/issue/migrations/0003_alter_organizationlinktoissue_link_active.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 01:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('issue', '0002_issue_forced_sort_order'), + ] + + operations = [ + migrations.AlterField( + model_name='organizationlinktoissue', + name='link_active', + field=models.BooleanField(db_index=True, default=True, verbose_name=''), + ), + ] diff --git a/issue/migrations/0004_alter_issue_we_vote_id.py b/issue/migrations/0004_alter_issue_we_vote_id.py new file mode 100644 index 000000000..43f7389a6 --- /dev/null +++ b/issue/migrations/0004_alter_issue_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('issue', '0003_alter_organizationlinktoissue_link_active'), + ] + + operations = [ + migrations.AlterField( + model_name='issue', + name='we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this issue'), + ), + ] diff --git a/issue/migrations/0005_issue_hide_issue_we_vote_id_and_more.py b/issue/migrations/0005_issue_hide_issue_we_vote_id_and_more.py new file mode 100644 index 000000000..b9ddc3fd3 --- /dev/null +++ b/issue/migrations/0005_issue_hide_issue_we_vote_id_and_more.py @@ -0,0 +1,25 @@ +# Generated by Django 5.0.7 on 2024-08-02 15:42 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('issue', '0004_alter_issue_we_vote_id'), + ] + + operations = [ + migrations.AddIndex( + model_name='issue', + index=models.Index(fields=['hide_issue', 'we_vote_id'], name='hide_issue_we_vote_id'), + ), + migrations.AddIndex( + model_name='organizationlinktoissue', + index=models.Index(fields=['organization_we_vote_id', 'link_active'], name='organization_and_link_active'), + ), + migrations.AddIndex( + model_name='organizationlinktoissue', + index=models.Index(fields=['issue_we_vote_id', 'organization_we_vote_id', 'link_active'], name='issue_org_link_active'), + ), + ] diff --git a/issue/migrations/0006_remove_organizationlinktoissue_issue_org_link_active_and_more.py b/issue/migrations/0006_remove_organizationlinktoissue_issue_org_link_active_and_more.py new file mode 100644 index 000000000..91750ced1 --- /dev/null +++ b/issue/migrations/0006_remove_organizationlinktoissue_issue_org_link_active_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.8 on 2024-09-01 18:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('issue', '0005_issue_hide_issue_we_vote_id_and_more'), + ] + + operations = [ + migrations.RemoveIndex( + model_name='organizationlinktoissue', + name='issue_org_link_active', + ), + migrations.AddIndex( + model_name='organizationlinktoissue', + index=models.Index(fields=['organization_we_vote_id', 'issue_we_vote_id', 'link_active'], name='org_issue_link_active'), + ), + ] diff --git a/measure/migrations/0001_initial.py b/measure/migrations/0001_initial.py new file mode 100644 index 000000000..3fc582601 --- /dev/null +++ b/measure/migrations/0001_initial.py @@ -0,0 +1,92 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='ContestMeasure', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('maplight_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('vote_smart_id', models.CharField(blank=True, db_index=True, max_length=200, null=True)), + ('measure_title', models.CharField(max_length=255, verbose_name='measure title')), + ('date_last_updated', models.DateTimeField(auto_now=True, null=True)), + ('google_civic_measure_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure name exactly as received from google civic')), + ('google_civic_measure_title2', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure name from google civic alternative')), + ('google_civic_measure_title3', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure name from google civic alternative')), + ('google_civic_measure_title4', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure name from google civic alternative')), + ('google_civic_measure_title5', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure name from google civic alternative')), + ('measure_subtitle', models.TextField(blank=True, default='', null=True, verbose_name='google civic referendum subtitle')), + ('measure_text', models.TextField(null=True, verbose_name='measure text')), + ('measure_url', models.CharField(max_length=255, null=True, verbose_name='measure details url')), + ('google_ballot_placement', models.BigIntegerField(blank=True, null=True, verbose_name='the order this item should appear on the ballot')), + ('google_civic_election_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='google civic election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id new')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='primary party')), + ('district_name', models.CharField(max_length=255, verbose_name='district name')), + ('district_scope', models.CharField(max_length=255, verbose_name='district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('measure_ultimate_election_date', models.PositiveIntegerField(default=None, null=True)), + ('measure_year', models.PositiveIntegerField(default=None, null=True)), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='state this measure affects')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of wikipedia logo')), + ('ballotpedia_district_id', models.PositiveIntegerField(default=0, verbose_name='ballotpedia district id')), + ('ballotpedia_election_id', models.PositiveIntegerField(default=0, verbose_name='ballotpedia election id')), + ('ballotpedia_measure_id', models.PositiveIntegerField(db_index=True, default=0)), + ('ballotpedia_measure_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia measure name')), + ('ballotpedia_measure_status', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia measure status')), + ('ballotpedia_measure_summary', models.TextField(blank=True, default='', null=True, verbose_name='ballotpedia measure summary')), + ('ballotpedia_measure_text', models.TextField(blank=True, default='', null=True, verbose_name='ballotpedia measure text')), + ('ballotpedia_measure_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='ballotpedia url of measure')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of ballotpedia logo')), + ('ballotpedia_yes_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a yes vote means')), + ('ballotpedia_no_vote_description', models.TextField(blank=True, default=None, null=True, verbose_name='what a no vote means')), + ('ctcl_uuid', models.CharField(blank=True, db_index=True, max_length=36, null=True)), + ('position_dates_set', models.BooleanField(default=False)), + ('vote_usa_measure_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='ContestMeasuresAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('contest_measure1_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='first contest measure we are tracking')), + ('contest_measure2_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='second contest measure we are tracking')), + ], + ), + migrations.CreateModel( + name='MeasureCampaign', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('contest_measure_id', models.CharField(max_length=255, verbose_name='contest_measure unique id')), + ('stance', models.CharField(choices=[('S', 'Support'), ('N', 'Neutral'), ('O', 'Oppose')], default='N', max_length=1, verbose_name='stance')), + ('candidate_name', models.CharField(max_length=255, verbose_name='candidate name')), + ('party', models.CharField(blank=True, max_length=255, null=True, verbose_name='party')), + ('photo_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='photoUrl')), + ('google_civic_election_id', models.CharField(max_length=255, verbose_name='google election id')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google election id')), + ('url', models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of campaign')), + ('facebook_url', models.URLField(blank=True, null=True, verbose_name='facebook url of campaign')), + ('twitter_url', models.URLField(blank=True, null=True, verbose_name='twitter url of campaign')), + ('google_plus_url', models.URLField(blank=True, null=True, verbose_name='google plus url of campaign')), + ('youtube_url', models.URLField(blank=True, null=True, verbose_name='youtube url of campaign')), + ('measure_email', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure email')), + ('measure_phone', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure phone')), + ], + ), + ] diff --git a/measure/migrations/0002_alter_measurecampaign_url.py b/measure/migrations/0002_alter_measurecampaign_url.py new file mode 100644 index 000000000..313ab1fbe --- /dev/null +++ b/measure/migrations/0002_alter_measurecampaign_url.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('measure', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='measurecampaign', + name='url', + field=models.TextField(null=True, verbose_name='website url of campaign'), + ), + ] diff --git a/measure/migrations/0003_alter_contestmeasuresarenotduplicates_contest_measure1_we_vote_id_and_more.py b/measure/migrations/0003_alter_contestmeasuresarenotduplicates_contest_measure1_we_vote_id_and_more.py new file mode 100644 index 000000000..b401c17b2 --- /dev/null +++ b/measure/migrations/0003_alter_contestmeasuresarenotduplicates_contest_measure1_we_vote_id_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('measure', '0002_alter_measurecampaign_url'), + ] + + operations = [ + migrations.AlterField( + model_name='contestmeasuresarenotduplicates', + name='contest_measure1_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='first contest measure we are tracking'), + ), + migrations.AlterField( + model_name='contestmeasuresarenotduplicates', + name='contest_measure2_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='second contest measure we are tracking'), + ), + migrations.AlterField( + model_name='measurecampaign', + name='we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id'), + ), + ] diff --git a/measure/migrations/0004_alter_contestmeasure_ballotpedia_measure_name_and_more.py b/measure/migrations/0004_alter_contestmeasure_ballotpedia_measure_name_and_more.py new file mode 100644 index 000000000..4270b6fc4 --- /dev/null +++ b/measure/migrations/0004_alter_contestmeasure_ballotpedia_measure_name_and_more.py @@ -0,0 +1,58 @@ +# Generated by Django 5.0.8 on 2024-09-17 14:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('measure', '0003_alter_contestmeasuresarenotduplicates_contest_measure1_we_vote_id_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='contestmeasure', + name='ballotpedia_measure_name', + field=models.TextField(blank=True, null=True, verbose_name='ballotpedia measure name'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='ballotpedia_measure_url', + field=models.TextField(blank=True, null=True, verbose_name='ballotpedia url of measure'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='google_civic_measure_title', + field=models.TextField(blank=True, null=True, verbose_name='measure name exactly as received from google civic'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='google_civic_measure_title2', + field=models.TextField(blank=True, null=True, verbose_name='measure name from google civic alternative'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='google_civic_measure_title3', + field=models.TextField(blank=True, null=True, verbose_name='measure name from google civic alternative'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='google_civic_measure_title4', + field=models.TextField(blank=True, null=True, verbose_name='measure name from google civic alternative'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='google_civic_measure_title5', + field=models.TextField(blank=True, null=True, verbose_name='measure name from google civic alternative'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='measure_title', + field=models.TextField(verbose_name='measure title'), + ), + migrations.AlterField( + model_name='contestmeasure', + name='measure_url', + field=models.TextField(null=True, verbose_name='measure details url'), + ), + ] diff --git a/office/migrations/0001_initial.py b/office/migrations/0001_initial.py new file mode 100644 index 000000000..5602c3366 --- /dev/null +++ b/office/migrations/0001_initial.py @@ -0,0 +1,82 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='ContestOffice', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id for this contest office')), + ('office_name', models.CharField(max_length=255, verbose_name='name of the office')), + ('date_last_updated', models.DateTimeField(auto_now=True, null=True)), + ('google_civic_office_name', models.CharField(max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_office_name2', models.CharField(max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_office_name3', models.CharField(max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_office_name4', models.CharField(max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_office_name5', models.CharField(max_length=255, null=True, verbose_name='office name exactly as received from google civic')), + ('google_civic_election_id', models.CharField(db_index=True, max_length=255, verbose_name='google civic election id')), + ('google_ballot_placement', models.BigIntegerField(blank=True, null=True, verbose_name='the order this item should appear on the ballot')), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='state this office serves')), + ('google_civic_election_id_new', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('maplight_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True)), + ('vote_usa_office_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True)), + ('ballotpedia_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('ballotpedia_election_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia election id')), + ('ballotpedia_is_marquee', models.BooleanField(default=None, null=True)), + ('is_battleground_race', models.BooleanField(default=None, null=True)), + ('is_ballotpedia_general_election', models.BooleanField(default=False)), + ('is_ballotpedia_general_runoff_election', models.BooleanField(default=False)), + ('is_ballotpedia_primary_election', models.BooleanField(default=False)), + ('is_ballotpedia_primary_runoff_election', models.BooleanField(default=False)), + ('ballotpedia_office_id', models.PositiveIntegerField(blank=True, db_index=True, null=True)), + ('ballotpedia_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='office name exactly as received from ballotpedia')), + ('ballotpedia_office_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of office on ballotpedia')), + ('ballotpedia_race_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of race on ballotpedia')), + ('ballotpedia_district_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia district id')), + ('ballotpedia_race_id', models.PositiveIntegerField(blank=True, db_index=True, null=True)), + ('ballotpedia_race_office_level', models.CharField(blank=True, max_length=255, null=True, verbose_name='race office level')), + ('wikipedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='wikipedia unique identifier')), + ('number_voting_for', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates to vote for')), + ('number_elected', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates who will be elected')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('district_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='district name')), + ('district_scope', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('contest_level0', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 0')), + ('contest_level1', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 1')), + ('contest_level2', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 2')), + ('electorate_specifications', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('special', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('ctcl_uuid', models.CharField(blank=True, db_index=True, max_length=36, null=True)), + ('elected_office_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the elected office')), + ], + ), + migrations.CreateModel( + name='ContestOfficesAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('contest_office1_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='first contest office we are tracking')), + ('contest_office2_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='second contest office we are tracking')), + ], + ), + migrations.CreateModel( + name='ContestOfficeVisitingOtherElection', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('contest_office_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='contest office we are tracking')), + ('ballotpedia_race_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia integer id')), + ('host_google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id of election the office is visiting')), + ('origin_google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id where the office first originated')), + ], + ), + ] diff --git a/office/migrations/0002_contestoffice_is_battleground_race_cached_in_candidates.py b/office/migrations/0002_contestoffice_is_battleground_race_cached_in_candidates.py new file mode 100644 index 000000000..93f5e901b --- /dev/null +++ b/office/migrations/0002_contestoffice_is_battleground_race_cached_in_candidates.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2023-01-02 06:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='contestoffice', + name='is_battleground_race_cached_in_candidates', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/office/migrations/0003_auto_20230110_0710.py b/office/migrations/0003_auto_20230110_0710.py new file mode 100644 index 000000000..65eea87cd --- /dev/null +++ b/office/migrations/0003_auto_20230110_0710.py @@ -0,0 +1,22 @@ +# Generated by Django 3.2.16 on 2023-01-10 15:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0002_contestoffice_is_battleground_race_cached_in_candidates'), + ] + + operations = [ + migrations.RemoveField( + model_name='contestoffice', + name='elected_office_name', + ), + migrations.AddField( + model_name='contestoffice', + name='office_held_name', + field=models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the office held'), + ), + ] diff --git a/office/migrations/0004_contestoffice_office_held_we_vote_id.py b/office/migrations/0004_contestoffice_office_held_we_vote_id.py new file mode 100644 index 000000000..e4767429c --- /dev/null +++ b/office/migrations/0004_contestoffice_office_held_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.17 on 2023-02-22 22:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0003_auto_20230110_0710'), + ] + + operations = [ + migrations.AddField( + model_name='contestoffice', + name='office_held_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + ] diff --git a/office/migrations/0005_remove_contestoffice_is_battleground_race_cached_in_candidates.py b/office/migrations/0005_remove_contestoffice_is_battleground_race_cached_in_candidates.py new file mode 100644 index 000000000..6759005dc --- /dev/null +++ b/office/migrations/0005_remove_contestoffice_is_battleground_race_cached_in_candidates.py @@ -0,0 +1,17 @@ +# Generated by Django 3.2.18 on 2023-03-07 00:49 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0004_contestoffice_office_held_we_vote_id'), + ] + + operations = [ + migrations.RemoveField( + model_name='contestoffice', + name='is_battleground_race_cached_in_candidates', + ), + ] diff --git a/office/migrations/0006_contestoffice_is_battleground_race_spread_to_all_objects.py b/office/migrations/0006_contestoffice_is_battleground_race_spread_to_all_objects.py new file mode 100644 index 000000000..2edd1331c --- /dev/null +++ b/office/migrations/0006_contestoffice_is_battleground_race_spread_to_all_objects.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-07 00:52 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0005_remove_contestoffice_is_battleground_race_cached_in_candidates'), + ] + + operations = [ + migrations.AddField( + model_name='contestoffice', + name='is_battleground_race_spread_to_all_objects', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/office/migrations/0007_auto_20230419_1557.py b/office/migrations/0007_auto_20230419_1557.py new file mode 100644 index 000000000..1701fb6bc --- /dev/null +++ b/office/migrations/0007_auto_20230419_1557.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.18 on 2023-04-19 22:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0006_contestoffice_is_battleground_race_spread_to_all_objects'), + ] + + operations = [ + migrations.AddField( + model_name='contestoffice', + name='facebook_url_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='contestoffice', + name='office_facebook_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='contestoffice', + name='office_held_description', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='office_held description'), + ), + migrations.AddField( + model_name='contestoffice', + name='office_held_description_es', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='office_held description in Spanish'), + ), + migrations.AddField( + model_name='contestoffice', + name='office_held_name_es', + field=models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the office held in Spanish'), + ), + migrations.AddField( + model_name='contestoffice', + name='office_twitter_handle', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='contestoffice', + name='office_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/office/migrations/0008_auto_20230531_0902.py b/office/migrations/0008_auto_20230531_0902.py new file mode 100644 index 000000000..8ac87260f --- /dev/null +++ b/office/migrations/0008_auto_20230531_0902.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-05-31 16:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0007_auto_20230419_1557'), + ] + + operations = [ + migrations.AlterField( + model_name='contestoffice', + name='office_held_description', + field=models.TextField(blank=True, null=True, verbose_name='office_held description'), + ), + migrations.AlterField( + model_name='contestoffice', + name='office_held_description_es', + field=models.TextField(blank=True, null=True, verbose_name='office_held description in Spanish'), + ), + ] diff --git a/office/migrations/0009_contestoffice_election_date_as_integer.py b/office/migrations/0009_contestoffice_election_date_as_integer.py new file mode 100644 index 000000000..cd6a15bac --- /dev/null +++ b/office/migrations/0009_contestoffice_election_date_as_integer.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-06-10 13:03 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0008_auto_20230531_0902'), + ] + + operations = [ + migrations.AddField( + model_name='contestoffice', + name='election_date_as_integer', + field=models.PositiveIntegerField(db_index=True, null=True), + ), + ] diff --git a/office/migrations/0010_alter_contestofficesarenotduplicates_contest_office1_we_vote_id_and_more.py b/office/migrations/0010_alter_contestofficesarenotduplicates_contest_office1_we_vote_id_and_more.py new file mode 100644 index 000000000..86d8167fe --- /dev/null +++ b/office/migrations/0010_alter_contestofficesarenotduplicates_contest_office1_we_vote_id_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0009_contestoffice_election_date_as_integer'), + ] + + operations = [ + migrations.AlterField( + model_name='contestofficesarenotduplicates', + name='contest_office1_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='first contest office we are tracking'), + ), + migrations.AlterField( + model_name='contestofficesarenotduplicates', + name='contest_office2_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='second contest office we are tracking'), + ), + migrations.AlterField( + model_name='contestofficevisitingotherelection', + name='contest_office_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='contest office we are tracking'), + ), + ] diff --git a/office/migrations/0011_alter_contestoffice_we_vote_id_and_more.py b/office/migrations/0011_alter_contestoffice_we_vote_id_and_more.py new file mode 100644 index 000000000..5c9d9e086 --- /dev/null +++ b/office/migrations/0011_alter_contestoffice_we_vote_id_and_more.py @@ -0,0 +1,22 @@ +# Generated by Django 5.0.8 on 2024-09-04 18:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0010_alter_contestofficesarenotduplicates_contest_office1_we_vote_id_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='contestoffice', + name='we_vote_id', + field=models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id for this contest office'), + ), + migrations.AddIndex( + model_name='contestoffice', + index=models.Index(fields=['we_vote_id'], name='contest_office_id_index'), + ), + ] diff --git a/office/migrations/0012_contestoffice_office_explanation_we_vote_id_and_more.py b/office/migrations/0012_contestoffice_office_explanation_we_vote_id_and_more.py new file mode 100644 index 000000000..8db3ce527 --- /dev/null +++ b/office/migrations/0012_contestoffice_office_explanation_we_vote_id_and_more.py @@ -0,0 +1,35 @@ +# Generated by Django 5.0.13 on 2026-01-18 15:32 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office', '0011_alter_contestoffice_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='contestoffice', + name='office_explanation_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.CreateModel( + name='OfficeExplanation', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_last_updated', models.DateTimeField(auto_now=True, null=True)), + ('office_explanation', models.TextField(null=True)), + ('office_explanation_name', models.CharField(max_length=255)), + ('state_code', models.CharField(max_length=2, null=True)), + ('video_url_horizontal', models.TextField(null=True)), + ('video_url_square', models.TextField(null=True)), + ('video_url_vertical', models.TextField(null=True)), + ('we_vote_id', models.CharField(default=None, max_length=255, null=True, unique=True)), + ], + options={ + 'indexes': [models.Index(fields=['we_vote_id'], name='office_explanation_index')], + }, + ), + ] diff --git a/office_held/migrations/0001_initial.py b/office_held/migrations/0001_initial.py new file mode 100644 index 000000000..fd54f587f --- /dev/null +++ b/office_held/migrations/0001_initial.py @@ -0,0 +1,44 @@ +# Generated by Django 3.2.16 on 2023-01-10 15:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='OfficeHeld', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id for this office held')), + ('office_held_name', models.CharField(max_length=255, verbose_name='name of the office held')), + ('office_held_name_es', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='name of the office held in Spanish')), + ('google_civic_office_held_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='office_held name exactly as received from google civic')), + ('google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('maplight_id', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='maplight unique identifier')), + ('ballotpedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ballotpedia unique identifier')), + ('wikipedia_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='wikipedia unique identifier')), + ('number_elected', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic number of candidates who will be elected')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this office_held serves')), + ('primary_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('district_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='district name')), + ('district_scope', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district scope')), + ('district_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic district id')), + ('contest_level0', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 0')), + ('contest_level1', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 1')), + ('contest_level2', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic level, option 2')), + ('electorate_specifications', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('special', models.CharField(blank=True, max_length=255, null=True, verbose_name='google civic primary party')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('office_held_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='office_held description')), + ('office_held_description_es', models.CharField(blank=True, max_length=255, null=True, verbose_name='office_held description in Spanish')), + ('office_held_is_partisan', models.BooleanField(default=False, verbose_name='office_held is_partisan')), + ], + ), + ] diff --git a/office_held/migrations/0002_auto_20230126_1420.py b/office_held/migrations/0002_auto_20230126_1420.py new file mode 100644 index 000000000..89de0c644 --- /dev/null +++ b/office_held/migrations/0002_auto_20230126_1420.py @@ -0,0 +1,209 @@ +# Generated by Django 3.2.16 on 2023-01-26 22:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='ContestOfficeToOfficeHeldLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('contest_office_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('office_held_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('contest_office_year', models.PositiveIntegerField(default=0)), + ], + ), + migrations.CreateModel( + name='OfficesHeldForLocation', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_last_retrieved', models.DateField(null=True)), + ('office_held_name_01', models.CharField(max_length=255, null=True)), + ('office_held_name_02', models.CharField(max_length=255, null=True)), + ('office_held_name_03', models.CharField(max_length=255, null=True)), + ('office_held_name_04', models.CharField(max_length=255, null=True)), + ('office_held_name_05', models.CharField(max_length=255, null=True)), + ('office_held_name_06', models.CharField(max_length=255, null=True)), + ('office_held_name_07', models.CharField(max_length=255, null=True)), + ('office_held_name_08', models.CharField(max_length=255, null=True)), + ('office_held_name_09', models.CharField(max_length=255, null=True)), + ('office_held_name_10', models.CharField(max_length=255, null=True)), + ('office_held_name_11', models.CharField(max_length=255, null=True)), + ('office_held_name_12', models.CharField(max_length=255, null=True)), + ('office_held_name_13', models.CharField(max_length=255, null=True)), + ('office_held_name_14', models.CharField(max_length=255, null=True)), + ('office_held_name_15', models.CharField(max_length=255, null=True)), + ('office_held_name_16', models.CharField(max_length=255, null=True)), + ('office_held_name_17', models.CharField(max_length=255, null=True)), + ('office_held_name_18', models.CharField(max_length=255, null=True)), + ('office_held_name_19', models.CharField(max_length=255, null=True)), + ('office_held_name_20', models.CharField(max_length=255, null=True)), + ('office_held_name_21', models.CharField(max_length=255, null=True)), + ('office_held_name_22', models.CharField(max_length=255, null=True)), + ('office_held_name_23', models.CharField(max_length=255, null=True)), + ('office_held_name_24', models.CharField(max_length=255, null=True)), + ('office_held_name_25', models.CharField(max_length=255, null=True)), + ('office_held_name_26', models.CharField(max_length=255, null=True)), + ('office_held_name_27', models.CharField(max_length=255, null=True)), + ('office_held_name_28', models.CharField(max_length=255, null=True)), + ('office_held_name_29', models.CharField(max_length=255, null=True)), + ('office_held_name_30', models.CharField(max_length=255, null=True)), + ('office_held_we_vote_id_01', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_02', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_03', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_04', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_05', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_06', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_07', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_08', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_09', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_10', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_11', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_12', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_13', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_14', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_15', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_16', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_17', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_18', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_19', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_20', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_21', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_22', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_23', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_24', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_25', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_26', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_27', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_28', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_29', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('office_held_we_vote_id_30', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('polling_location_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('years_retrieved_flags', models.PositiveIntegerField(default=0)), + ], + ), + migrations.RemoveField( + model_name='officeheld', + name='ballotpedia_id', + ), + migrations.RemoveField( + model_name='officeheld', + name='contest_level0', + ), + migrations.RemoveField( + model_name='officeheld', + name='contest_level1', + ), + migrations.RemoveField( + model_name='officeheld', + name='contest_level2', + ), + migrations.RemoveField( + model_name='officeheld', + name='ctcl_uuid', + ), + migrations.RemoveField( + model_name='officeheld', + name='electorate_specifications', + ), + migrations.RemoveField( + model_name='officeheld', + name='google_civic_election_id', + ), + migrations.RemoveField( + model_name='officeheld', + name='maplight_id', + ), + migrations.RemoveField( + model_name='officeheld', + name='special', + ), + migrations.RemoveField( + model_name='officeheld', + name='wikipedia_id', + ), + migrations.AddField( + model_name='officeheld', + name='google_civic_office_held_name2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='google_civic_office_held_name3', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_level0', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_level1', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_level2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_role0', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_role1', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_role2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='race_office_level', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='year_with_data_2023', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='year_with_data_2024', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='year_with_data_2025', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='officeheld', + name='year_with_data_2026', + field=models.BooleanField(default=None, null=True), + ), + migrations.AlterField( + model_name='officeheld', + name='google_civic_office_held_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='officeheld', + name='number_elected', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/office_held/migrations/0003_auto_20230201_1248.py b/office_held/migrations/0003_auto_20230201_1248.py new file mode 100644 index 000000000..b94b9398e --- /dev/null +++ b/office_held/migrations/0003_auto_20230201_1248.py @@ -0,0 +1,42 @@ +# Generated by Django 3.2.16 on 2023-02-01 20:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0002_auto_20230126_1420'), + ] + + operations = [ + migrations.RemoveField( + model_name='officesheldforlocation', + name='years_retrieved_flags', + ), + migrations.AddField( + model_name='officesheldforlocation', + name='date_last_updated', + field=models.DateField(auto_now=True, null=True), + ), + migrations.AddField( + model_name='officesheldforlocation', + name='year_with_data_2023', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='officesheldforlocation', + name='year_with_data_2024', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='officesheldforlocation', + name='year_with_data_2025', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='officesheldforlocation', + name='year_with_data_2026', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/office_held/migrations/0004_auto_20230222_1441.py b/office_held/migrations/0004_auto_20230222_1441.py new file mode 100644 index 000000000..308c67bb6 --- /dev/null +++ b/office_held/migrations/0004_auto_20230222_1441.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.17 on 2023-02-22 22:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0003_auto_20230201_1248'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2022', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2023', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2024', + field=models.BooleanField(default=False), + ), + ] diff --git a/office_held/migrations/0005_auto_20230306_1649.py b/office_held/migrations/0005_auto_20230306_1649.py new file mode 100644 index 000000000..eaefcf87b --- /dev/null +++ b/office_held/migrations/0005_auto_20230306_1649.py @@ -0,0 +1,43 @@ +# Generated by Django 3.2.18 on 2023-03-07 00:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0004_auto_20230222_1441'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2019', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2020', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2021', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2025', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='is_battleground_race_2026', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_twitter_handle', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/office_held/migrations/0006_officeheld_office_held_url.py b/office_held/migrations/0006_officeheld_office_held_url.py new file mode 100644 index 000000000..3126f87db --- /dev/null +++ b/office_held/migrations/0006_officeheld_office_held_url.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-11 16:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0005_auto_20230306_1649'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='office_held_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/office_held/migrations/0007_auto_20230311_0908.py b/office_held/migrations/0007_auto_20230311_0908.py new file mode 100644 index 000000000..73468d364 --- /dev/null +++ b/office_held/migrations/0007_auto_20230311_0908.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-03-11 17:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0006_officeheld_office_held_url'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='facebook_url_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='office_held_facebook_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/office_held/migrations/0008_auto_20230423_0727.py b/office_held/migrations/0008_auto_20230423_0727.py new file mode 100644 index 000000000..e7097b011 --- /dev/null +++ b/office_held/migrations/0008_auto_20230423_0727.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-04-23 14:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0007_auto_20230311_0908'), + ] + + operations = [ + migrations.AddField( + model_name='officesheldforlocation', + name='latitude', + field=models.FloatField(null=True, verbose_name='latitude returned from Google'), + ), + migrations.AddField( + model_name='officesheldforlocation', + name='longitude', + field=models.FloatField(null=True, verbose_name='longitude returned from Google'), + ), + ] diff --git a/office_held/migrations/0009_auto_20230531_0902.py b/office_held/migrations/0009_auto_20230531_0902.py new file mode 100644 index 000000000..7703dad48 --- /dev/null +++ b/office_held/migrations/0009_auto_20230531_0902.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-05-31 16:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0008_auto_20230423_0727'), + ] + + operations = [ + migrations.AlterField( + model_name='officeheld', + name='office_held_description', + field=models.TextField(blank=True, null=True, verbose_name='office_held description'), + ), + migrations.AlterField( + model_name='officeheld', + name='office_held_description_es', + field=models.TextField(blank=True, null=True, verbose_name='office_held description in Spanish'), + ), + ] diff --git a/office_held/migrations/0010_auto_20230629_0744.py b/office_held/migrations/0010_auto_20230629_0744.py new file mode 100644 index 000000000..e6d377100 --- /dev/null +++ b/office_held/migrations/0010_auto_20230629_0744.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.19 on 2023-06-29 14:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0009_auto_20230531_0902'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='ocd_id_state_mismatch_checked', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='officeheld', + name='ocd_id_state_mismatch_found', + field=models.BooleanField(default=False), + ), + ] diff --git a/office_held/migrations/0011_auto_20230827_1805.py b/office_held/migrations/0011_auto_20230827_1805.py new file mode 100644 index 000000000..93e3a9182 --- /dev/null +++ b/office_held/migrations/0011_auto_20230827_1805.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.20 on 2023-08-28 01:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0010_auto_20230629_0744'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='is_us_national_house', + field=models.BooleanField(null=True), + ), + migrations.AddField( + model_name='officeheld', + name='is_us_national_senate', + field=models.BooleanField(null=True), + ), + ] diff --git a/office_held/migrations/0012_officeheld_office_explanation_we_vote_id.py b/office_held/migrations/0012_officeheld_office_explanation_we_vote_id.py new file mode 100644 index 000000000..9604ad8b3 --- /dev/null +++ b/office_held/migrations/0012_officeheld_office_explanation_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2026-01-18 15:32 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('office_held', '0011_auto_20230827_1805'), + ] + + operations = [ + migrations.AddField( + model_name='officeheld', + name='office_explanation_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/organization/migrations/0001_initial.py b/organization/migrations/0001_initial.py new file mode 100644 index 000000000..10daf4832 --- /dev/null +++ b/organization/migrations/0001_initial.py @@ -0,0 +1,151 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +import django.core.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Organization', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('organization_name', models.CharField(max_length=255, verbose_name='organization name')), + ('most_recent_name_update_from_voter_first_and_last', models.BooleanField(default=False)), + ('organization_website', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of the endorsing organization')), + ('organization_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='organization contact email address')), + ('organization_contact_form_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of the contact us form')), + ('organization_contact_name', models.CharField(max_length=255, null=True)), + ('organization_facebook', models.URLField(blank=True, null=True, verbose_name='url of facebook page')), + ('organization_image', models.CharField(max_length=255, null=True, verbose_name='organization image')), + ('state_served_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this organization serves')), + ('vote_smart_id', models.BigIntegerField(blank=True, null=True, unique=True, verbose_name='vote smart special interest group id')), + ('organization_description', models.TextField(blank=True, null=True, verbose_name='Text description of this organization.')), + ('organization_address', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization street address')), + ('organization_city', models.CharField(blank=True, max_length=255, null=True)), + ('organization_state', models.CharField(blank=True, max_length=2, null=True)), + ('organization_zip', models.CharField(blank=True, max_length=255, null=True)), + ('organization_phone1', models.CharField(blank=True, max_length=255, null=True)), + ('organization_phone2', models.CharField(blank=True, max_length=255, null=True)), + ('organization_fax', models.CharField(blank=True, max_length=255, null=True)), + ('facebook_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook big integer id')), + ('facebook_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='facebook email address')), + ('fb_username', models.CharField(max_length=50, null=True, unique=True, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z]*$', message='Only alphanumeric characters are allowed.')])), + ('facebook_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of image from facebook')), + ('facebook_background_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of cover image from facebook')), + ('twitter_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter id')), + ('organization_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='organization twitter screen_name')), + ('organization_twitter_updates_failing', models.BooleanField(default=False)), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='org name from twitter')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='org location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of user logo from twitter')), + ('twitter_profile_background_image_url_https', models.TextField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_banner_url_https', models.TextField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('organization_instagram_handle', models.CharField(max_length=255, null=True, verbose_name='organization instagram screen_name')), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True, verbose_name='we vote hosted tiny image url')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_thumbnail_url', models.TextField(blank=True, null=True, verbose_name='url of wikipedia logo thumbnail')), + ('wikipedia_thumbnail_width', models.IntegerField(blank=True, null=True, verbose_name='width of photo')), + ('wikipedia_thumbnail_height', models.IntegerField(blank=True, null=True, verbose_name='height of photo')), + ('wikipedia_photo_url', models.TextField(blank=True, null=True, verbose_name='url of wikipedia logo')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_photo_url', models.TextField(blank=True, null=True, verbose_name='url of ballotpedia logo')), + ('issue_analysis_done', models.BooleanField(default=False)), + ('issue_analysis_admin_notes', models.TextField(blank=True, null=True, verbose_name='we vote admin notes')), + ('organization_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='type of org')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True)), + ('chosen_about_organization_external_url', models.TextField(blank=True, null=True)), + ('chosen_domain_type_is_campaign', models.BooleanField(default=False)), + ('chosen_domain_string', models.CharField(blank=True, max_length=255, null=True, verbose_name='client domain name for we vote site')), + ('chosen_favicon_url_https', models.TextField(blank=True, null=True, verbose_name='url of client favicon')), + ('chosen_google_analytics_tracking_id', models.CharField(blank=True, max_length=255, null=True)), + ('chosen_html_verification_string', models.CharField(blank=True, max_length=255, null=True)), + ('chosen_hide_we_vote_logo', models.BooleanField(default=False)), + ('chosen_logo_url_https', models.TextField(blank=True, null=True, verbose_name='url of client logo')), + ('chosen_organization_api_pass_code', models.TextField(blank=True, null=True)), + ('chosen_prevent_sharing_opinions', models.BooleanField(default=False)), + ('chosen_ready_introduction_title', models.CharField(blank=True, max_length=255, null=True)), + ('chosen_ready_introduction_text', models.TextField(blank=True, null=True)), + ('chosen_social_share_description', models.TextField(blank=True, null=True)), + ('chosen_social_share_master_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of client social share master image')), + ('chosen_social_share_image_256x256_url_https', models.TextField(blank=True, null=True, verbose_name='url of client social share image')), + ('chosen_subdomain_string', models.CharField(blank=True, max_length=255, null=True, verbose_name='client we vote subdomain')), + ('chosen_subscription_plan', models.PositiveIntegerField(default=0, verbose_name='number of the plan client chose')), + ('chosen_website_name', models.CharField(blank=True, max_length=255, null=True)), + ('subscription_plan_end_day_text', models.CharField(blank=True, max_length=8, null=True, verbose_name='paid through day')), + ('subscription_plan_features_active', models.PositiveIntegerField(default=0, verbose_name='features that are active')), + ('chosen_feature_package', models.CharField(blank=True, max_length=255, null=True, verbose_name='plan type {FREE, PROFESSIONAL, ENTERPRISE} that is referred to in MasterFeaturePackage')), + ('features_provided_bitmap', models.PositiveIntegerField(default=0, verbose_name='features that are active')), + ('organization_endorsements_api_url', models.TextField(blank=True, null=True, verbose_name='endorsements importer url')), + ], + options={ + 'ordering': ('organization_name',), + }, + ), + migrations.CreateModel( + name='OrganizationLinkToHashtag', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(max_length=255, verbose_name='we vote permanent id')), + ('hashtag_text', models.CharField(max_length=255, verbose_name='hashtag text')), + ], + ), + migrations.CreateModel( + name='OrganizationLinkToWordOrPhrase', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(max_length=255, unique=True, verbose_name='we vote permanent id')), + ('word_or_phrase_text', models.CharField(max_length=255, verbose_name='text of a word or phrase')), + ('tweet_id', models.BigIntegerField(unique=True, verbose_name='tweet id')), + ('published_datetime', models.DateTimeField(verbose_name='published datetime')), + ('organization_twitter_handle', models.CharField(max_length=15, verbose_name='organization twitter handle')), + ], + ), + migrations.CreateModel( + name='OrganizationMembershipLinkToVoter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(max_length=255, verbose_name='we vote id for organization')), + ('voter_we_vote_id', models.CharField(max_length=255, verbose_name='we vote id for the voter owner')), + ('external_voter_id', models.CharField(max_length=255, verbose_name='id for the voter in other system')), + ], + ), + migrations.CreateModel( + name='OrganizationReservedDomain', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('full_domain_string', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='full domain')), + ('subdomain_string', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='we vote subdomain')), + ], + ), + migrations.CreateModel( + name='OrganizationTeamMember', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('can_edit_campaignx_owned_by_organization', models.BooleanField(default=True)), + ('can_edit_organization', models.BooleanField(default=True)), + ('can_manage_team_members', models.BooleanField(default=False)), + ('can_moderate_campaignx_owned_by_organization', models.BooleanField(default=True)), + ('can_send_updates_for_campaignx_owned_by_organization', models.BooleanField(default=False)), + ('team_member_name', models.CharField(max_length=255)), + ('team_member_organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/organization/migrations/0002_auto_20221007_1756.py b/organization/migrations/0002_auto_20221007_1756.py new file mode 100644 index 000000000..c77d8d3a5 --- /dev/null +++ b/organization/migrations/0002_auto_20221007_1756.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.15 on 2022-10-08 00:56 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='organization', + name='chosen_domain_string2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='organization', + name='chosen_domain_string3', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/organization/migrations/0003_auto_20230210_1159.py b/organization/migrations/0003_auto_20230210_1159.py new file mode 100644 index 000000000..09d7486f6 --- /dev/null +++ b/organization/migrations/0003_auto_20230210_1159.py @@ -0,0 +1,133 @@ +# Generated by Django 3.2.17 on 2023-02-10 19:59 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0002_auto_20221007_1756'), + ] + + operations = [ + migrations.AddField( + model_name='organization', + name='facebook_url_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='organization', + name='instagram_followers_count', + field=models.IntegerField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='politician_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='organization', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('FACEBOOK', 'Facebook'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA')], default='UNKNOWN', max_length=10), + ), + migrations.AddField( + model_name='organization', + name='twitter_handle2_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='organization', + name='twitter_handle_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_facebook_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_facebook_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_facebook_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_twitter_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_twitter_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_twitter_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_uploaded_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_uploaded_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_uploaded_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_vote_usa_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_vote_usa_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='we_vote_hosted_profile_vote_usa_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='wikipedia_url', + field=models.TextField(null=True), + ), + migrations.AddField( + model_name='organization', + name='youtube_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='organization', + name='organization_facebook', + field=models.URLField(blank=True, null=True), + ), + migrations.AlterField( + model_name='organization', + name='we_vote_hosted_profile_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='organization', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='organization', + name='we_vote_hosted_profile_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/organization/migrations/0004_organizationchangelog.py b/organization/migrations/0004_organizationchangelog.py new file mode 100644 index 000000000..672bce6fd --- /dev/null +++ b/organization/migrations/0004_organizationchangelog.py @@ -0,0 +1,25 @@ +# Generated by Django 3.2.18 on 2023-03-12 21:04 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0003_auto_20230210_1159'), + ] + + operations = [ + migrations.CreateModel( + name='OrganizationChangeLog', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('changed_by_name', models.CharField(default=None, max_length=255, null=True)), + ('changed_by_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('change_description', models.TextField(blank=True, null=True)), + ('log_datetime', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('status', models.TextField(blank=True, null=True)), + ], + ), + ] diff --git a/organization/migrations/0005_auto_20230804_1408.py b/organization/migrations/0005_auto_20230804_1408.py new file mode 100644 index 000000000..940ff1c99 --- /dev/null +++ b/organization/migrations/0005_auto_20230804_1408.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.20 on 2023-08-04 21:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0004_organizationchangelog'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='chosen_domain_string', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='client domain name for we vote site'), + ), + migrations.AlterField( + model_name='organization', + name='chosen_domain_string2', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organization', + name='chosen_domain_string3', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + ] diff --git a/organization/migrations/0006_auto_20240129_0555.py b/organization/migrations/0006_auto_20240129_0555.py new file mode 100644 index 000000000..5b477928b --- /dev/null +++ b/organization/migrations/0006_auto_20240129_0555.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.23 on 2024-01-29 13:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0005_auto_20230804_1408'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='organization_instagram_handle', + field=models.CharField(max_length=255, null=True, verbose_name='organization instagram username'), + ), + migrations.AlterField( + model_name='organization', + name='organization_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='organization twitter username'), + ), + ] diff --git a/organization/migrations/0007_alter_organization_profile_image_type_currently_active.py b/organization/migrations/0007_alter_organization_profile_image_type_currently_active.py new file mode 100644 index 000000000..81a43ef1b --- /dev/null +++ b/organization/migrations/0007_alter_organization_profile_image_type_currently_active.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2024-02-11 02:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0006_auto_20240129_0555'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('BALLOTPEDIA', 'Ballotpedia'), ('FACEBOOK', 'Facebook'), ('LINKEDIN', 'LinkedIn'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA'), ('WIKIPEDIA', 'Wikipedia')], default='UNKNOWN', max_length=11), + ), + ] diff --git a/organization/migrations/0008_organization_facebook_photo_url_and_more.py b/organization/migrations/0008_organization_facebook_photo_url_and_more.py new file mode 100644 index 000000000..d0afe282a --- /dev/null +++ b/organization/migrations/0008_organization_facebook_photo_url_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-05-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0007_alter_organization_profile_image_type_currently_active'), + ] + + operations = [ + migrations.AddField( + model_name='organization', + name='facebook_photo_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='facebook_photo_url_is_placeholder', + field=models.BooleanField(default=False), + ), + ] diff --git a/organization/migrations/0009_alter_organization_organization_contact_form_url_and_more.py b/organization/migrations/0009_alter_organization_organization_contact_form_url_and_more.py new file mode 100644 index 000000000..8e5a1e779 --- /dev/null +++ b/organization/migrations/0009_alter_organization_organization_contact_form_url_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0008_organization_facebook_photo_url_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='organization_contact_form_url', + field=models.TextField(null=True, verbose_name='url of the contact us form'), + ), + migrations.AlterField( + model_name='organization', + name='organization_website', + field=models.TextField(null=True, verbose_name='url of the endorsing organization'), + ), + ] diff --git a/organization/migrations/0010_alter_organization_organization_facebook.py b/organization/migrations/0010_alter_organization_organization_facebook.py new file mode 100644 index 000000000..7814f1f38 --- /dev/null +++ b/organization/migrations/0010_alter_organization_organization_facebook.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-08 01:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0009_alter_organization_organization_contact_form_url_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='organization_facebook', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/organization/migrations/0011_alter_organization_organization_instagram_handle_and_more.py b/organization/migrations/0011_alter_organization_organization_instagram_handle_and_more.py new file mode 100644 index 000000000..a5a8d17b1 --- /dev/null +++ b/organization/migrations/0011_alter_organization_organization_instagram_handle_and_more.py @@ -0,0 +1,38 @@ +# Generated by Django 5.0.3 on 2024-07-10 16:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0010_alter_organization_organization_facebook'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='organization_instagram_handle', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='organization instagram username'), + ), + migrations.AlterField( + model_name='organization', + name='organization_name', + field=models.CharField(db_index=True, max_length=255, verbose_name='organization name'), + ), + migrations.AlterField( + model_name='organization', + name='organization_twitter_handle', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='organization twitter username'), + ), + migrations.AlterField( + model_name='organization', + name='politician_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organization', + name='state_served_code', + field=models.CharField(db_index=True, max_length=2, null=True, verbose_name='state this organization serves'), + ), + ] diff --git a/organization/migrations/0012_alter_organization_twitter_followers_count.py b/organization/migrations/0012_alter_organization_twitter_followers_count.py new file mode 100644 index 000000000..6fd325529 --- /dev/null +++ b/organization/migrations/0012_alter_organization_twitter_followers_count.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 01:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0011_alter_organization_organization_instagram_handle_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='organization', + name='twitter_followers_count', + field=models.IntegerField(blank=True, db_index=True, default=0, verbose_name='number of twitter followers'), + ), + ] diff --git a/organization/migrations/0013_alter_organizationchangelog_changed_by_voter_we_vote_id_and_more.py b/organization/migrations/0013_alter_organizationchangelog_changed_by_voter_we_vote_id_and_more.py new file mode 100644 index 000000000..2ce4996ac --- /dev/null +++ b/organization/migrations/0013_alter_organizationchangelog_changed_by_voter_we_vote_id_and_more.py @@ -0,0 +1,58 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0012_alter_organization_twitter_followers_count'), + ] + + operations = [ + migrations.AlterField( + model_name='organizationchangelog', + name='changed_by_voter_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organizationchangelog', + name='organization_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organizationlinktohashtag', + name='organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='organizationlinktowordorphrase', + name='organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, unique=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='organizationmembershiplinktovoter', + name='organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, verbose_name='we vote id for organization'), + ), + migrations.AlterField( + model_name='organizationmembershiplinktovoter', + name='voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, verbose_name='we vote id for the voter owner'), + ), + migrations.AlterField( + model_name='organizationreserveddomain', + name='organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organizationteammember', + name='organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organizationteammember', + name='team_member_organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True), + ), + ] diff --git a/organization/migrations/0014_organization_organization_politicians_match_and_more.py b/organization/migrations/0014_organization_organization_politicians_match_and_more.py new file mode 100644 index 000000000..f5b6272b3 --- /dev/null +++ b/organization/migrations/0014_organization_organization_politicians_match_and_more.py @@ -0,0 +1,25 @@ +# Generated by Django 5.0.3 on 2024-07-14 14:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0013_alter_organizationchangelog_changed_by_voter_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='organization', + index=models.Index(fields=['politician_we_vote_id', 'state_served_code', 'organization_name', '-twitter_followers_count'], name='organization_politicians_match'), + ), + migrations.AddIndex( + model_name='organization', + index=models.Index(fields=['chosen_domain_string', 'chosen_domain_string2', 'chosen_domain_string3', 'chosen_subdomain_string'], name='site_configuration'), + ), + migrations.AddIndex( + model_name='organization', + index=models.Index(fields=['we_vote_id', '-twitter_followers_count'], name='orgs_by_twitter_followers'), + ), + ] diff --git a/organization/migrations/0015_rename_organization_politicians_match_organization_politicians_sort_and_more.py b/organization/migrations/0015_rename_organization_politicians_match_organization_politicians_sort_and_more.py new file mode 100644 index 000000000..893d5623b --- /dev/null +++ b/organization/migrations/0015_rename_organization_politicians_match_organization_politicians_sort_and_more.py @@ -0,0 +1,46 @@ +# Generated by Django 5.0.3 on 2024-07-25 19:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0014_organization_organization_politicians_match_and_more'), + ] + + operations = [ + migrations.RenameIndex( + model_name='organization', + new_name='organization_politicians_sort', + old_name='organization_politicians_match', + ), + migrations.AlterField( + model_name='organization', + name='chosen_domain_string', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='client domain name for we vote site'), + ), + migrations.AlterField( + model_name='organization', + name='chosen_domain_string2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organization', + name='chosen_domain_string3', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='organization', + name='politician_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddIndex( + model_name='organization', + index=models.Index(fields=['politician_we_vote_id', 'organization_name'], name='orgs_by_politician'), + ), + migrations.AddIndex( + model_name='organization', + index=models.Index(fields=['politician_we_vote_id', 'state_served_code', 'organization_name'], name='organization_politicians_match'), + ), + ] diff --git a/organization/migrations/0016_organizationteammember_can_edit_challenge_owned_by_organization_and_more.py b/organization/migrations/0016_organizationteammember_can_edit_challenge_owned_by_organization_and_more.py new file mode 100644 index 000000000..ba4f3cb26 --- /dev/null +++ b/organization/migrations/0016_organizationteammember_can_edit_challenge_owned_by_organization_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.8 on 2024-08-28 00:53 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0015_rename_organization_politicians_match_organization_politicians_sort_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='organizationteammember', + name='can_edit_challenge_owned_by_organization', + field=models.BooleanField(default=True), + ), + migrations.AddField( + model_name='organizationteammember', + name='can_moderate_challenge_owned_by_organization', + field=models.BooleanField(default=True), + ), + migrations.AddField( + model_name='organizationteammember', + name='can_send_updates_for_challenge_owned_by_organization', + field=models.BooleanField(default=True), + ), + ] diff --git a/organization/migrations/0017_organizationsarenotduplicates_and_more.py b/organization/migrations/0017_organizationsarenotduplicates_and_more.py new file mode 100644 index 000000000..abe7a2a91 --- /dev/null +++ b/organization/migrations/0017_organizationsarenotduplicates_and_more.py @@ -0,0 +1,30 @@ +# Generated by Django 5.0.11 on 2025-02-07 19:07 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0016_organizationteammember_can_edit_challenge_owned_by_organization_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='OrganizationsAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization1_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, verbose_name='first organization we are tracking')), + ('organization2_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, verbose_name='second organization we are tracking')), + ], + ), + migrations.CreateModel( + name='OrganizationsArePossibleDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization1_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('organization2_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True)), + ], + ), + ] diff --git a/organization/migrations/0018_organization_bluesky_handle_organization_tiktok_url.py b/organization/migrations/0018_organization_bluesky_handle_organization_tiktok_url.py new file mode 100644 index 000000000..001efec32 --- /dev/null +++ b/organization/migrations/0018_organization_bluesky_handle_organization_tiktok_url.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.13 on 2025-06-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0017_organizationsarenotduplicates_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='organization', + name='bluesky_handle', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='organization', + name='tiktok_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/organization/migrations/0019_organization_augmentation_done_and_more.py b/organization/migrations/0019_organization_augmentation_done_and_more.py new file mode 100644 index 000000000..8489db319 --- /dev/null +++ b/organization/migrations/0019_organization_augmentation_done_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.13 on 2025-06-17 16:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0018_organization_bluesky_handle_organization_tiktok_url'), + ] + + operations = [ + migrations.AddField( + model_name='organization', + name='augmentation_done', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='organization', + name='organization_defunct', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='organization', + name='qa_done', + field=models.BooleanField(default=False), + ), + ] diff --git a/organization/migrations/0020_organization_help_needed.py b/organization/migrations/0020_organization_help_needed.py new file mode 100644 index 000000000..3f0c95d1c --- /dev/null +++ b/organization/migrations/0020_organization_help_needed.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-06-18 19:52 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('organization', '0019_organization_augmentation_done_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='organization', + name='help_needed', + field=models.BooleanField(default=False), + ), + ] diff --git a/party/migrations/0001_initial.py b/party/migrations/0001_initial.py new file mode 100644 index 000000000..a2de699ea --- /dev/null +++ b/party/migrations/0001_initial.py @@ -0,0 +1,25 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Party', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('party_id_temp', models.CharField(max_length=255, null=True, unique=True, verbose_name='temporary party id')), + ('we_vote_id', models.CharField(max_length=32, null=True, unique=True, verbose_name='party we_vote_id')), + ('party_name', models.CharField(max_length=255, verbose_name='party name')), + ('party_abbreviation', models.CharField(blank=True, max_length=255, null=True, verbose_name='party abbreviation')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, unique=True, verbose_name='ctcl uuid')), + ], + ), + ] diff --git a/party/migrations/0002_alter_party_we_vote_id.py b/party/migrations/0002_alter_party_we_vote_id.py new file mode 100644 index 000000000..318344f62 --- /dev/null +++ b/party/migrations/0002_alter_party_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('party', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='party', + name='we_vote_id', + field=models.CharField(db_index=True, max_length=32, null=True, unique=True, verbose_name='party we_vote_id'), + ), + ] diff --git a/pledge_to_vote/migrations/0001_initial.py b/pledge_to_vote/migrations/0001_initial.py new file mode 100644 index 000000000..503eaf9ea --- /dev/null +++ b/pledge_to_vote/migrations/0001_initial.py @@ -0,0 +1,29 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='PledgeToVote', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote id of this pledge')), + ('voter_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='we vote id for the voter who made the pledge')), + ('organization_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='we vote id for the organization running pledge campaign')), + ('voter_guide_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='we vote id for the voter guide of pledge campaign')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('take_same_positions', models.BooleanField(default=False)), + ('visible_to_public', models.BooleanField(default=False)), + ('date_entered', models.DateTimeField(auto_now_add=True, null=True, verbose_name='date entered')), + ('deleted', models.BooleanField(default=False)), + ], + ), + ] diff --git a/politician/migrations/0001_initial.py b/politician/migrations/0001_initial.py new file mode 100644 index 000000000..7e2fac337 --- /dev/null +++ b/politician/migrations/0001_initial.py @@ -0,0 +1,94 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('tag', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='Politician', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this politician')), + ('first_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='first name')), + ('middle_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='middle name')), + ('last_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='last name')), + ('politician_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='official full name')), + ('google_civic_candidate_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='full name from google civic')), + ('google_civic_candidate_name2', models.CharField(max_length=255, null=True)), + ('google_civic_candidate_name3', models.CharField(max_length=255, null=True)), + ('full_name_assembled', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='full name assembled from first_name + last_name')), + ('gender', models.CharField(choices=[('F', 'Female'), ('N', 'Gender Neutral'), ('M', 'Male'), ('U', 'Unknown')], default='U', max_length=1, verbose_name='gender')), + ('birth_date', models.DateField(blank=True, default=None, null=True, verbose_name='birth date')), + ('bioguide_id', models.CharField(max_length=200, null=True, unique=True, verbose_name='bioguide unique identifier')), + ('thomas_id', models.CharField(max_length=200, null=True, unique=True, verbose_name='thomas unique identifier')), + ('lis_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='lis unique identifier')), + ('govtrack_id', models.CharField(max_length=200, null=True, unique=True, verbose_name='govtrack unique identifier')), + ('opensecrets_id', models.CharField(max_length=200, null=True, verbose_name='opensecrets unique identifier')), + ('vote_smart_id', models.CharField(max_length=200, null=True, verbose_name='votesmart unique identifier')), + ('fec_id', models.CharField(blank=True, max_length=200, null=True, unique=True, verbose_name='fec unique identifier')), + ('cspan_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='cspan unique identifier')), + ('wikipedia_id', models.CharField(blank=True, default=None, max_length=500, null=True, verbose_name='wikipedia url')), + ('ballotpedia_id', models.CharField(blank=True, default=None, max_length=500, null=True, verbose_name='ballotpedia url')), + ('house_history_id', models.CharField(blank=True, max_length=200, null=True, verbose_name='house history unique identifier')), + ('maplight_id', models.CharField(blank=True, max_length=200, null=True, unique=True, verbose_name='maplight unique identifier')), + ('washington_post_id', models.CharField(max_length=200, null=True, verbose_name='washington post unique identifier')), + ('icpsr_id', models.CharField(max_length=200, null=True, verbose_name='icpsr unique identifier')), + ('political_party', models.CharField(max_length=255, null=True, verbose_name='politician political party')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='politician home state')), + ('politician_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='latest website url of politician')), + ('politician_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='politician twitter screen_name')), + ('vote_usa_politician_id', models.CharField(blank=True, default=None, max_length=64, null=True, verbose_name='Vote USA permanent id for this candidate')), + ('we_vote_hosted_profile_image_url_large', models.URLField(blank=True, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_profile_image_url_medium', models.URLField(blank=True, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_profile_image_url_tiny', models.URLField(blank=True, null=True, verbose_name='we vote hosted tiny image url')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ('politician_facebook_id', models.CharField(max_length=255, null=True, verbose_name='politician facebook user name')), + ('politician_phone_number', models.CharField(max_length=255, null=True, verbose_name='politician phone number')), + ('politician_googleplus_id', models.CharField(max_length=255, null=True, verbose_name='politician googleplus profile name')), + ('politician_youtube_id', models.CharField(max_length=255, null=True, verbose_name='politician youtube profile name')), + ('politician_email_address', models.CharField(max_length=80, null=True, verbose_name='politician email address')), + ('date_last_updated', models.DateTimeField(auto_now=True, null=True)), + ], + options={ + 'ordering': ('last_name',), + }, + ), + migrations.CreateModel( + name='PoliticiansAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('politician1_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='first politician we are tracking')), + ('politician2_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='second politician we are tracking')), + ], + ), + migrations.CreateModel( + name='PoliticianTagLinkDisputed', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('politician', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, to='politician.politician', verbose_name='politician unique identifier')), + ('tag', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, to='tag.tag', verbose_name='tag unique identifier')), + ], + ), + migrations.CreateModel( + name='PoliticianTagLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('politician', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, to='politician.politician', verbose_name='politician unique identifier')), + ('tag', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, to='tag.tag', verbose_name='tag unique identifier')), + ], + ), + migrations.AddField( + model_name='politician', + name='tag_link', + field=models.ManyToManyField(through='politician.PoliticianTagLink', to='tag.Tag'), + ), + ] diff --git a/politician/migrations/0002_auto_20230104_0640.py b/politician/migrations/0002_auto_20230104_0640.py new file mode 100644 index 000000000..be35e4003 --- /dev/null +++ b/politician/migrations/0002_auto_20230104_0640.py @@ -0,0 +1,38 @@ +# Generated by Django 3.2.16 on 2023-01-04 14:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='politician_twitter_handle2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_twitter_handle3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_twitter_handle4', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_twitter_handle5', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='politician', + name='politician_twitter_handle', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/politician/migrations/0003_auto_20230106_1130.py b/politician/migrations/0003_auto_20230106_1130.py new file mode 100644 index 000000000..1fb7381c8 --- /dev/null +++ b/politician/migrations/0003_auto_20230106_1130.py @@ -0,0 +1,113 @@ +# Generated by Django 3.2.16 on 2023-01-06 19:30 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0002_auto_20230104_0640'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ballotpedia_politician_name', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='name exactly as received from ballotpedia'), + ), + migrations.AddField( + model_name='politician', + name='ballotpedia_politician_url', + field=models.TextField(blank=True, null=True, verbose_name='url of politician on ballotpedia'), + ), + migrations.AddField( + model_name='politician', + name='facebook_url', + field=models.TextField(blank=True, null=True, verbose_name='facebook url of candidate'), + ), + migrations.AddField( + model_name='politician', + name='facebook_url_is_broken', + field=models.BooleanField(default=False, verbose_name='facebook url is broken'), + ), + migrations.AddField( + model_name='politician', + name='instagram_followers_count', + field=models.IntegerField(blank=True, null=True, verbose_name="count of candidate's instagram followers"), + ), + migrations.AddField( + model_name='politician', + name='instagram_handle', + field=models.TextField(blank=True, null=True, verbose_name="politician's instagram handle"), + ), + migrations.AddField( + model_name='politician', + name='politician_contact_form_url', + field=models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of contact form'), + ), + migrations.AddField( + model_name='politician', + name='twitter_description', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.'), + ), + migrations.AddField( + model_name='politician', + name='twitter_followers_count', + field=models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers'), + ), + migrations.AddField( + model_name='politician', + name='twitter_location', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate location from twitter'), + ), + migrations.AddField( + model_name='politician', + name='twitter_name', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate plain text name from twitter'), + ), + migrations.AddField( + model_name='politician', + name='twitter_profile_background_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='tile-able background from twitter'), + ), + migrations.AddField( + model_name='politician', + name='twitter_profile_banner_url_https', + field=models.TextField(blank=True, null=True, verbose_name='profile banner image from twitter'), + ), + migrations.AddField( + model_name='politician', + name='twitter_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached url of candidate profile image from twitter'), + ), + migrations.AddField( + model_name='politician', + name='vote_usa_profile_image_url_https', + field=models.TextField(blank=True, default=None, null=True), + ), + migrations.AlterField( + model_name='politician', + name='gender', + field=models.CharField(choices=[('F', 'Female'), ('N', 'Nonbinary'), ('M', 'Male'), ('U', 'Unknown')], default='U', max_length=1, verbose_name='gender'), + ), + migrations.AlterField( + model_name='politician', + name='politician_email_address', + field=models.CharField(max_length=255, null=True, verbose_name='politician email address'), + ), + migrations.AlterField( + model_name='politician', + name='we_vote_hosted_profile_image_url_large', + field=models.TextField(blank=True, null=True, verbose_name='we vote hosted large image url'), + ), + migrations.AlterField( + model_name='politician', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True, verbose_name='we vote hosted medium image url'), + ), + migrations.AlterField( + model_name='politician', + name='we_vote_hosted_profile_image_url_tiny', + field=models.TextField(blank=True, null=True, verbose_name='we vote hosted tiny image url'), + ), + ] diff --git a/politician/migrations/0004_auto_20230126_1420.py b/politician/migrations/0004_auto_20230126_1420.py new file mode 100644 index 000000000..00ea2112a --- /dev/null +++ b/politician/migrations/0004_auto_20230126_1420.py @@ -0,0 +1,43 @@ +# Generated by Django 3.2.16 on 2023-01-26 22:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0003_auto_20230106_1130'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='date_last_updated_from_candidate', + field=models.DateTimeField(default=None, null=True), + ), + migrations.AddField( + model_name='politician', + name='linkedin_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='twitter_handle2_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='twitter_handle_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='wikipedia_url', + field=models.TextField(null=True), + ), + migrations.AddField( + model_name='politician', + name='youtube_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/politician/migrations/0005_auto_20230128_1026.py b/politician/migrations/0005_auto_20230128_1026.py new file mode 100644 index 000000000..3bedd921c --- /dev/null +++ b/politician/migrations/0005_auto_20230128_1026.py @@ -0,0 +1,38 @@ +# Generated by Django 3.2.16 on 2023-01-28 18:26 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0004_auto_20230126_1420'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='politician_url2', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_url3', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_url4', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_url5', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='politician', + name='politician_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/politician/migrations/0006_auto_20230201_1248.py b/politician/migrations/0006_auto_20230201_1248.py new file mode 100644 index 000000000..21f0d8cae --- /dev/null +++ b/politician/migrations/0006_auto_20230201_1248.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.16 on 2023-02-01 20:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0005_auto_20230128_1026'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='politician_email', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_email2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_email3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='politician', + name='politician_email_address', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/politician/migrations/0007_auto_20230203_1547.py b/politician/migrations/0007_auto_20230203_1547.py new file mode 100644 index 000000000..59087c531 --- /dev/null +++ b/politician/migrations/0007_auto_20230203_1547.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.17 on 2023-02-03 23:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0006_auto_20230201_1248'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='facebook_url2', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='facebook_url2_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='facebook_url3', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='facebook_url3_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='politician_phone_number2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_phone_number3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='politician', + name='politician_phone_number', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/politician/migrations/0008_auto_20230208_1449.py b/politician/migrations/0008_auto_20230208_1449.py new file mode 100644 index 000000000..ae0781342 --- /dev/null +++ b/politician/migrations/0008_auto_20230208_1449.py @@ -0,0 +1,98 @@ +# Generated by Django 3.2.17 on 2023-02-08 22:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0007_auto_20230203_1547'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('FACEBOOK', 'Facebook'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA')], default='UNKNOWN', max_length=10), + ), + migrations.AddField( + model_name='politician', + name='twitter_user_id', + field=models.BigIntegerField(blank=True, null=True, verbose_name='twitter id'), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_facebook_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_facebook_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_facebook_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_twitter_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_twitter_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_twitter_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_uploaded_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_uploaded_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_uploaded_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_vote_usa_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_vote_usa_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_vote_usa_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='politician', + name='we_vote_hosted_profile_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='politician', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='politician', + name='we_vote_hosted_profile_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/politician/migrations/0009_politiciansarepossibleduplicates.py b/politician/migrations/0009_politiciansarepossibleduplicates.py new file mode 100644 index 000000000..f27965c9d --- /dev/null +++ b/politician/migrations/0009_politiciansarepossibleduplicates.py @@ -0,0 +1,22 @@ +# Generated by Django 3.2.17 on 2023-02-12 01:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0008_auto_20230208_1449'), + ] + + operations = [ + migrations.CreateModel( + name='PoliticiansArePossibleDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('politician1_we_vote_id', models.CharField(max_length=255, null=True)), + ('politician2_we_vote_id', models.CharField(max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True)), + ], + ), + ] diff --git a/politician/migrations/0010_auto_20230306_1649.py b/politician/migrations/0010_auto_20230306_1649.py new file mode 100644 index 000000000..e2a14471f --- /dev/null +++ b/politician/migrations/0010_auto_20230306_1649.py @@ -0,0 +1,53 @@ +# Generated by Django 3.2.18 on 2023-03-07 00:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0009_politiciansarepossibleduplicates'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='is_battleground_race_2019', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2020', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2021', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2022', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2023', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2024', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2025', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='is_battleground_race_2026', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0011_auto_20230320_1111.py b/politician/migrations/0011_auto_20230320_1111.py new file mode 100644 index 000000000..aaf305e4c --- /dev/null +++ b/politician/migrations/0011_auto_20230320_1111.py @@ -0,0 +1,29 @@ +# Generated by Django 3.2.18 on 2023-03-20 18:11 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0010_auto_20230306_1649'), + ] + + operations = [ + migrations.CreateModel( + name='PoliticianSEOFriendlyPath', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('politician_we_vote_id', models.CharField(max_length=255, null=True)), + ('politician_name', models.CharField(max_length=255)), + ('base_pathname_string', models.CharField(max_length=255, null=True)), + ('pathname_modifier', models.CharField(max_length=10, null=True)), + ('final_pathname_string', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ], + ), + migrations.AddField( + model_name='politician', + name='seo_friendly_path', + field=models.CharField(db_index=True, max_length=255, null=True, unique=True), + ), + ] diff --git a/politician/migrations/0012_politician_seo_friendly_path_date_last_updated.py b/politician/migrations/0012_politician_seo_friendly_path_date_last_updated.py new file mode 100644 index 000000000..66b698748 --- /dev/null +++ b/politician/migrations/0012_politician_seo_friendly_path_date_last_updated.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-24 17:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0011_auto_20230320_1111'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='seo_friendly_path_date_last_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/politician/migrations/0013_politician_linked_campaignx_we_vote_id.py b/politician/migrations/0013_politician_linked_campaignx_we_vote_id.py new file mode 100644 index 000000000..465e0c6e4 --- /dev/null +++ b/politician/migrations/0013_politician_linked_campaignx_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-04-10 19:03 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0012_politician_seo_friendly_path_date_last_updated'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='linked_campaignx_we_vote_id', + field=models.CharField(max_length=255, null=True, unique=True), + ), + ] diff --git a/politician/migrations/0014_politician_linked_campaignx_we_vote_id_date_last_updated.py b/politician/migrations/0014_politician_linked_campaignx_we_vote_id_date_last_updated.py new file mode 100644 index 000000000..05ba3b2dc --- /dev/null +++ b/politician/migrations/0014_politician_linked_campaignx_we_vote_id_date_last_updated.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-05-04 13:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0013_politician_linked_campaignx_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='linked_campaignx_we_vote_id_date_last_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/politician/migrations/0015_politician_supporters_count.py b/politician/migrations/0015_politician_supporters_count.py new file mode 100644 index 000000000..1bc433536 --- /dev/null +++ b/politician/migrations/0015_politician_supporters_count.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-05-21 17:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0014_politician_linked_campaignx_we_vote_id_date_last_updated'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='supporters_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/politician/migrations/0016_auto_20230606_1749.py b/politician/migrations/0016_auto_20230606_1749.py new file mode 100644 index 000000000..ce1512bb9 --- /dev/null +++ b/politician/migrations/0016_auto_20230606_1749.py @@ -0,0 +1,43 @@ +# Generated by Django 3.2.18 on 2023-06-07 00:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0015_politician_supporters_count'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='we_vote_hosted_politician_photo_original_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AlterField( + model_name='politician', + name='instagram_followers_count', + field=models.IntegerField(blank=True, null=True, verbose_name="count of politician's instagram followers"), + ), + migrations.AlterField( + model_name='politician', + name='twitter_location', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='politician location from twitter'), + ), + migrations.AlterField( + model_name='politician', + name='twitter_name', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='politician plain text name from twitter'), + ), + migrations.AlterField( + model_name='politician', + name='twitter_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached url of politician profile image from twitter'), + ), + migrations.AlterField( + model_name='politician', + name='vote_usa_politician_id', + field=models.CharField(blank=True, default=None, max_length=64, null=True, verbose_name='Vote USA permanent id for this politician'), + ), + ] diff --git a/politician/migrations/0017_politician_google_civic_name_alternates_generated.py b/politician/migrations/0017_politician_google_civic_name_alternates_generated.py new file mode 100644 index 000000000..2ce1d96fd --- /dev/null +++ b/politician/migrations/0017_politician_google_civic_name_alternates_generated.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-06-18 01:33 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0016_auto_20230606_1749'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='google_civic_name_alternates_generated', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0018_politician_photo_url_from_vote_usa.py b/politician/migrations/0018_politician_photo_url_from_vote_usa.py new file mode 100644 index 000000000..5525ab398 --- /dev/null +++ b/politician/migrations/0018_politician_photo_url_from_vote_usa.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-06-19 17:26 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0017_politician_google_civic_name_alternates_generated'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='photo_url_from_vote_usa', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/politician/migrations/0019_politician_ocd_id_state_mismatch_found.py b/politician/migrations/0019_politician_ocd_id_state_mismatch_found.py new file mode 100644 index 000000000..c520bb113 --- /dev/null +++ b/politician/migrations/0019_politician_ocd_id_state_mismatch_found.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-06-29 14:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0018_politician_photo_url_from_vote_usa'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ocd_id_state_mismatch_found', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0020_politician_seo_friendly_path_needs_regeneration.py b/politician/migrations/0020_politician_seo_friendly_path_needs_regeneration.py new file mode 100644 index 000000000..64abcc226 --- /dev/null +++ b/politician/migrations/0020_politician_seo_friendly_path_needs_regeneration.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-07-03 12:17 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0019_politician_ocd_id_state_mismatch_found'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='seo_friendly_path_needs_regeneration', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0021_politician_ballot_guide_official_statement.py b/politician/migrations/0021_politician_ballot_guide_official_statement.py new file mode 100644 index 000000000..bce2f876e --- /dev/null +++ b/politician/migrations/0021_politician_ballot_guide_official_statement.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.19 on 2023-07-15 22:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0020_politician_seo_friendly_path_needs_regeneration'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ballot_guide_official_statement', + field=models.TextField(blank=True, default=None, null=True, verbose_name='official candidate statement from ballot guide'), + ), + ] diff --git a/politician/migrations/0022_auto_20230720_0429.py b/politician/migrations/0022_auto_20230720_0429.py new file mode 100644 index 000000000..b9b1f7ac0 --- /dev/null +++ b/politician/migrations/0022_auto_20230720_0429.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.19 on 2023-07-20 11:29 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0021_politician_ballot_guide_official_statement'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='gender_likelihood', + field=models.CharField(choices=[('PolDataMgr', 'Political Data Mgr'), ('Politician', 'Politician Provided'), ('GuessHigh', 'Gender Guesser High Likelihood'), ('GuessLow', 'Gender Guesser Low Likelihood'), ('', '')], default='', max_length=11, verbose_name='gender guess likelihood'), + ), + migrations.AlterField( + model_name='politician', + name='gender', + field=models.CharField(choices=[('M', 'Male'), ('F', 'Female'), ('N', 'Nonbinary'), ('U', 'Unknown')], default='U', max_length=1, verbose_name='gender'), + ), + ] diff --git a/politician/migrations/0023_auto_20231216_1125.py b/politician/migrations/0023_auto_20231216_1125.py new file mode 100644 index 000000000..1393e0587 --- /dev/null +++ b/politician/migrations/0023_auto_20231216_1125.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.23 on 2023-12-16 19:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0022_auto_20230720_0429'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='profile_image_background_color', + field=models.CharField(blank=True, max_length=7, null=True), + ), + migrations.AlterField( + model_name='politician', + name='linked_campaignx_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, unique=True), + ), + ] diff --git a/politician/migrations/0024_politician_profile_image_background_color_needed.py b/politician/migrations/0024_politician_profile_image_background_color_needed.py new file mode 100644 index 000000000..4b7bd1a25 --- /dev/null +++ b/politician/migrations/0024_politician_profile_image_background_color_needed.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-12-21 15:21 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0023_auto_20231216_1125'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='profile_image_background_color_needed', + field=models.BooleanField(null=True), + ), + ] diff --git a/politician/migrations/0025_auto_20240210_1816.py b/politician/migrations/0025_auto_20240210_1816.py new file mode 100644 index 000000000..bd255aff5 --- /dev/null +++ b/politician/migrations/0025_auto_20240210_1816.py @@ -0,0 +1,93 @@ +# Generated by Django 3.2.23 on 2024-02-11 02:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0024_politician_profile_image_background_color_needed'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ballotpedia_photo_url', + field=models.TextField(blank=True, null=True, verbose_name='url of remote ballotpedia profile photo'), + ), + migrations.AddField( + model_name='politician', + name='ballotpedia_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached profile image from ballotpedia'), + ), + migrations.AddField( + model_name='politician', + name='linkedin_photo_url', + field=models.TextField(blank=True, null=True, verbose_name='url of remote linkedin profile photo'), + ), + migrations.AddField( + model_name='politician', + name='linkedin_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached candidate profile image from linkedin'), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_ballotpedia_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_ballotpedia_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_ballotpedia_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_linkedin_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_linkedin_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_linkedin_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_wikipedia_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_wikipedia_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='we_vote_hosted_profile_wikipedia_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='wikipedia_photo_url', + field=models.TextField(blank=True, null=True, verbose_name='url of remote wikipedia profile photo'), + ), + migrations.AddField( + model_name='politician', + name='wikipedia_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='locally cached candidate profile image from wikipedia'), + ), + migrations.AlterField( + model_name='politician', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('BALLOTPEDIA', 'Ballotpedia'), ('FACEBOOK', 'Facebook'), ('LINKEDIN', 'LinkedIn'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA'), ('WIKIPEDIA', 'Wikipedia')], default='UNKNOWN', max_length=11), + ), + ] diff --git a/politician/migrations/0026_auto_20240407_1401.py b/politician/migrations/0026_auto_20240407_1401.py new file mode 100644 index 000000000..da1e1c863 --- /dev/null +++ b/politician/migrations/0026_auto_20240407_1401.py @@ -0,0 +1,54 @@ +# Generated by Django 3.2.25 on 2024-04-07 21:01 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0025_auto_20240210_1816'), + ] + + operations = [ + migrations.CreateModel( + name='PoliticianChangeLog', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, null=True)), + ('politician_we_vote_id', models.CharField(max_length=255)), + ('changed_by_name', models.CharField(default=None, max_length=255, null=True)), + ('changed_by_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('change_description', models.TextField(blank=True, null=True)), + ('log_datetime', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('is_ballotpedia_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_ballotpedia_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_facebook_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_facebook_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_from_twitter', models.BooleanField(db_index=True, default=None, null=True)), + ('is_linkedin_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_linkedin_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_official_statement_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_official_statement_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_photo_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_photo_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_politician_analysis_done', models.BooleanField(db_index=True, default=None, null=True)), + ('is_politician_url_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_politician_url_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_twitter_handle_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_twitter_handle_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_website_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_website_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_wikipedia_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_wikipedia_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('is_withdrawal_date_added', models.BooleanField(db_index=True, default=None, null=True)), + ('is_withdrawal_date_removed', models.BooleanField(db_index=True, default=None, null=True)), + ('kind_of_log_entry', models.CharField(db_index=True, default=None, max_length=50, null=True)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ], + ), + migrations.AddField( + model_name='politician', + name='politician_analysis_done', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0027_politician_ballotpedia_photo_url_is_broken.py b/politician/migrations/0027_politician_ballotpedia_photo_url_is_broken.py new file mode 100644 index 000000000..fad73f7d7 --- /dev/null +++ b/politician/migrations/0027_politician_ballotpedia_photo_url_is_broken.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-11 01:17 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0026_auto_20240407_1401'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ballotpedia_photo_url_is_broken', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0028_politician_ballotpedia_photo_url_is_placeholder.py b/politician/migrations/0028_politician_ballotpedia_photo_url_is_placeholder.py new file mode 100644 index 000000000..d8b4ffcf8 --- /dev/null +++ b/politician/migrations/0028_politician_ballotpedia_photo_url_is_placeholder.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-11 15:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0027_politician_ballotpedia_photo_url_is_broken'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ballotpedia_photo_url_is_placeholder', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0029_recommendedpoliticianlinkbypolitician.py b/politician/migrations/0029_recommendedpoliticianlinkbypolitician.py new file mode 100644 index 000000000..af82759d0 --- /dev/null +++ b/politician/migrations/0029_recommendedpoliticianlinkbypolitician.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.3 on 2024-05-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0028_politician_ballotpedia_photo_url_is_placeholder'), + ] + + operations = [ + migrations.CreateModel( + name='RecommendedPoliticianLinkByPolitician', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('from_politician_we_vote_id', models.CharField(max_length=255, null=True)), + ('recommended_politician_we_vote_id', models.CharField(max_length=255, null=True)), + ], + ), + ] diff --git a/politician/migrations/0030_politician_wikipedia_photo_does_not_exist.py b/politician/migrations/0030_politician_wikipedia_photo_does_not_exist.py new file mode 100644 index 000000000..65481f271 --- /dev/null +++ b/politician/migrations/0030_politician_wikipedia_photo_does_not_exist.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-30 01:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0029_recommendedpoliticianlinkbypolitician'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='wikipedia_photo_does_not_exist', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0031_alter_politician_politician_contact_form_url.py b/politician/migrations/0031_alter_politician_politician_contact_form_url.py new file mode 100644 index 000000000..07ed13193 --- /dev/null +++ b/politician/migrations/0031_alter_politician_politician_contact_form_url.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0030_politician_wikipedia_photo_does_not_exist'), + ] + + operations = [ + migrations.AlterField( + model_name='politician', + name='politician_contact_form_url', + field=models.TextField(null=True, verbose_name='website url of contact form'), + ), + ] diff --git a/politician/migrations/0032_politician_ballotpedia_candidate_links_retrieved.py b/politician/migrations/0032_politician_ballotpedia_candidate_links_retrieved.py new file mode 100644 index 000000000..859a252af --- /dev/null +++ b/politician/migrations/0032_politician_ballotpedia_candidate_links_retrieved.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-11 05:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0031_alter_politician_politician_contact_form_url'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='ballotpedia_candidate_links_retrieved', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0033_politician_opposers_count_and_more.py b/politician/migrations/0033_politician_opposers_count_and_more.py new file mode 100644 index 000000000..735826e9e --- /dev/null +++ b/politician/migrations/0033_politician_opposers_count_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-07-08 01:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0032_politician_ballotpedia_candidate_links_retrieved'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='opposers_count', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='politician', + name='organization_and_manual_intervention_needed', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='organization_might_be_needed', + field=models.BooleanField(default=True), + ), + migrations.AddField( + model_name='politician', + name='politician_ultimate_election_date', + field=models.PositiveIntegerField(default=None, null=True), + ), + ] diff --git a/politician/migrations/0034_alter_politician_we_vote_id.py b/politician/migrations/0034_alter_politician_we_vote_id.py new file mode 100644 index 000000000..f02c7e1a6 --- /dev/null +++ b/politician/migrations/0034_alter_politician_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0033_politician_opposers_count_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='politician', + name='we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this politician'), + ), + ] diff --git a/politician/migrations/0035_rename_organization_and_manual_intervention_needed_politician_organization_manual_intervention_neede.py b/politician/migrations/0035_rename_organization_and_manual_intervention_needed_politician_organization_manual_intervention_neede.py new file mode 100644 index 000000000..3a52138f2 --- /dev/null +++ b/politician/migrations/0035_rename_organization_and_manual_intervention_needed_politician_organization_manual_intervention_neede.py @@ -0,0 +1,37 @@ +# Generated by Django 5.0.3 on 2024-07-24 22:50 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0034_alter_politician_we_vote_id'), + ] + + operations = [ + migrations.RenameField( + model_name='politician', + old_name='organization_and_manual_intervention_needed', + new_name='organization_manual_intervention_needed', + ), + migrations.RemoveField( + model_name='politician', + name='organization_might_be_needed', + ), + migrations.AddField( + model_name='politician', + name='organization_analysis_needed', + field=models.BooleanField(default=True), + ), + migrations.AddField( + model_name='politician', + name='organization_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='politician', + name='politician_has_two_linked_organizations', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0036_politician_follow_organization_analysis_complete_and_more.py b/politician/migrations/0036_politician_follow_organization_analysis_complete_and_more.py new file mode 100644 index 000000000..a206ba5a3 --- /dev/null +++ b/politician/migrations/0036_politician_follow_organization_analysis_complete_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-27 14:42 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0035_rename_organization_and_manual_intervention_needed_politician_organization_manual_intervention_neede'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='follow_organization_analysis_complete', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='politician', + name='follow_organization_intervention_needed', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/politician/migrations/0037_politician_date_ultimate_election_last_updated_from_candidate.py b/politician/migrations/0037_politician_date_ultimate_election_last_updated_from_candidate.py new file mode 100644 index 000000000..c99789216 --- /dev/null +++ b/politician/migrations/0037_politician_date_ultimate_election_last_updated_from_candidate.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.9 on 2024-11-11 03:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0036_politician_follow_organization_analysis_complete_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='date_ultimate_election_last_updated_from_candidate', + field=models.DateTimeField(default=None, null=True), + ), + ] diff --git a/politician/migrations/0038_politician_bluesky_handle_politician_tiktok_url_and_more.py b/politician/migrations/0038_politician_bluesky_handle_politician_tiktok_url_and_more.py new file mode 100644 index 000000000..5ed3b9b5a --- /dev/null +++ b/politician/migrations/0038_politician_bluesky_handle_politician_tiktok_url_and_more.py @@ -0,0 +1,43 @@ +# Generated by Django 5.0.13 on 2025-06-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0037_politician_date_ultimate_election_last_updated_from_candidate'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='bluesky_handle', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politician', + name='tiktok_url', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politicianchangelog', + name='is_bluesky_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='politicianchangelog', + name='is_bluesky_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='politicianchangelog', + name='is_tiktok_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='politicianchangelog', + name='is_tiktok_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/politician/migrations/0039_politician_linked_campaignx_we_vote_id_verified.py b/politician/migrations/0039_politician_linked_campaignx_we_vote_id_verified.py new file mode 100644 index 000000000..d9d29f7b8 --- /dev/null +++ b/politician/migrations/0039_politician_linked_campaignx_we_vote_id_verified.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-08-18 14:19 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0038_politician_bluesky_handle_politician_tiktok_url_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='linked_campaignx_we_vote_id_verified', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0040_politician_is_claimed_profile.py b/politician/migrations/0040_politician_is_claimed_profile.py new file mode 100644 index 000000000..fdf324252 --- /dev/null +++ b/politician/migrations/0040_politician_is_claimed_profile.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-10-12 00:33 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0039_politician_linked_campaignx_we_vote_id_verified'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='is_claimed_profile', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0041_politiciansupporter.py b/politician/migrations/0041_politiciansupporter.py new file mode 100644 index 000000000..abfa005dd --- /dev/null +++ b/politician/migrations/0041_politiciansupporter.py @@ -0,0 +1,39 @@ +# Generated by Django 5.0.13 on 2025-10-25 23:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0040_politician_is_claimed_profile'), + ] + + operations = [ + migrations.CreateModel( + name='PoliticianSupporter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('email', models.EmailField(max_length=255, null=True)), + ('date_email_invite_sent', models.DateTimeField(db_index=True, null=True)), + ('date_imported', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('date_sms_invite_sent', models.DateTimeField(db_index=True, null=True)), + ('email_invite_sent', models.BooleanField(default=False)), + ('email_ownership_is_verified', models.BooleanField(default=False)), + ('email_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True)), + ('invited_by_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('normalized_sms_phone_number', models.CharField(blank=True, max_length=50, null=True)), + ('politician_name', models.CharField(default=None, max_length=255, null=True)), + ('politician_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('sms_invite_sent', models.BooleanField(default=False)), + ('sms_ownership_is_verified', models.BooleanField(default=False)), + ('sms_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True)), + ('stance', models.CharField(choices=[('SUPPORT', 'Supports'), ('INFO_ONLY', 'Information only'), ('OPPOSE', 'Opposes')], db_index=True, default='INFO_ONLY', max_length=15)), + ('supporter_name', models.CharField(default=None, max_length=255, null=True)), + ('supporter_endorsement', models.TextField(null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(null=True)), + ], + ), + ] diff --git a/politician/migrations/0042_politician_linked_campaignx_we_vote_id_verified_in_campaignx.py b/politician/migrations/0042_politician_linked_campaignx_we_vote_id_verified_in_campaignx.py new file mode 100644 index 000000000..80103e224 --- /dev/null +++ b/politician/migrations/0042_politician_linked_campaignx_we_vote_id_verified_in_campaignx.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-11-05 18:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0041_politiciansupporter'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='linked_campaignx_we_vote_id_verified_in_campaignx', + field=models.BooleanField(default=False), + ), + ] diff --git a/politician/migrations/0043_politician_threads_handle_and_more.py b/politician/migrations/0043_politician_threads_handle_and_more.py new file mode 100644 index 000000000..3f51f53ea --- /dev/null +++ b/politician/migrations/0043_politician_threads_handle_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.13 on 2025-11-14 06:30 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0042_politician_linked_campaignx_we_vote_id_verified_in_campaignx'), + ] + + operations = [ + migrations.AddField( + model_name='politician', + name='threads_handle', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='politicianchangelog', + name='is_threads_handle_added', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + migrations.AddField( + model_name='politicianchangelog', + name='is_threads_handle_removed', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/politician/migrations/0044_deduplicationneededforstatetoday_and_more.py b/politician/migrations/0044_deduplicationneededforstatetoday_and_more.py new file mode 100644 index 000000000..1f22bf626 --- /dev/null +++ b/politician/migrations/0044_deduplicationneededforstatetoday_and_more.py @@ -0,0 +1,78 @@ +# Generated by Django 5.0.13 on 2025-11-24 15:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0043_politician_threads_handle_and_more'), + ] + + operations = [ + migrations.CreateModel( + name='DeduplicationNeededForStateToday', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_now_as_integer', models.PositiveIntegerField(db_index=True, null=True, unique=True)), + ('ak_deduplication_needed', models.BooleanField(default=True)), + ('al_deduplication_needed', models.BooleanField(default=True)), + ('ar_deduplication_needed', models.BooleanField(default=True)), + ('az_deduplication_needed', models.BooleanField(default=True)), + ('ca_deduplication_needed', models.BooleanField(default=True)), + ('co_deduplication_needed', models.BooleanField(default=True)), + ('ct_deduplication_needed', models.BooleanField(default=True)), + ('dc_deduplication_needed', models.BooleanField(default=True)), + ('de_deduplication_needed', models.BooleanField(default=True)), + ('fl_deduplication_needed', models.BooleanField(default=True)), + ('ga_deduplication_needed', models.BooleanField(default=True)), + ('hi_deduplication_needed', models.BooleanField(default=True)), + ('ia_deduplication_needed', models.BooleanField(default=True)), + ('id_deduplication_needed', models.BooleanField(default=True)), + ('il_deduplication_needed', models.BooleanField(default=True)), + ('in_deduplication_needed', models.BooleanField(default=True)), + ('ks_deduplication_needed', models.BooleanField(default=True)), + ('ky_deduplication_needed', models.BooleanField(default=True)), + ('la_deduplication_needed', models.BooleanField(default=True)), + ('ma_deduplication_needed', models.BooleanField(default=True)), + ('md_deduplication_needed', models.BooleanField(default=True)), + ('me_deduplication_needed', models.BooleanField(default=True)), + ('mi_deduplication_needed', models.BooleanField(default=True)), + ('mn_deduplication_needed', models.BooleanField(default=True)), + ('mo_deduplication_needed', models.BooleanField(default=True)), + ('ms_deduplication_needed', models.BooleanField(default=True)), + ('mt_deduplication_needed', models.BooleanField(default=True)), + ('na_deduplication_needed', models.BooleanField(default=True)), + ('nc_deduplication_needed', models.BooleanField(default=True)), + ('nd_deduplication_needed', models.BooleanField(default=True)), + ('ne_deduplication_needed', models.BooleanField(default=True)), + ('nh_deduplication_needed', models.BooleanField(default=True)), + ('nj_deduplication_needed', models.BooleanField(default=True)), + ('nm_deduplication_needed', models.BooleanField(default=True)), + ('nv_deduplication_needed', models.BooleanField(default=True)), + ('ny_deduplication_needed', models.BooleanField(default=True)), + ('oh_deduplication_needed', models.BooleanField(default=True)), + ('ok_deduplication_needed', models.BooleanField(default=True)), + ('or_deduplication_needed', models.BooleanField(default=True)), + ('pa_deduplication_needed', models.BooleanField(default=True)), + ('pr_deduplication_needed', models.BooleanField(default=True)), + ('ri_deduplication_needed', models.BooleanField(default=True)), + ('sc_deduplication_needed', models.BooleanField(default=True)), + ('sd_deduplication_needed', models.BooleanField(default=True)), + ('tn_deduplication_needed', models.BooleanField(default=True)), + ('tx_deduplication_needed', models.BooleanField(default=True)), + ('ut_deduplication_needed', models.BooleanField(default=True)), + ('va_deduplication_needed', models.BooleanField(default=True)), + ('vt_deduplication_needed', models.BooleanField(default=True)), + ('wa_deduplication_needed', models.BooleanField(default=True)), + ('wi_deduplication_needed', models.BooleanField(default=True)), + ('wv_deduplication_needed', models.BooleanField(default=True)), + ('wy_deduplication_needed', models.BooleanField(default=True)), + ], + ), + migrations.AddField( + model_name='politician', + name='duplicate_check_last_completed', + field=models.DateTimeField(null=True), + ), + ] diff --git a/politician/migrations/0045_remove_politician_tag_link_and_more.py b/politician/migrations/0045_remove_politician_tag_link_and_more.py new file mode 100644 index 000000000..f8683a567 --- /dev/null +++ b/politician/migrations/0045_remove_politician_tag_link_and_more.py @@ -0,0 +1,31 @@ +# Generated by Django 5.0.13 on 2025-11-24 16:53 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('politician', '0044_deduplicationneededforstatetoday_and_more'), + ] + + operations = [ + migrations.RemoveField( + model_name='politician', + name='tag_link', + ), + migrations.RemoveField( + model_name='politiciantaglinkdisputed', + name='politician', + ), + migrations.RemoveField( + model_name='politiciantaglinkdisputed', + name='tag', + ), + migrations.DeleteModel( + name='PoliticianTagLink', + ), + migrations.DeleteModel( + name='PoliticianTagLinkDisputed', + ), + ] diff --git a/polling_location/migrations/0001_initial.py b/polling_location/migrations/0001_initial.py new file mode 100644 index 000000000..615a343a9 --- /dev/null +++ b/polling_location/migrations/0001_initial.py @@ -0,0 +1,61 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='PollingLocation', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('polling_location_id', models.CharField(max_length=255, verbose_name='vip polling_location id')), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this map point')), + ('location_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='location name')), + ('polling_hours_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='polling hours')), + ('directions_text', models.TextField(blank=True, null=True, verbose_name='directions to get to map point')), + ('line1', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='address line 1 returned from VIP')), + ('line2', models.CharField(blank=True, max_length=255, null=True, verbose_name='address line 2 returned from VIP')), + ('city', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='city returned from VIP')), + ('state', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='state returned from VIP')), + ('zip_long', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='raw text zip returned from VIP, 9 characters')), + ('county_name', models.CharField(default=None, max_length=255, null=True)), + ('precinct_name', models.CharField(default=None, max_length=255, null=True)), + ('latitude', models.FloatField(default=None, null=True)), + ('longitude', models.FloatField(default=None, null=True)), + ('ctcl_error_count', models.PositiveIntegerField(default=None, null=True)), + ('google_response_address_not_found', models.PositiveIntegerField(default=None, null=True, verbose_name="how many times Google can't find address")), + ('vote_usa_error_count', models.PositiveIntegerField(default=None, null=True)), + ('no_contests_count', models.PositiveIntegerField(default=None, null=True)), + ('source_code', models.CharField(default=None, max_length=50, null=True)), + ('successful_retrieve_count', models.PositiveIntegerField(default=None, null=True)), + ('use_for_bulk_retrieve', models.BooleanField(default=False, verbose_name='this provides geographical coverage')), + ('polling_location_deleted', models.BooleanField(default=False, verbose_name='removed from usage')), + ], + ), + migrations.CreateModel( + name='PollingLocationLogEntry', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('batch_process_id', models.PositiveIntegerField(db_index=True, null=True)), + ('date_time', models.DateTimeField(auto_now_add=True)), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True)), + ('is_from_ballotpedia', models.BooleanField(db_index=True, default=False, null=True)), + ('is_from_ctcl', models.BooleanField(db_index=True, default=False, null=True)), + ('is_from_vote_usa', models.BooleanField(db_index=True, default=False, null=True)), + ('kind_of_log_entry', models.CharField(db_index=True, default=None, max_length=50, null=True)), + ('log_entry_deleted', models.BooleanField(db_index=True, default=False)), + ('log_entry_message', models.TextField(null=True)), + ('polling_location_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('text_for_map_search', models.CharField(max_length=255, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ], + ), + ] diff --git a/polling_location/migrations/0002_auto_20230126_1420.py b/polling_location/migrations/0002_auto_20230126_1420.py new file mode 100644 index 000000000..80171c256 --- /dev/null +++ b/polling_location/migrations/0002_auto_20230126_1420.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.16 on 2023-01-26 22:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='pollinglocation', + name='google_civic_error_count', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AddField( + model_name='pollinglocationlogentry', + name='is_from_google_civic', + field=models.BooleanField(db_index=True, default=False, null=True), + ), + ] diff --git a/polling_location/migrations/0003_pollinglocationlogentry_kind_of_log_entry_and_deleted.py b/polling_location/migrations/0003_pollinglocationlogentry_kind_of_log_entry_and_deleted.py new file mode 100644 index 000000000..116bcdab0 --- /dev/null +++ b/polling_location/migrations/0003_pollinglocationlogentry_kind_of_log_entry_and_deleted.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-13 13:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0002_auto_20230126_1420'), + ] + + operations = [ + migrations.AddIndex( + model_name='pollinglocationlogentry', + index=models.Index(fields=['kind_of_log_entry', 'log_entry_deleted'], name='kind_of_log_entry_and_deleted'), + ), + ] diff --git a/polling_location/migrations/0004_pollinglocationlogentry_log_entry_one_location_index.py b/polling_location/migrations/0004_pollinglocationlogentry_log_entry_one_location_index.py new file mode 100644 index 000000000..931ce9d4d --- /dev/null +++ b/polling_location/migrations/0004_pollinglocationlogentry_log_entry_one_location_index.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-13 14:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0003_pollinglocationlogentry_kind_of_log_entry_and_deleted'), + ] + + operations = [ + migrations.AddIndex( + model_name='pollinglocationlogentry', + index=models.Index(fields=['polling_location_we_vote_id', 'kind_of_log_entry', 'log_entry_deleted'], name='log_entry_one_location_index'), + ), + ] diff --git a/polling_location/migrations/0005_pollinglocationlogentry_we_vote_id_and_kind_index_and_more.py b/polling_location/migrations/0005_pollinglocationlogentry_we_vote_id_and_kind_index_and_more.py new file mode 100644 index 000000000..b6853564d --- /dev/null +++ b/polling_location/migrations/0005_pollinglocationlogentry_we_vote_id_and_kind_index_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.3 on 2024-07-13 19:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0004_pollinglocationlogentry_log_entry_one_location_index'), + ] + + operations = [ + migrations.AddIndex( + model_name='pollinglocationlogentry', + index=models.Index(fields=['polling_location_we_vote_id', 'kind_of_log_entry'], name='we_vote_id_and_kind_index'), + ), + migrations.AddIndex( + model_name='pollinglocationlogentry', + index=models.Index(fields=['kind_of_log_entry', 'polling_location_we_vote_id'], name='kind_and_we_vote_id_index'), + ), + ] diff --git a/polling_location/migrations/0006_pollinglocation_state_and_not_deleted.py b/polling_location/migrations/0006_pollinglocation_state_and_not_deleted.py new file mode 100644 index 000000000..24da983ef --- /dev/null +++ b/polling_location/migrations/0006_pollinglocation_state_and_not_deleted.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-14 14:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0005_pollinglocationlogentry_we_vote_id_and_kind_index_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='pollinglocation', + index=models.Index(fields=['state', 'polling_location_deleted'], name='state_and_not_deleted'), + ), + ] diff --git a/polling_location/migrations/0007_pollinglocationlogentry_deleted_and_kind_of_log_entry.py b/polling_location/migrations/0007_pollinglocationlogentry_deleted_and_kind_of_log_entry.py new file mode 100644 index 000000000..68f4255f6 --- /dev/null +++ b/polling_location/migrations/0007_pollinglocationlogentry_deleted_and_kind_of_log_entry.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-18 17:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0006_pollinglocation_state_and_not_deleted'), + ] + + operations = [ + migrations.AddIndex( + model_name='pollinglocationlogentry', + index=models.Index(fields=['log_entry_deleted', 'kind_of_log_entry'], name='deleted_and_kind_of_log_entry'), + ), + ] diff --git a/polling_location/migrations/0008_remove_pollinglocationlogentry_kind_and_we_vote_id_index_and_more.py b/polling_location/migrations/0008_remove_pollinglocationlogentry_kind_and_we_vote_id_index_and_more.py new file mode 100644 index 000000000..09e6d1d20 --- /dev/null +++ b/polling_location/migrations/0008_remove_pollinglocationlogentry_kind_and_we_vote_id_index_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.8 on 2024-09-01 15:07 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('polling_location', '0007_pollinglocationlogentry_deleted_and_kind_of_log_entry'), + ] + + operations = [ + migrations.RemoveIndex( + model_name='pollinglocationlogentry', + name='kind_and_we_vote_id_index', + ), + migrations.RemoveIndex( + model_name='pollinglocationlogentry', + name='deleted_and_kind_of_log_entry', + ), + ] diff --git a/position/migrations/0001_initial.py b/position/migrations/0001_initial.py new file mode 100644 index 000000000..8d9cb1b04 --- /dev/null +++ b/position/migrations/0001_initial.py @@ -0,0 +1,167 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('twitter', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='PositionNetworkScore', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('viewing_voter_id', models.PositiveIntegerField(db_index=True)), + ('viewing_voter_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, db_index=True, default=None, null=True, verbose_name='google civic election id')), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('friend_voter_we_vote_id', models.CharField(max_length=255, null=True)), + ('candidate_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('measure_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('speaker_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the org or person with position')), + ('is_support', models.BooleanField(default=False)), + ('is_oppose', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='PositionForFriends', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('position_id', models.BigIntegerField(blank=True, null=True)), + ('test', models.BigIntegerField(blank=True, null=True)), + ('ballot_item_display_name', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='text name for ballot item')), + ('ballot_item_image_url_https', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https image for candidate, measure or office')), + ('ballot_item_image_url_https_large', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https large version image for candidate, measure or office')), + ('ballot_item_image_url_https_medium', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https medium version image for candidate, measure or office')), + ('ballot_item_image_url_https_tiny', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https tiny version image for candidate, measure or office')), + ('ballot_item_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name for candidate, measure, or office')), + ('speaker_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the org or person with position')), + ('speaker_image_url_https', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https image for org or person with position')), + ('speaker_image_url_https_large', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https large version image for org or person with position')), + ('speaker_image_url_https_medium', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https medium version image for org or person with position')), + ('speaker_image_url_https_tiny', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https tiny version image for org or person with position')), + ('speaker_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name for org or person with position')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('speaker_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='type of org')), + ('date_entered', models.DateTimeField(db_index=True, default=None, null=True, verbose_name='date entered')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('organization_id', models.BigIntegerField(blank=True, db_index=True, null=True)), + ('organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the organization')), + ('is_private_citizen', models.BooleanField(null=True)), + ('voter_id', models.BigIntegerField(blank=True, db_index=True, null=True)), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the voter expressing the opinion')), + ('public_figure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='public figure we vote id')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, db_index=True, default=0, null=True, verbose_name='google civic election id')), + ('position_ultimate_election_date', models.PositiveIntegerField(default=None, null=True)), + ('position_year', models.PositiveIntegerField(default=None, null=True)), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='us state of the ballot item position is for')), + ('vote_smart_rating_id', models.BigIntegerField(blank=True, null=True)), + ('vote_smart_time_span', models.CharField(blank=True, max_length=255, null=True, verbose_name='the period in which the organization stated this position')), + ('vote_smart_rating', models.CharField(blank=True, max_length=255, null=True, verbose_name='vote smart value between 0-100')), + ('vote_smart_rating_integer', models.PositiveIntegerField(blank=True, default=None, null=True, verbose_name='vote smart value between 0-100')), + ('vote_smart_rating_name', models.CharField(blank=True, max_length=255, null=True)), + ('tweet_source_id', models.BigIntegerField(blank=True, null=True)), + ('contest_office_id', models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='id of contest_office')), + ('contest_office_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_office')), + ('contest_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the office')), + ('race_office_level', models.CharField(blank=True, max_length=255, null=True, verbose_name='race office level')), + ('candidate_campaign_id', models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='id of candidate')), + ('candidate_campaign_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the candidate')), + ('google_civic_candidate_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate name exactly as received from google civic')), + ('politician_id', models.BigIntegerField(blank=True, null=True, verbose_name='')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for politician')), + ('political_party', models.CharField(max_length=255, null=True, verbose_name='candidate political party')), + ('contest_measure_id', models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='id of contest_measure')), + ('contest_measure_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_measure')), + ('google_civic_measure_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure title exactly as received from google civic')), + ('stance', models.CharField(choices=[('SUPPORT', 'Supports'), ('STILL_DECIDING', 'Still deciding'), ('NO_STANCE', 'No stance'), ('INFO_ONLY', 'Information only'), ('OPPOSE', 'Opposes'), ('PERCENT_RATING', 'Percentage point rating')], db_index=True, default='NO_STANCE', max_length=15)), + ('statement_text', models.TextField(blank=True, null=True)), + ('statement_html', models.TextField(blank=True, null=True)), + ('more_info_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url with more info about this position')), + ('from_scraper', models.BooleanField(default=False)), + ('organization_certified', models.BooleanField(default=False)), + ('volunteer_certified', models.BooleanField(default=False)), + ('twitter_user_entered_position', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='twitter.twitteruser', verbose_name='')), + ('voter_entering_position', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to=settings.AUTH_USER_MODEL, verbose_name='authenticated user who entered position')), + ], + options={ + 'ordering': ('date_entered',), + }, + ), + migrations.CreateModel( + name='PositionEntered', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('position_id', models.BigIntegerField(blank=True, null=True)), + ('test', models.BigIntegerField(blank=True, null=True)), + ('ballot_item_display_name', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='text name for ballot item')), + ('ballot_item_image_url_https', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https image for candidate, measure or office')), + ('ballot_item_image_url_https_large', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https large version image for candidate, measure or office')), + ('ballot_item_image_url_https_medium', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https medium version image for candidate, measure or office')), + ('ballot_item_image_url_https_tiny', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https tiny version image for candidate, measure or office')), + ('ballot_item_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name for candidate, measure, or office')), + ('speaker_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the org or person with position')), + ('speaker_image_url_https', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https image for org or person with position')), + ('speaker_image_url_https_large', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https large version image for org or person with position')), + ('speaker_image_url_https_medium', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https medium version image for org or person with position')), + ('speaker_image_url_https_tiny', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of https tiny version image for org or person with position')), + ('speaker_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name for org or person with position')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('speaker_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='type of org')), + ('date_entered', models.DateTimeField(db_index=True, default=None, null=True, verbose_name='date entered')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('organization_id', models.BigIntegerField(blank=True, db_index=True, null=True)), + ('organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the organization')), + ('is_private_citizen', models.BooleanField(null=True)), + ('voter_id', models.BigIntegerField(blank=True, db_index=True, null=True)), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the voter expressing the opinion')), + ('public_figure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='public figure we vote id')), + ('google_civic_election_id', models.CharField(db_index=True, default=0, max_length=255, null=True, verbose_name='google civic election id')), + ('position_ultimate_election_date', models.PositiveIntegerField(default=None, null=True)), + ('position_year', models.PositiveIntegerField(default=None, null=True)), + ('state_code', models.CharField(blank=True, db_index=True, max_length=2, null=True, verbose_name='us state of the ballot item position is for')), + ('google_civic_election_id_new', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('vote_smart_rating_id', models.BigIntegerField(blank=True, null=True)), + ('vote_smart_time_span', models.CharField(blank=True, max_length=255, null=True, verbose_name='the period in which the organization stated this position')), + ('vote_smart_rating', models.CharField(blank=True, max_length=255, null=True, verbose_name='vote smart value between 0-100')), + ('vote_smart_rating_integer', models.PositiveIntegerField(blank=True, default=None, null=True, verbose_name='vote smart value between 0-100')), + ('vote_smart_rating_name', models.CharField(blank=True, max_length=255, null=True)), + ('tweet_source_id', models.BigIntegerField(blank=True, null=True)), + ('contest_office_id', models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='id of contest_office')), + ('contest_office_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_office')), + ('contest_office_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the office')), + ('race_office_level', models.CharField(blank=True, max_length=255, null=True, verbose_name='race office level')), + ('candidate_campaign_id', models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='id of candidate')), + ('candidate_campaign_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the candidate')), + ('google_civic_candidate_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate name exactly as received from google civic')), + ('google_civic_measure_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='measure title exactly as received from google civic')), + ('politician_id', models.BigIntegerField(blank=True, null=True, verbose_name='')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for politician')), + ('political_party', models.CharField(max_length=255, null=True, verbose_name='political party')), + ('contest_measure_id', models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='id of contest_measure')), + ('contest_measure_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_measure')), + ('stance', models.CharField(choices=[('SUPPORT', 'Supports'), ('STILL_DECIDING', 'Still deciding'), ('NO_STANCE', 'No stance'), ('INFO_ONLY', 'Information only'), ('OPPOSE', 'Opposes'), ('PERCENT_RATING', 'Percentage point rating')], db_index=True, default='NO_STANCE', max_length=15)), + ('statement_text', models.TextField(blank=True, null=True)), + ('statement_html', models.TextField(blank=True, null=True)), + ('more_info_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url with more info about this position')), + ('from_scraper', models.BooleanField(default=False)), + ('organization_certified', models.BooleanField(default=False)), + ('volunteer_certified', models.BooleanField(default=False)), + ('twitter_user_entered_position', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='twitter.twitteruser', verbose_name='')), + ('voter_entering_position', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to=settings.AUTH_USER_MODEL, verbose_name='authenticated user who entered position')), + ], + options={ + 'ordering': ('date_entered',), + }, + ), + ] diff --git a/position/migrations/0002_auto_20230331_1340.py b/position/migrations/0002_auto_20230331_1340.py new file mode 100644 index 000000000..cce2f4662 --- /dev/null +++ b/position/migrations/0002_auto_20230331_1340.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-03-31 20:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='positionentered', + name='position_ultimate_election_not_linked', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='positionforfriends', + name='position_ultimate_election_not_linked', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/position/migrations/0003_auto_20230521_1027.py b/position/migrations/0003_auto_20230521_1027.py new file mode 100644 index 000000000..540c34a30 --- /dev/null +++ b/position/migrations/0003_auto_20230521_1027.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-05-21 17:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0002_auto_20230331_1340'), + ] + + operations = [ + migrations.AddField( + model_name='positionentered', + name='campaignx_supporter_created', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='positionforfriends', + name='campaignx_supporter_created', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/position/migrations/0004_auto_20240129_0555.py b/position/migrations/0004_auto_20240129_0555.py new file mode 100644 index 000000000..540084538 --- /dev/null +++ b/position/migrations/0004_auto_20240129_0555.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.23 on 2024-01-29 13:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0003_auto_20230521_1027'), + ] + + operations = [ + migrations.AlterField( + model_name='positionentered', + name='ballot_item_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username for candidate, measure, or office'), + ), + migrations.AlterField( + model_name='positionentered', + name='speaker_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username for org or person with position'), + ), + migrations.AlterField( + model_name='positionforfriends', + name='ballot_item_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username for candidate, measure, or office'), + ), + migrations.AlterField( + model_name='positionforfriends', + name='speaker_twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username for org or person with position'), + ), + ] diff --git a/position/migrations/0005_alter_positionentered_more_info_url_and_more.py b/position/migrations/0005_alter_positionentered_more_info_url_and_more.py new file mode 100644 index 000000000..3d0361ce9 --- /dev/null +++ b/position/migrations/0005_alter_positionentered_more_info_url_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-06-02 15:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0004_auto_20240129_0555'), + ] + + operations = [ + migrations.AlterField( + model_name='positionentered', + name='more_info_url', + field=models.TextField(null=True, verbose_name='url with more info about this position'), + ), + migrations.AlterField( + model_name='positionforfriends', + name='more_info_url', + field=models.TextField(null=True, verbose_name='url with more info about this position'), + ), + ] diff --git a/position/migrations/0006_positionentered_positions_for_candidate_index_and_more.py b/position/migrations/0006_positionentered_positions_for_candidate_index_and_more.py new file mode 100644 index 000000000..58a4bea2f --- /dev/null +++ b/position/migrations/0006_positionentered_positions_for_candidate_index_and_more.py @@ -0,0 +1,32 @@ +# Generated by Django 5.0.3 on 2024-07-13 14:38 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0005_alter_positionentered_more_info_url_and_more'), + ('twitter', '0007_alter_tweet_organization_we_vote_id_and_more'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'voter_we_vote_id', 'stance', '-date_entered'], name='positions_for_candidate_index'), + ), + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'organization_we_vote_id', 'google_civic_election_id', 'stance'], name='positions_for_election_index'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'voter_we_vote_id', 'stance', '-date_entered'], name='friends_positions_candidate'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'organization_we_vote_id', 'google_civic_election_id', 'stance'], name='friends_positions_election'), + ), + ] diff --git a/position/migrations/0007_rename_positions_for_candidate_index_positions_for_candidate_voter_and_more.py b/position/migrations/0007_rename_positions_for_candidate_index_positions_for_candidate_voter_and_more.py new file mode 100644 index 000000000..8d62defb2 --- /dev/null +++ b/position/migrations/0007_rename_positions_for_candidate_index_positions_for_candidate_voter_and_more.py @@ -0,0 +1,29 @@ +# Generated by Django 5.0.3 on 2024-07-13 15:58 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0006_positionentered_positions_for_candidate_index_and_more'), + ('twitter', '0007_alter_tweet_organization_we_vote_id_and_more'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.RenameIndex( + model_name='positionentered', + new_name='positions_for_candidate_voter', + old_name='positions_for_candidate_index', + ), + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'organization_we_vote_id'], name='positions_for_candidate_org'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'organization_we_vote_id'], name='friends_for_candidate_org'), + ), + ] diff --git a/position/migrations/0008_remove_positionentered_positions_for_election_index_and_more.py b/position/migrations/0008_remove_positionentered_positions_for_election_index_and_more.py new file mode 100644 index 000000000..73c694a85 --- /dev/null +++ b/position/migrations/0008_remove_positionentered_positions_for_election_index_and_more.py @@ -0,0 +1,40 @@ +# Generated by Django 5.0.3 on 2024-07-13 19:25 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0007_rename_positions_for_candidate_index_positions_for_candidate_voter_and_more'), + ('twitter', '0007_alter_tweet_organization_we_vote_id_and_more'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.RemoveIndex( + model_name='positionentered', + name='positions_for_election_index', + ), + migrations.RemoveIndex( + model_name='positionforfriends', + name='friends_positions_election', + ), + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'google_civic_election_id', 'organization_we_vote_id'], name='positions_for_election_index'), + ), + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['organization_we_vote_id', 'candidate_campaign_we_vote_id'], name='positions_for_org_candidate'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'google_civic_election_id', 'organization_we_vote_id'], name='friends_positions_election'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['organization_we_vote_id', 'candidate_campaign_we_vote_id'], name='friends_for_org_candidate'), + ), + ] diff --git a/position/migrations/0009_positionentered_politician_follow_created.py b/position/migrations/0009_positionentered_politician_follow_created.py new file mode 100644 index 000000000..cee0e8076 --- /dev/null +++ b/position/migrations/0009_positionentered_politician_follow_created.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-14 14:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0008_remove_positionentered_positions_for_election_index_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='positionentered', + name='politician_follow_created', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/position/migrations/0010_rename_politician_follow_created_positionentered_follow_organization_created_and_more.py b/position/migrations/0010_rename_politician_follow_created_positionentered_follow_organization_created_and_more.py new file mode 100644 index 000000000..42e7db235 --- /dev/null +++ b/position/migrations/0010_rename_politician_follow_created_positionentered_follow_organization_created_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-07-16 01:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0009_positionentered_politician_follow_created'), + ] + + operations = [ + migrations.RenameField( + model_name='positionentered', + old_name='politician_follow_created', + new_name='follow_organization_created', + ), + migrations.AddField( + model_name='positionentered', + name='follow_organization_analysis_complete', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='positionforfriends', + name='follow_organization_analysis_complete', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='positionforfriends', + name='follow_organization_created', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/position/migrations/0011_alter_positionentered_candidate_campaign_we_vote_id_and_more.py b/position/migrations/0011_alter_positionentered_candidate_campaign_we_vote_id_and_more.py new file mode 100644 index 000000000..f7c4bba88 --- /dev/null +++ b/position/migrations/0011_alter_positionentered_candidate_campaign_we_vote_id_and_more.py @@ -0,0 +1,34 @@ +# Generated by Django 5.0.3 on 2024-07-25 13:17 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0010_rename_politician_follow_created_positionentered_follow_organization_created_and_more'), + ('twitter', '0007_alter_tweet_organization_we_vote_id_and_more'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.AlterField( + model_name='positionentered', + name='candidate_campaign_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the candidate'), + ), + migrations.AlterField( + model_name='positionforfriends', + name='candidate_campaign_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the candidate'), + ), + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id'], name='candidate_we_vote_id'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['candidate_campaign_we_vote_id'], name='friends_candidate_we_vote_id'), + ), + ] diff --git a/position/migrations/0012_positionentered_politician_we_vote_id_analyzed_and_more.py b/position/migrations/0012_positionentered_politician_we_vote_id_analyzed_and_more.py new file mode 100644 index 000000000..e40126440 --- /dev/null +++ b/position/migrations/0012_positionentered_politician_we_vote_id_analyzed_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-27 20:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0011_alter_positionentered_candidate_campaign_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='positionentered', + name='politician_we_vote_id_analyzed', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='positionforfriends', + name='politician_we_vote_id_analyzed', + field=models.BooleanField(default=False), + ), + ] diff --git a/position/migrations/0013_remove_positionentered_positions_for_org_candidate_and_more.py b/position/migrations/0013_remove_positionentered_positions_for_org_candidate_and_more.py new file mode 100644 index 000000000..6501c312b --- /dev/null +++ b/position/migrations/0013_remove_positionentered_positions_for_org_candidate_and_more.py @@ -0,0 +1,24 @@ +# Generated by Django 5.0.8 on 2024-09-02 13:19 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0012_positionentered_politician_we_vote_id_analyzed_and_more'), + ('twitter', '0007_alter_tweet_organization_we_vote_id_and_more'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.RemoveIndex( + model_name='positionentered', + name='positions_for_org_candidate', + ), + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'google_civic_election_id'], name='cand_and_election_index'), + ), + ] diff --git a/position/migrations/0014_positionentered_candidate_voter_date_entered_and_more.py b/position/migrations/0014_positionentered_candidate_voter_date_entered_and_more.py new file mode 100644 index 000000000..1b822fe50 --- /dev/null +++ b/position/migrations/0014_positionentered_candidate_voter_date_entered_and_more.py @@ -0,0 +1,24 @@ +# Generated by Django 5.0.8 on 2024-09-04 18:48 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('position', '0013_remove_positionentered_positions_for_org_candidate_and_more'), + ('twitter', '0007_alter_tweet_organization_we_vote_id_and_more'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.AddIndex( + model_name='positionentered', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'voter_we_vote_id', '-date_entered'], name='candidate_voter_date_entered'), + ), + migrations.AddIndex( + model_name='positionforfriends', + index=models.Index(fields=['candidate_campaign_we_vote_id', 'voter_we_vote_id', '-date_entered'], name='friends_candidate_voter_date'), + ), + ] diff --git a/quick_info/migrations/0001_initial.py b/quick_info/migrations/0001_initial.py new file mode 100644 index 000000000..3155f76f1 --- /dev/null +++ b/quick_info/migrations/0001_initial.py @@ -0,0 +1,57 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='QuickInfo', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('language', models.CharField(choices=[('en', 'English'), ('es', 'Spanish'), ('tl', 'Tagalog'), ('vi', 'Vietnamese'), ('zh', 'Chinese')], default='en', max_length=5)), + ('info_text', models.TextField(blank=True, null=True)), + ('info_html', models.TextField(blank=True, null=True)), + ('ballot_item_display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='text name for ballot item for quick display')), + ('more_info_credit', models.CharField(blank=True, choices=[('not_specified', 'Not Specified'), ('ballotpedia', 'Ballotpedia'), ('direct', 'Direct Entry'), ('wikipedia', 'Wikipedia')], default='not_specified', max_length=15, null=True)), + ('more_info_url', models.URLField(blank=True, null=True, verbose_name='url with more the full entry for this info')), + ('last_updated', models.DateTimeField(auto_now=True, null=True, verbose_name='date entered')), + ('last_editor_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='last editor we vote id')), + ('contest_office_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_office')), + ('candidate_campaign_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the candidate')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for politician')), + ('contest_measure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id for the contest_measure')), + ('quick_info_master_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote id of other entry which is the master')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ], + options={ + 'ordering': ('last_updated',), + }, + ), + migrations.CreateModel( + name='QuickInfoMaster', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('kind_of_ballot_item', models.CharField(choices=[('OFFICE', 'Office'), ('CANDIDATE', 'Candidate'), ('POLITICIAN', 'Politician'), ('MEASURE', 'Measure')], default='OFFICE', max_length=10)), + ('language', models.CharField(choices=[('en', 'English'), ('es', 'Spanish'), ('tl', 'Tagalog'), ('vi', 'Vietnamese'), ('zh', 'Chinese')], default='en', max_length=5)), + ('info_text', models.TextField(blank=True, null=True)), + ('info_html', models.TextField(blank=True, null=True)), + ('master_entry_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='text name for quick info master entry')), + ('more_info_credit', models.CharField(blank=True, choices=[('not_specified', 'Not Specified'), ('ballotpedia', 'Ballotpedia'), ('direct', 'Direct Entry'), ('wikipedia', 'Wikipedia')], default='ballotpedia', max_length=15, null=True)), + ('more_info_url', models.URLField(blank=True, null=True, verbose_name='url with more the full entry for this info')), + ('last_updated', models.DateTimeField(auto_now=True, null=True, verbose_name='date entered')), + ('last_editor_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='last editor we vote id')), + ], + options={ + 'ordering': ('last_updated',), + }, + ), + ] diff --git a/quick_info/migrations/0002_alter_quickinfo_more_info_url_and_more.py b/quick_info/migrations/0002_alter_quickinfo_more_info_url_and_more.py new file mode 100644 index 000000000..3e1bfa591 --- /dev/null +++ b/quick_info/migrations/0002_alter_quickinfo_more_info_url_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-06-02 15:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('quick_info', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='quickinfo', + name='more_info_url', + field=models.TextField(null=True, verbose_name='url with more the full entry for this info'), + ), + migrations.AlterField( + model_name='quickinfomaster', + name='more_info_url', + field=models.TextField(null=True, verbose_name='url with more the full entry for this info'), + ), + ] diff --git a/reaction/migrations/0001_initial.py b/reaction/migrations/0001_initial.py new file mode 100644 index 000000000..7017d3ee5 --- /dev/null +++ b/reaction/migrations/0001_initial.py @@ -0,0 +1,26 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='ReactionLike', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_id', models.PositiveIntegerField(db_index=True, default=None, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('voter_display_name', models.CharField(max_length=255, null=True)), + ('liked_item_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('activity_tidbit_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/representative/migrations/0001_initial.py b/representative/migrations/0001_initial.py new file mode 100644 index 000000000..441194d51 --- /dev/null +++ b/representative/migrations/0001_initial.py @@ -0,0 +1,79 @@ +# Generated by Django 3.2.16 on 2023-01-10 15:10 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Representative', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote permanent id of this person in this position')), + ('office_held_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='office_held_id id')), + ('office_held_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id for the office this representative is running for')), + ('office_held_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='name of the office')), + ('politician_id', models.BigIntegerField(blank=True, null=True, verbose_name='politician unique identifier')), + ('politician_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote politician id')), + ('representative_name', models.CharField(max_length=255, verbose_name='representative name')), + ('google_civic_representative_name', models.CharField(max_length=255, verbose_name='representative name exactly as received from google civic')), + ('political_party', models.CharField(blank=True, max_length=255, null=True, verbose_name='political_party')), + ('photo_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='photoUrl')), + ('photo_url_from_maplight', models.URLField(blank=True, null=True, verbose_name='representative portrait url of representative from maplight')), + ('photo_url_from_vote_smart', models.URLField(blank=True, null=True, verbose_name='representative portrait url of representative from vote smart')), + ('order_on_ballot', models.CharField(blank=True, max_length=255, null=True, verbose_name='order on ballot')), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='google civic election id')), + ('ocd_division_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='ocd division id')), + ('state_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='state this representative serves')), + ('representative_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='website url of representative')), + ('facebook_url', models.URLField(blank=True, null=True, verbose_name='facebook url of representative')), + ('facebook_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of profile image from facebook')), + ('twitter_url', models.URLField(blank=True, null=True, verbose_name='twitter url of representative')), + ('twitter_user_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter id')), + ('representative_twitter_handle', models.CharField(max_length=255, null=True, verbose_name='representative twitter screen_name')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='representative plain text name from twitter')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='representative location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('twitter_profile_background_image_url_https', models.URLField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_banner_url_https', models.URLField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('we_vote_hosted_profile_image_url_large', models.URLField(blank=True, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_profile_image_url_medium', models.URLField(blank=True, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_profile_image_url_tiny', models.URLField(blank=True, null=True, verbose_name='we vote hosted tiny image url')), + ('google_plus_url', models.URLField(blank=True, null=True, verbose_name='google plus url of representative')), + ('vote_smart_id', models.CharField(max_length=200, null=True, verbose_name='votesmart unique identifier')), + ('maplight_id', models.CharField(blank=True, max_length=200, null=True, unique=True, verbose_name='maplight unique identifier')), + ('youtube_url', models.URLField(blank=True, null=True, verbose_name='youtube url of representative')), + ('representative_email', models.CharField(blank=True, max_length=255, null=True, verbose_name='representative email')), + ('representative_phone', models.CharField(blank=True, max_length=255, null=True, verbose_name='representative phone')), + ('wikipedia_page_id', models.BigIntegerField(blank=True, null=True, verbose_name='pageid')), + ('wikipedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Wikipedia')), + ('wikipedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of wikipedia logo')), + ('linkedin_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='linkedin url of representative')), + ('linkedin_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of linkedin logo')), + ('other_source_url', models.CharField(blank=True, max_length=255, null=True, verbose_name='other source url of representative')), + ('other_source_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of other source image')), + ('ballotpedia_representative_id', models.PositiveIntegerField(blank=True, null=True, verbose_name='ballotpedia integer id')), + ('ballotpedia_representative_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='representative name exactly as received from ballotpedia')), + ('ballotpedia_representative_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of representative on ballotpedia')), + ('ballotpedia_page_title', models.CharField(blank=True, max_length=255, null=True, verbose_name='Page title on Ballotpedia')), + ('ballotpedia_photo_url', models.URLField(blank=True, max_length=255, null=True, verbose_name='url of ballotpedia logo')), + ('ctcl_uuid', models.CharField(blank=True, max_length=36, null=True, verbose_name='ctcl uuid')), + ], + ), + migrations.CreateModel( + name='RepresentativesAreNotDuplicates', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('representative1_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='first representative we are tracking')), + ('representative2_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='second representative we are tracking')), + ], + ), + ] diff --git a/representative/migrations/0002_auto_20230126_1420.py b/representative/migrations/0002_auto_20230126_1420.py new file mode 100644 index 000000000..6bf3b4460 --- /dev/null +++ b/representative/migrations/0002_auto_20230126_1420.py @@ -0,0 +1,325 @@ +# Generated by Django 3.2.16 on 2023-01-26 22:20 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='RepresentativeToOfficeHeldLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('representative_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('office_held_we_vote_id', models.CharField(db_index=True, max_length=255)), + ('politician_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('years_in_office_flags', models.PositiveIntegerField(default=0)), + ], + ), + migrations.RemoveField( + model_name='representative', + name='ballotpedia_page_title', + ), + migrations.RemoveField( + model_name='representative', + name='ballotpedia_photo_url', + ), + migrations.RemoveField( + model_name='representative', + name='ballotpedia_representative_id', + ), + migrations.RemoveField( + model_name='representative', + name='ballotpedia_representative_name', + ), + migrations.RemoveField( + model_name='representative', + name='facebook_profile_image_url_https', + ), + migrations.RemoveField( + model_name='representative', + name='google_civic_election_id', + ), + migrations.RemoveField( + model_name='representative', + name='google_plus_url', + ), + migrations.RemoveField( + model_name='representative', + name='linkedin_photo_url', + ), + migrations.RemoveField( + model_name='representative', + name='maplight_id', + ), + migrations.RemoveField( + model_name='representative', + name='order_on_ballot', + ), + migrations.RemoveField( + model_name='representative', + name='other_source_photo_url', + ), + migrations.RemoveField( + model_name='representative', + name='other_source_url', + ), + migrations.RemoveField( + model_name='representative', + name='photo_url', + ), + migrations.RemoveField( + model_name='representative', + name='photo_url_from_maplight', + ), + migrations.RemoveField( + model_name='representative', + name='photo_url_from_vote_smart', + ), + migrations.RemoveField( + model_name='representative', + name='vote_smart_id', + ), + migrations.RemoveField( + model_name='representative', + name='wikipedia_page_id', + ), + migrations.RemoveField( + model_name='representative', + name='wikipedia_page_title', + ), + migrations.RemoveField( + model_name='representative', + name='wikipedia_photo_url', + ), + migrations.AddField( + model_name='representative', + name='date_last_updated_from_politician', + field=models.DateTimeField(default=None, null=True), + ), + migrations.AddField( + model_name='representative', + name='facebook_url_is_broken', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='google_civic_profile_image_url_https', + field=models.TextField(blank=True, default=None, null=True), + ), + migrations.AddField( + model_name='representative', + name='google_civic_representative_name2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='google_civic_representative_name3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='instagram_followers_count', + field=models.IntegerField(blank=True, default=0), + ), + migrations.AddField( + model_name='representative', + name='instagram_handle', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='photo_url_from_google_civic', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_contact_form_url', + field=models.TextField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_email2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_email3', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_phone2', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_phone3', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_twitter_handle2', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_twitter_handle3', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_url2', + field=models.TextField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='representative_url3', + field=models.TextField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='twitter_handle2_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='twitter_handle_updates_failing', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='vote_usa_politician_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='wikipedia_url', + field=models.TextField(null=True), + ), + migrations.AddField( + model_name='representative', + name='year_in_office_2023', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='representative', + name='year_in_office_2024', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='representative', + name='year_in_office_2025', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='representative', + name='year_in_office_2026', + field=models.BooleanField(default=None, null=True), + ), + migrations.AlterField( + model_name='representative', + name='ballotpedia_representative_url', + field=models.TextField(blank=True, max_length=255, null=True, verbose_name='url of representative on ballotpedia'), + ), + migrations.AlterField( + model_name='representative', + name='facebook_url', + field=models.TextField(blank=True, default=None, null=True), + ), + migrations.AlterField( + model_name='representative', + name='google_civic_representative_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='linkedin_url', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='politician_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='representative_email', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='representative_name', + field=models.CharField(max_length=255), + ), + migrations.AlterField( + model_name='representative', + name='representative_phone', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='representative_twitter_handle', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='representative_url', + field=models.TextField(blank=True, max_length=255, null=True), + ), + migrations.AlterField( + model_name='representative', + name='state_code', + field=models.CharField(max_length=2, null=True, verbose_name='state this representative serves'), + ), + migrations.AlterField( + model_name='representative', + name='twitter_followers_count', + field=models.IntegerField(blank=True, default=0), + ), + migrations.AlterField( + model_name='representative', + name='twitter_profile_background_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='tile-able background from twitter'), + ), + migrations.AlterField( + model_name='representative', + name='twitter_profile_banner_url_https', + field=models.TextField(blank=True, null=True, verbose_name='profile banner image from twitter'), + ), + migrations.AlterField( + model_name='representative', + name='twitter_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='url of logo from twitter'), + ), + migrations.AlterField( + model_name='representative', + name='twitter_url', + field=models.TextField(blank=True, null=True, verbose_name='twitter url of representative'), + ), + migrations.AlterField( + model_name='representative', + name='we_vote_hosted_profile_image_url_large', + field=models.TextField(null=True), + ), + migrations.AlterField( + model_name='representative', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(null=True), + ), + migrations.AlterField( + model_name='representative', + name='we_vote_hosted_profile_image_url_tiny', + field=models.TextField(null=True), + ), + migrations.AlterField( + model_name='representative', + name='youtube_url', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/representative/migrations/0003_auto_20230201_1248.py b/representative/migrations/0003_auto_20230201_1248.py new file mode 100644 index 000000000..d32305e7b --- /dev/null +++ b/representative/migrations/0003_auto_20230201_1248.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.16 on 2023-02-01 20:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0002_auto_20230126_1420'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='politician_deduplication_attempted', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='politician_match_attempted', + field=models.BooleanField(default=False), + ), + ] diff --git a/representative/migrations/0004_representativesmissingfrompollinglocation.py b/representative/migrations/0004_representativesmissingfrompollinglocation.py new file mode 100644 index 000000000..f0ac002ef --- /dev/null +++ b/representative/migrations/0004_representativesmissingfrompollinglocation.py @@ -0,0 +1,25 @@ +# Generated by Django 3.2.17 on 2023-02-04 16:45 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0003_auto_20230201_1248'), + ] + + operations = [ + migrations.CreateModel( + name='RepresentativesMissingFromPollingLocation', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_last_updated', models.DateTimeField(auto_now=True, db_index=True, verbose_name='date representatives last requested')), + ('error_message', models.TextField(default=None, null=True)), + ('is_from_google_civic', models.BooleanField(default=False)), + ('issue_resolved', models.BooleanField(default=False)), + ('polling_location_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote permanent id of the map point')), + ('state_code', models.CharField(db_index=True, max_length=2, null=True)), + ], + ), + ] diff --git a/representative/migrations/0005_auto_20230208_1449.py b/representative/migrations/0005_auto_20230208_1449.py new file mode 100644 index 000000000..0f61a605c --- /dev/null +++ b/representative/migrations/0005_auto_20230208_1449.py @@ -0,0 +1,78 @@ +# Generated by Django 3.2.17 on 2023-02-08 22:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0004_representativesmissingfrompollinglocation'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('FACEBOOK', 'Facebook'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA')], default='UNKNOWN', max_length=10), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_facebook_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_facebook_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_facebook_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_twitter_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_twitter_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_twitter_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_uploaded_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_uploaded_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_uploaded_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_vote_usa_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_vote_usa_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='we_vote_hosted_profile_vote_usa_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/representative/migrations/0006_auto_20230222_1441.py b/representative/migrations/0006_auto_20230222_1441.py new file mode 100644 index 000000000..4179e981a --- /dev/null +++ b/representative/migrations/0006_auto_20230222_1441.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.17 on 2023-02-22 22:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0005_auto_20230208_1449'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='is_battleground_race_2022', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2023', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2024', + field=models.BooleanField(default=False), + ), + ] diff --git a/representative/migrations/0007_auto_20230306_1649.py b/representative/migrations/0007_auto_20230306_1649.py new file mode 100644 index 000000000..d2e7289af --- /dev/null +++ b/representative/migrations/0007_auto_20230306_1649.py @@ -0,0 +1,43 @@ +# Generated by Django 3.2.18 on 2023-03-07 00:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0006_auto_20230222_1441'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='date_last_updated', + field=models.DateTimeField(auto_now=True, null=True), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2019', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2020', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2021', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2025', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='is_battleground_race_2026', + field=models.BooleanField(default=False), + ), + ] diff --git a/representative/migrations/0008_representative_seo_friendly_path.py b/representative/migrations/0008_representative_seo_friendly_path.py new file mode 100644 index 000000000..608e520ee --- /dev/null +++ b/representative/migrations/0008_representative_seo_friendly_path.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-24 03:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0007_auto_20230306_1649'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='seo_friendly_path', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/representative/migrations/0009_representative_seo_friendly_path_date_last_updated.py b/representative/migrations/0009_representative_seo_friendly_path_date_last_updated.py new file mode 100644 index 000000000..8e128b3d5 --- /dev/null +++ b/representative/migrations/0009_representative_seo_friendly_path_date_last_updated.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-03-24 17:35 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0008_representative_seo_friendly_path'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='seo_friendly_path_date_last_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/representative/migrations/0010_representative_office_held_district_name.py b/representative/migrations/0010_representative_office_held_district_name.py new file mode 100644 index 000000000..3d1b78874 --- /dev/null +++ b/representative/migrations/0010_representative_office_held_district_name.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-04-01 20:36 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0009_representative_seo_friendly_path_date_last_updated'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='office_held_district_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/representative/migrations/0011_delete_representativetoofficeheldlink.py b/representative/migrations/0011_delete_representativetoofficeheldlink.py new file mode 100644 index 000000000..773731cad --- /dev/null +++ b/representative/migrations/0011_delete_representativetoofficeheldlink.py @@ -0,0 +1,16 @@ +# Generated by Django 3.2.18 on 2023-04-15 14:09 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0010_representative_office_held_district_name'), + ] + + operations = [ + migrations.DeleteModel( + name='RepresentativeToOfficeHeldLink', + ), + ] diff --git a/representative/migrations/0012_auto_20230504_0648.py b/representative/migrations/0012_auto_20230504_0648.py new file mode 100644 index 000000000..9b0b580f9 --- /dev/null +++ b/representative/migrations/0012_auto_20230504_0648.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-05-04 13:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0011_delete_representativetoofficeheldlink'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='linked_campaignx_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='representative', + name='linked_campaignx_we_vote_id_date_last_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/representative/migrations/0013_representative_supporters_count.py b/representative/migrations/0013_representative_supporters_count.py new file mode 100644 index 000000000..eca260808 --- /dev/null +++ b/representative/migrations/0013_representative_supporters_count.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.18 on 2023-05-21 17:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0012_auto_20230504_0648'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='supporters_count', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/representative/migrations/0014_auto_20230629_0744.py b/representative/migrations/0014_auto_20230629_0744.py new file mode 100644 index 000000000..35a3c081e --- /dev/null +++ b/representative/migrations/0014_auto_20230629_0744.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.19 on 2023-06-29 14:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0013_representative_supporters_count'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='ocd_id_state_mismatch_checked', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='representative', + name='ocd_id_state_mismatch_found', + field=models.BooleanField(default=False), + ), + ] diff --git a/representative/migrations/0015_alter_representative_seo_friendly_path.py b/representative/migrations/0015_alter_representative_seo_friendly_path.py new file mode 100644 index 000000000..876cbf6f9 --- /dev/null +++ b/representative/migrations/0015_alter_representative_seo_friendly_path.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-12-16 19:25 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0014_auto_20230629_0744'), + ] + + operations = [ + migrations.AlterField( + model_name='representative', + name='seo_friendly_path', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/representative/migrations/0016_representative_profile_image_background_color.py b/representative/migrations/0016_representative_profile_image_background_color.py new file mode 100644 index 000000000..065aef192 --- /dev/null +++ b/representative/migrations/0016_representative_profile_image_background_color.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2023-12-21 15:21 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0015_alter_representative_seo_friendly_path'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='profile_image_background_color', + field=models.CharField(blank=True, max_length=7, null=True), + ), + ] diff --git a/representative/migrations/0017_alter_representative_profile_image_type_currently_active.py b/representative/migrations/0017_alter_representative_profile_image_type_currently_active.py new file mode 100644 index 000000000..126e0a66a --- /dev/null +++ b/representative/migrations/0017_alter_representative_profile_image_type_currently_active.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2024-02-11 02:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0016_representative_profile_image_background_color'), + ] + + operations = [ + migrations.AlterField( + model_name='representative', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('BALLOTPEDIA', 'Ballotpedia'), ('FACEBOOK', 'Facebook'), ('LINKEDIN', 'LinkedIn'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded'), ('VOTE_USA', 'Vote-USA'), ('WIKIPEDIA', 'Wikipedia')], default='UNKNOWN', max_length=11), + ), + ] diff --git a/representative/migrations/0018_representative_is_claimed_profile.py b/representative/migrations/0018_representative_is_claimed_profile.py new file mode 100644 index 000000000..6af01162c --- /dev/null +++ b/representative/migrations/0018_representative_is_claimed_profile.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-10-25 23:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('representative', '0017_alter_representative_profile_image_type_currently_active'), + ] + + operations = [ + migrations.AddField( + model_name='representative', + name='is_claimed_profile', + field=models.BooleanField(default=False), + ), + ] diff --git a/retrieve_tables/migrations/0001_initial.py b/retrieve_tables/migrations/0001_initial.py new file mode 100644 index 000000000..97b8075e3 --- /dev/null +++ b/retrieve_tables/migrations/0001_initial.py @@ -0,0 +1,27 @@ +# Generated by Django 3.2.25 on 2024-03-29 14:03 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='RetrieveTableState', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('is_running', models.BooleanField(default=False, verbose_name='Is the retrieve table running?')), + ('started_date', models.DateTimeField(auto_now_add=True, verbose_name='Date, tables retrieve started')), + ('table_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='Current table name')), + ('chunk', models.PositiveIntegerField(default=0, verbose_name='Current chunk number')), + ('current_record', models.PositiveIntegerField(default=0, verbose_name='Current record counter')), + ('total_records', models.PositiveIntegerField(default=0, verbose_name='Total records to be exported')), + ('voter_device_id', models.CharField(db_index=True, max_length=255, null=True, unique=True, verbose_name='voter device id')), + ], + ), + ] diff --git a/retrieve_tables/migrations/0002_remove_retrievetablestate_voter_device_id_and_more.py b/retrieve_tables/migrations/0002_remove_retrievetablestate_voter_device_id_and_more.py new file mode 100644 index 000000000..096dbb146 --- /dev/null +++ b/retrieve_tables/migrations/0002_remove_retrievetablestate_voter_device_id_and_more.py @@ -0,0 +1,22 @@ +# Generated by Django 5.0.3 on 2024-04-18 22:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('retrieve_tables', '0001_initial'), + ] + + operations = [ + migrations.RemoveField( + model_name='retrievetablestate', + name='voter_device_id', + ), + migrations.AddField( + model_name='retrievetablestate', + name='voter_api_device_id', + field=models.CharField(db_index=True, max_length=255, null=True, unique=True, verbose_name='voter_api_device_id'), + ), + ] diff --git a/share/migrations/0001_initial.py b/share/migrations/0001_initial.py new file mode 100644 index 000000000..50c2257cd --- /dev/null +++ b/share/migrations/0001_initial.py @@ -0,0 +1,114 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='SharedItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('destination_full_url', models.URLField(blank=True, max_length=255, null=True)), + ('shared_item_code_no_opinions', models.CharField(blank=True, db_index=True, max_length=50, null=True, unique=True)), + ('shared_item_code_all_opinions', models.CharField(blank=True, db_index=True, max_length=50, null=True, unique=True)), + ('shared_by_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('shared_by_organization_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='type of org')), + ('shared_by_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('shared_by_state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('site_owner_organization_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, default=0, null=True)), + ('hide_introduction', models.BooleanField(default=False)), + ('is_ballot_share', models.BooleanField(default=False)), + ('is_campaignx_share', models.BooleanField(default=False)), + ('is_candidate_share', models.BooleanField(default=False)), + ('is_measure_share', models.BooleanField(default=False)), + ('is_office_share', models.BooleanField(default=False)), + ('is_organization_share', models.BooleanField(default=False)), + ('is_ready_share', models.BooleanField(default=False)), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('candidate_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('measure_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('office_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('date_first_shared', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('year_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='SharedLinkClicked', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('destination_full_url', models.URLField(blank=True, max_length=255, null=True)), + ('shared_by_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('shared_by_organization_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='type of org')), + ('shared_by_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('shared_by_state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('viewed_by_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('viewed_by_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('viewed_by_state_code', models.CharField(db_index=True, max_length=2, null=True)), + ('shared_item_id', models.PositiveIntegerField(blank=True, default=0, null=True)), + ('shared_item_code', models.CharField(blank=True, db_index=True, max_length=50, null=True)), + ('site_owner_organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('include_public_positions', models.BooleanField(default=False)), + ('include_friends_only_positions', models.BooleanField(default=False)), + ('date_clicked', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('year_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ], + ), + migrations.CreateModel( + name='SharedPermissionsGranted', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('shared_by_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('shared_by_organization_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='type of org')), + ('shared_by_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('shared_to_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('shared_to_organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True)), + ('google_civic_election_id', models.PositiveIntegerField(blank=True, default=0, null=True)), + ('year_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('include_friends_only_positions', models.BooleanField(default=False)), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='SuperShareEmailRecipient', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('date_sent_to_email', models.DateTimeField(default=None, null=True)), + ('email_address_text', models.TextField(blank=True, db_index=True, null=True)), + ('google_contact_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('recipient_display_name', models.CharField(default=None, max_length=255, null=True)), + ('recipient_first_name', models.CharField(default=None, max_length=255, null=True)), + ('recipient_last_name', models.CharField(default=None, max_length=255, null=True)), + ('recipient_state_code', models.CharField(db_index=True, default=None, max_length=2, null=True)), + ('recipient_voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('shared_by_voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('super_share_item_id', models.PositiveIntegerField(blank=True, default=0, null=True)), + ], + ), + migrations.CreateModel( + name='SuperShareItem', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('campaignx_news_item_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('date_created', models.DateTimeField(auto_now_add=True, db_index=True, null=True)), + ('date_sent_to_email', models.DateTimeField(default=None, null=True)), + ('destination_full_url', models.URLField(blank=True, max_length=255, null=True)), + ('in_draft_mode', models.BooleanField(db_index=True, default=True)), + ('personalized_message', models.TextField(blank=True, db_index=True, null=True)), + ('personalized_subject', models.TextField(blank=True, db_index=True, null=True)), + ('shared_by_voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('site_owner_organization_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ], + ), + ] diff --git a/share/migrations/0002_auto_20220810_0843.py b/share/migrations/0002_auto_20220810_0843.py new file mode 100644 index 000000000..a04577ecb --- /dev/null +++ b/share/migrations/0002_auto_20220810_0843.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.15 on 2022-08-10 15:43 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='shareditem', + name='shared_by_display_name', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_by_we_vote_hosted_profile_image_url_large', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_by_we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_by_we_vote_hosted_profile_image_url_tiny', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/share/migrations/0003_auto_20221024_2026.py b/share/migrations/0003_auto_20221024_2026.py new file mode 100644 index 000000000..fdfb0b683 --- /dev/null +++ b/share/migrations/0003_auto_20221024_2026.py @@ -0,0 +1,58 @@ +# Generated by Django 3.2.15 on 2022-10-25 03:26 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0002_auto_20220810_0843'), + ] + + operations = [ + migrations.AddField( + model_name='shareditem', + name='email_secret_key', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='is_remind_contact_share', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='shareditem', + name='other_voter_display_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='other_voter_email_address_text', + field=models.TextField(blank=True, db_index=True, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='other_voter_first_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='other_voter_last_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='other_voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_message', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='sms_secret_key', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/share/migrations/0004_auto_20221026_1801.py b/share/migrations/0004_auto_20221026_1801.py new file mode 100644 index 000000000..404b92570 --- /dev/null +++ b/share/migrations/0004_auto_20221026_1801.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.15 on 2022-10-27 01:01 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0003_auto_20221024_2026'), + ] + + operations = [ + migrations.AddField( + model_name='shareditem', + name='shared_item_code_ready', + field=models.CharField(db_index=True, max_length=50, null=True, unique=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_item_code_remind_contacts', + field=models.CharField(db_index=True, max_length=50, null=True, unique=True), + ), + ] diff --git a/share/migrations/0005_auto_20221119_1136.py b/share/migrations/0005_auto_20221119_1136.py new file mode 100644 index 000000000..5c5888126 --- /dev/null +++ b/share/migrations/0005_auto_20221119_1136.py @@ -0,0 +1,68 @@ +# Generated by Django 3.2.16 on 2022-11-19 19:36 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0004_auto_20221026_1801'), + ] + + operations = [ + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_count', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_count_all_opinions', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_count_last_updated', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_count_no_opinions', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_count_ready', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_count_remind_contacts', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_unique_viewer_count', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_unique_viewer_count_all_opinions', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_unique_viewer_count_no_opinions', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_unique_viewer_count_ready', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_link_clicked_unique_viewer_count_remind_contacts', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + ] diff --git a/share/migrations/0006_voterwhosharessummaryalltime_voterwhosharessummaryoneyear.py b/share/migrations/0006_voterwhosharessummaryalltime_voterwhosharessummaryoneyear.py new file mode 100644 index 000000000..5cfe78ae5 --- /dev/null +++ b/share/migrations/0006_voterwhosharessummaryalltime_voterwhosharessummaryoneyear.py @@ -0,0 +1,42 @@ +# Generated by Django 3.2.16 on 2022-11-20 21:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0005_auto_20221119_1136'), + ] + + operations = [ + migrations.CreateModel( + name='VoterWhoSharesSummaryAllTime', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ('shared_by_display_name', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('shared_link_clicked_count', models.PositiveIntegerField(blank=True, default=0, null=True)), + ('shared_link_clicked_count_last_updated', models.DateTimeField(null=True)), + ('shared_link_clicked_unique_viewer_count', models.PositiveIntegerField(blank=True, default=0, null=True)), + ], + ), + migrations.CreateModel( + name='VoterWhoSharesSummaryOneYear', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ('shared_by_display_name', models.TextField(blank=True, null=True)), + ('year_as_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('shared_link_clicked_count', models.PositiveIntegerField(blank=True, default=0, null=True)), + ('shared_link_clicked_count_last_updated', models.DateTimeField(null=True)), + ('shared_link_clicked_unique_viewer_count', models.PositiveIntegerField(blank=True, default=0, null=True)), + ], + ), + ] diff --git a/share/migrations/0007_alter_voterwhosharessummaryoneyear_voter_we_vote_id.py b/share/migrations/0007_alter_voterwhosharessummaryoneyear_voter_we_vote_id.py new file mode 100644 index 000000000..fb0a48de7 --- /dev/null +++ b/share/migrations/0007_alter_voterwhosharessummaryoneyear_voter_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2022-11-21 19:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0006_voterwhosharessummaryalltime_voterwhosharessummaryoneyear'), + ] + + operations = [ + migrations.AlterField( + model_name='voterwhosharessummaryoneyear', + name='voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True), + ), + ] diff --git a/share/migrations/0008_auto_20221122_1256.py b/share/migrations/0008_auto_20221122_1256.py new file mode 100644 index 000000000..10b409b44 --- /dev/null +++ b/share/migrations/0008_auto_20221122_1256.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.16 on 2022-11-22 20:56 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0007_alter_voterwhosharessummaryoneyear_voter_we_vote_id'), + ] + + operations = [ + migrations.AddField( + model_name='voterwhosharessummaryalltime', + name='shared_item_count', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + migrations.AddField( + model_name='voterwhosharessummaryoneyear', + name='shared_item_count', + field=models.PositiveIntegerField(blank=True, default=0, null=True), + ), + ] diff --git a/share/migrations/0009_auto_20221128_1626.py b/share/migrations/0009_auto_20221128_1626.py new file mode 100644 index 000000000..ef1a9d04e --- /dev/null +++ b/share/migrations/0009_auto_20221128_1626.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.16 on 2022-11-29 00:26 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0008_auto_20221122_1256'), + ] + + operations = [ + migrations.AddField( + model_name='shareditem', + name='shared_by_first_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='shareditem', + name='shared_by_last_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/share/migrations/0010_alter_shareditem_destination_full_url_and_more.py b/share/migrations/0010_alter_shareditem_destination_full_url_and_more.py new file mode 100644 index 000000000..aa29e8a0e --- /dev/null +++ b/share/migrations/0010_alter_shareditem_destination_full_url_and_more.py @@ -0,0 +1,28 @@ +# Generated by Django 5.0.3 on 2024-06-05 12:46 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0009_auto_20221128_1626'), + ] + + operations = [ + migrations.AlterField( + model_name='shareditem', + name='destination_full_url', + field=models.TextField(null=True), + ), + migrations.AlterField( + model_name='sharedlinkclicked', + name='destination_full_url', + field=models.TextField(null=True), + ), + migrations.AlterField( + model_name='supershareitem', + name='destination_full_url', + field=models.TextField(null=True), + ), + ] diff --git a/share/migrations/0011_shareditem_is_challenge_share_and_more.py b/share/migrations/0011_shareditem_is_challenge_share_and_more.py new file mode 100644 index 000000000..d394616f5 --- /dev/null +++ b/share/migrations/0011_shareditem_is_challenge_share_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.9 on 2024-10-10 19:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('share', '0010_alter_shareditem_destination_full_url_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='shareditem', + name='is_challenge_share', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='shareditem', + name='shared_item_code_challenge', + field=models.CharField(db_index=True, max_length=50, null=True, unique=True), + ), + ] diff --git a/sms/migrations/0001_initial.py b/sms/migrations/0001_initial.py new file mode 100644 index 000000000..e074756c2 --- /dev/null +++ b/sms/migrations/0001_initial.py @@ -0,0 +1,56 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='SMSOutboundDescription', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('kind_of_sms_template', models.CharField(choices=[('SIGN_IN_CODE_SMS_TEMPLATE', 'Send code to verify sign in.')], default='SIGN_IN_CODE_SMS_TEMPLATE', max_length=50)), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('sender_voter_sms', models.CharField(blank=True, max_length=50, null=True, verbose_name='sms address for sender')), + ('recipient_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the recipient if we have it')), + ('recipient_sms_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='sms we vote id for recipient')), + ('recipient_voter_sms', models.CharField(blank=True, max_length=50, null=True, verbose_name='sms address for recipient')), + ('template_variables_in_json', models.TextField(blank=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='SMSPhoneNumber', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote id of this sms address')), + ('voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sms owner')), + ('normalized_sms_phone_number', models.CharField(max_length=50, verbose_name='sms address')), + ('sms_ownership_is_verified', models.BooleanField(default=False)), + ('sms_permanent_bounce', models.BooleanField(default=False)), + ('secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to verify ownership of sms')), + ('deleted', models.BooleanField(default=False)), + ], + ), + migrations.CreateModel( + name='SMSScheduled', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('message_text', models.TextField(blank=True, null=True)), + ('sender_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sender')), + ('sender_voter_sms', models.CharField(blank=True, max_length=50, null=True, verbose_name='sender sms address')), + ('recipient_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the recipient')), + ('recipient_sms_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote id for the sms')), + ('recipient_voter_sms', models.CharField(blank=True, max_length=50, null=True, verbose_name='recipient sms address')), + ('send_status', models.CharField(choices=[('TO_BE_PROCESSED', 'Message to be processed'), ('BEING_SENT', 'Message being sent'), ('SENT', 'Message sent')], default='TO_BE_PROCESSED', max_length=50)), + ('sms_description_id', models.PositiveIntegerField(default=0, verbose_name='the internal id of SMSOutboundDescription')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/sms/migrations/0002_alter_smsoutbounddescription_recipient_sms_we_vote_id_and_more.py b/sms/migrations/0002_alter_smsoutbounddescription_recipient_sms_we_vote_id_and_more.py new file mode 100644 index 000000000..e4e2b5c14 --- /dev/null +++ b/sms/migrations/0002_alter_smsoutbounddescription_recipient_sms_we_vote_id_and_more.py @@ -0,0 +1,53 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('sms', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='smsoutbounddescription', + name='recipient_sms_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='sms we vote id for recipient'), + ), + migrations.AlterField( + model_name='smsoutbounddescription', + name='recipient_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the recipient if we have it'), + ), + migrations.AlterField( + model_name='smsoutbounddescription', + name='sender_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender'), + ), + migrations.AlterField( + model_name='smsphonenumber', + name='voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sms owner'), + ), + migrations.AlterField( + model_name='smsphonenumber', + name='we_vote_id', + field=models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True, verbose_name='we vote id of this sms address'), + ), + migrations.AlterField( + model_name='smsscheduled', + name='recipient_sms_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sms'), + ), + migrations.AlterField( + model_name='smsscheduled', + name='recipient_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the recipient'), + ), + migrations.AlterField( + model_name='smsscheduled', + name='sender_voter_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote id for the sender'), + ), + ] diff --git a/stripe_donations/migrations/0001_initial.py b/stripe_donations/migrations/0001_initial.py new file mode 100644 index 000000000..07c9d4057 --- /dev/null +++ b/stripe_donations/migrations/0001_initial.py @@ -0,0 +1,101 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='StripeLinkToVoter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('stripe_customer_id', models.CharField(max_length=255, verbose_name='stripe unique customer id')), + ('voter_we_vote_id', models.CharField(max_length=255, verbose_name='unique we vote user id')), + ], + ), + migrations.CreateModel( + name='StripePayments', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='unique we vote user id')), + ('not_loggedin_voter_we_vote_id', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='unique we vote user id')), + ('stripe_customer_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe unique customer id')), + ('stripe_charge_id', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='unique charge id per specific donation')), + ('stripe_card_id', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='unique id for a credit/debit card')), + ('stripe_request_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe initial request id')), + ('stripe_subscription_id', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='unique subscription id for one voter, amount, and creation time')), + ('amount', models.PositiveIntegerField(default=0, null=True, verbose_name='donation amount')), + ('currency', models.CharField(blank=True, default='', max_length=8, null=True, verbose_name='donation currency country code')), + ('funding', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name="stripe returns 'credit' also might be debit, etc")), + ('livemode', models.BooleanField(blank=True, default=False, verbose_name='True: Live transaction, False: Test transaction')), + ('action_taken', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='action taken')), + ('action_result', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='action result')), + ('created', models.DateTimeField(verbose_name='stripe record creation timestamp')), + ('failure_code', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='failure code reported by stripe')), + ('failure_message', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name='failure message reported by stripe')), + ('network_status', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='network status reported by stripe')), + ('billing_reason', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='reason for billing from by stripe')), + ('reason', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name='reason for failure reported by stripe')), + ('seller_message', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name='plain text message to us from stripe')), + ('stripe_type', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='authorization outcome message to us from stripe')), + ('payment_msg', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='payment outcome message to us from stripe')), + ('is_paid', models.BooleanField(default=False, verbose_name='Charge has been paid')), + ('is_refunded', models.BooleanField(default=False, verbose_name='Charge has been refunded')), + ('source_obj', models.CharField(blank=True, default='card', max_length=32, null=True, verbose_name="stripe returns the donor's zip code")), + ('amount_refunded', models.PositiveIntegerField(default=0, null=True, verbose_name='refund amount')), + ('email', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name="stripe returns the donor's email address as a name")), + ('address_zip', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name="stripe returns the donor's zip code")), + ('brand', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='the brand of the credit card, eg. Visa, Amex')), + ('country', models.CharField(blank=True, default='', max_length=8, null=True, verbose_name='the country code of the bank that issued the credit card')), + ('exp_month', models.PositiveIntegerField(default=0, null=True, verbose_name='the expiration month of the credit card')), + ('exp_year', models.PositiveIntegerField(default=0, null=True, verbose_name='the expiration year of the credit card')), + ('last4', models.PositiveIntegerField(default=0, null=True, verbose_name='the last 4 digits of the credit card')), + ('stripe_status', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='status string reported by stripe')), + ('status', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name='our generated status message')), + ('we_plan_id', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='WeVote subscription plan id')), + ('paid_at', models.DateTimeField(null=True, verbose_name='stripe subscription most recent charge timestamp')), + ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='user ip address')), + ('is_chip_in', models.BooleanField(default=False, verbose_name="Is this a Campaign 'Chip In' payment?")), + ('is_premium_plan', models.BooleanField(default=False, verbose_name='is this a premium organization plan (and not a personal donation subscription)?')), + ('is_monthly_donation', models.BooleanField(default=False, verbose_name='is this a repeating monthly subscription donation?')), + ('campaignx_we_vote_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='Campaign we vote id, in order to credit chip ins')), + ('record_enum', models.CharField(blank=True, max_length=32, null=True, verbose_name='enum of record type {PAYMENT_FROM_UI, PAYMENT_AUTO_SUBSCRIPTION, SUBSCRIPTION_SETUP_AND_INITIAL}')), + ('api_version', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe API Version at creation time')), + ], + ), + migrations.CreateModel( + name='StripeSubscription', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_plan_id', models.CharField(blank=True, max_length=64, verbose_name='donation plan name')), + ('stripe_subscription_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe subscription id')), + ('voter_we_vote_id', models.CharField(blank=True, db_index=True, default='', max_length=64, null=True, verbose_name='we vote permanent id of the person who created this subscription')), + ('not_loggedin_voter_we_vote_id', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='unique we vote user id')), + ('stripe_customer_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe customer id')), + ('amount', models.PositiveIntegerField(default=0, verbose_name='recurring donation amount')), + ('billing_interval', models.CharField(default='month', max_length=64, verbose_name='recurring donation frequency')), + ('currency', models.CharField(default='usd', max_length=64, verbose_name='currency')), + ('donation_plan_is_active', models.BooleanField(default=True, verbose_name='status of recurring donation plan')), + ('subscription_created_at', models.DateTimeField(null=True, verbose_name='stripe subscription creation timestamp')), + ('subscription_canceled_at', models.DateTimeField(null=True, verbose_name='stripe subscription canceled timestamp')), + ('subscription_ended_at', models.DateTimeField(null=True, verbose_name='stripe subscription ended timestamp')), + ('stripe_charge_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe charge id')), + ('last_charged', models.DateTimeField(null=True, verbose_name='stripe subscription most recent charge timestamp')), + ('brand', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name='the brand of the credit card, eg. Visa, Amex')), + ('exp_month', models.PositiveIntegerField(default=0, verbose_name='the expiration month of the credit card')), + ('exp_year', models.PositiveIntegerField(default=0, verbose_name='the expiration year of the credit card')), + ('last4', models.PositiveIntegerField(default=0, verbose_name='the last 4 digits of the credit card')), + ('stripe_request_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe initial request id')), + ('linked_organization_we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=64, null=True, verbose_name='we vote permanent id of the organization who benefits from the organization subscription, but does not include the organizations that get credif for Chip Ins')), + ('api_version', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe API Version')), + ('livemode', models.BooleanField(default=False, verbose_name='True: Live transaction, False: Test transaction')), + ('client_ip', models.CharField(blank=True, max_length=32, null=True, verbose_name='Client IP address as seen by Stripe')), + ], + ), + ] diff --git a/stripe_donations/migrations/0002_stripedispute.py b/stripe_donations/migrations/0002_stripedispute.py new file mode 100644 index 000000000..e5b3d4bf3 --- /dev/null +++ b/stripe_donations/migrations/0002_stripedispute.py @@ -0,0 +1,41 @@ +# Generated by Django 3.2.13 on 2022-04-18 23:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('stripe_donations', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='StripeDispute', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('created', models.DateTimeField(null=True, verbose_name='stripe dispute creation timestamp')), + ('etype', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe transaction type')), + ('reason', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe dispute cause')), + ('transaction_status', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe transaction status')), + ('amount', models.IntegerField(default=0, verbose_name='disputed stripe charge amount')), + ('description', models.CharField(blank=True, max_length=64, null=True, verbose_name='stripe dispute description')), + ('fee', models.IntegerField(default=0, verbose_name='disputed stripe charge fee amount')), + ('total_cost', models.IntegerField(default=0, verbose_name='net charge by stripe including fees')), + ('fee_description', models.CharField(blank=True, max_length=32, null=True, verbose_name='stripe dispute fee description')), + ('evidence_due_by', models.DateTimeField(null=True, verbose_name='stripe deadline for submitting evidence')), + ('billing_address', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name="stripe returns the fraud initiator's zip code")), + ('customer_email_address', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name="stripe returns fraud initiator's email address as a name")), + ('customer_name', models.CharField(blank=True, default='', max_length=32, null=True, verbose_name="stripe returns the disputed customer's name")), + ('customer_purchase_ip', models.CharField(blank=True, max_length=32, null=True, verbose_name='Client IP address as seen by Stripe')), + ('charge_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe charge id')), + ('dispute_source_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe dispute id')), + ('balance_transaction_id', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe transaction id')), + ('transaction_state', models.CharField(blank=True, max_length=32, null=True, verbose_name='Stripe transaction state')), + ('evidence_has_evidence', models.BooleanField(default=False, verbose_name='We vote has submitted evidence about the transaction')), + ('evidence_past_due', models.BooleanField(default=False, verbose_name='We vote did not submit evidence in time')), + ('evidence_submission_count', models.IntegerField(default=0, verbose_name='Number of times evidence has been submitted')), + ('livemode', models.BooleanField(default=False, verbose_name='True: Live transaction, False: Test transaction')), + ], + ), + ] diff --git a/stripe_ip_history/migrations/0001_initial.py b/stripe_ip_history/migrations/0001_initial.py new file mode 100644 index 000000000..0f89c305e --- /dev/null +++ b/stripe_ip_history/migrations/0001_initial.py @@ -0,0 +1,31 @@ +# Generated by Django 3.2.17 on 2023-02-03 00:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='StripeIpHistory', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date', models.DateTimeField(auto_now=True, null=True, verbose_name='Date of the captcha test')), + ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='user ip address')), + ('country_code', models.CharField(blank=True, max_length=2, null=True, verbose_name='ISO Country code from GEOIP')), + ('voter_we_vote_id', models.CharField(max_length=255, verbose_name='Captcha session we vote user id')), + ('email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='voters email address, this is checked before they enter it on the donation form, so only what is in the voter record')), + ('captcha_score', models.FloatField(null=True, verbose_name='reCaptcha score returned from Google')), + ('captcha_success', models.BooleanField(default=True, verbose_name='reCaptcha success returned from Google')), + ('blocked_by_captcha', models.BooleanField(default=True, verbose_name='Did Google reCaptcha cause a block')), + ('blocked_by_country', models.BooleanField(default=True, verbose_name='Did our country check cause a block')), + ('blocked_by_frequency_hours', models.BooleanField(default=True, verbose_name='Did users frequency of donating cause a block (initially five in an hour) ')), + ('blocked_by_frequency_days', models.BooleanField(default=True, verbose_name='Did users frequency of donating cause a block (initially twenty in a week')), + ], + ), + ] diff --git a/tag/migrations/0001_initial.py b/tag/migrations/0001_initial.py new file mode 100644 index 000000000..754ae4cfa --- /dev/null +++ b/tag/migrations/0001_initial.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Tag', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('hashtag_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='the text for a single hashtag')), + ('twitter_handle', models.CharField(blank=True, max_length=15, null=True, verbose_name='twitter handle that we want to link to something')), + ('keywords', models.CharField(blank=True, max_length=255, null=True, verbose_name='text that might be found in a tweet')), + ], + ), + ] diff --git a/twitter/migrations/0001_initial.py b/twitter/migrations/0001_initial.py new file mode 100644 index 000000000..65dfc30a5 --- /dev/null +++ b/twitter/migrations/0001_initial.py @@ -0,0 +1,118 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Tweet', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('author_handle', models.CharField(default='', max_length=15, verbose_name="twitter handle of this tweet's author")), + ('twitter_id', models.BigIntegerField(default=0, verbose_name="twitter user's id of this tweet's author")), + ('tweet_id', models.BigIntegerField(default=0, verbose_name="id of this tweet's author")), + ('is_retweet', models.BooleanField(default=False, verbose_name='is this a retweet?')), + ('tweet_text', models.CharField(default='', max_length=280, verbose_name='text field from twitter tweet api')), + ('date_published', models.DateTimeField(null=True, verbose_name='date published')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='we vote permanent id')), + ], + ), + migrations.CreateModel( + name='TweetFavorite', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('tweet_id', models.BigIntegerField(default=0, verbose_name="id of this tweet's author")), + ('favorited_by_handle', models.CharField(max_length=15, verbose_name='twitter handle of person who favorited this tweet')), + ('date_favorited', models.DateTimeField(null=True, verbose_name='date favorited')), + ], + ), + migrations.CreateModel( + name='TwitterCursorState', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('twitter_id_of_me', models.BigIntegerField(verbose_name='twitter id of viewer')), + ('twitter_api_name', models.CharField(max_length=255, verbose_name='twitter api name')), + ('twitter_next_cursor', models.BigIntegerField(verbose_name='twitter next cursor state')), + ], + ), + migrations.CreateModel( + name='TwitterLinkPossibility', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('candidate_campaign_we_vote_id', models.CharField(max_length=255, verbose_name='candidate we vote id')), + ('search_term_used', models.CharField(max_length=255, verbose_name='')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='display name from twitter')), + ('not_a_match', models.BooleanField(default=False, verbose_name='')), + ('likelihood_score', models.IntegerField(null=True, verbose_name='')), + ('twitter_id', models.BigIntegerField(null=True, verbose_name='twitter big integer id')), + ('twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen name / handle')), + ('twitter_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('twitter_url', models.URLField(blank=True, null=True, verbose_name='url of website from twitter account')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_utc_offset', models.IntegerField(blank=True, default=0, null=True, verbose_name='utc_offset from twitter')), + ], + ), + migrations.CreateModel( + name='TwitterLinkToOrganization', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('organization_we_vote_id', models.CharField(max_length=255, unique=True, verbose_name='we vote id for the org owner')), + ('twitter_id', models.BigIntegerField(null=True, unique=True, verbose_name='twitter big integer id')), + ('date_last_changed', models.DateTimeField(auto_now=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='TwitterLinkToVoter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(max_length=255, unique=True, verbose_name='we vote id for the voter owner')), + ('twitter_id', models.BigIntegerField(unique=True, verbose_name='twitter big integer id')), + ('secret_key', models.CharField(max_length=255, unique=True, verbose_name='secret key to verify ownership twitter account')), + ('date_last_changed', models.DateTimeField(auto_now=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='TwitterUser', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('twitter_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter big integer id')), + ('twitter_handle', models.CharField(max_length=255, unique=True, verbose_name='twitter screen name / handle')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='display name from twitter')), + ('twitter_url', models.URLField(blank=True, null=True, verbose_name="url of user's website")), + ('twitter_profile_image_url_https', models.URLField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('twitter_location', models.CharField(blank=True, max_length=255, null=True, verbose_name='location from twitter')), + ('twitter_followers_count', models.IntegerField(blank=True, default=0, verbose_name='number of twitter followers')), + ('twitter_profile_background_image_url_https', models.URLField(blank=True, null=True, verbose_name='tile-able background from twitter')), + ('twitter_profile_banner_url_https', models.URLField(blank=True, null=True, verbose_name='profile banner image from twitter')), + ('we_vote_hosted_profile_image_url_large', models.URLField(blank=True, null=True, verbose_name='we vote hosted large image url')), + ('we_vote_hosted_profile_image_url_medium', models.URLField(blank=True, null=True, verbose_name='we vote hosted medium image url')), + ('we_vote_hosted_profile_image_url_tiny', models.URLField(blank=True, null=True, verbose_name='we vote hosted tiny image url')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ], + ), + migrations.CreateModel( + name='TwitterWhoFollowMe', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('handle_of_me', models.CharField(max_length=15, verbose_name="from this twitter handle's perspective...")), + ('handle_that_follows_me', models.CharField(max_length=15, verbose_name="twitter handle of this tweet's author")), + ], + ), + migrations.CreateModel( + name='TwitterWhoIFollow', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('twitter_id_of_me', models.BigIntegerField(verbose_name='twitter id of viewer')), + ('twitter_id_i_follow', models.BigIntegerField(verbose_name='twitter id of the friend')), + ], + ), + ] diff --git a/twitter/migrations/0002_auto_20230208_1449.py b/twitter/migrations/0002_auto_20230208_1449.py new file mode 100644 index 000000000..d17e17be2 --- /dev/null +++ b/twitter/migrations/0002_auto_20230208_1449.py @@ -0,0 +1,53 @@ +# Generated by Django 3.2.17 on 2023-02-08 22:49 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('twitter', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='twitteruser', + name='date_last_updated_from_twitter', + field=models.DateTimeField(null=True), + ), + migrations.AddField( + model_name='twitteruser', + name='twitter_handle_updates_failing', + field=models.BooleanField(default=None, null=True), + ), + migrations.AlterField( + model_name='twitteruser', + name='twitter_profile_background_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='tile-able background from twitter'), + ), + migrations.AlterField( + model_name='twitteruser', + name='twitter_profile_banner_url_https', + field=models.TextField(blank=True, null=True, verbose_name='profile banner image from twitter'), + ), + migrations.AlterField( + model_name='twitteruser', + name='twitter_profile_image_url_https', + field=models.TextField(blank=True, null=True, verbose_name='url of logo from twitter'), + ), + migrations.AlterField( + model_name='twitteruser', + name='we_vote_hosted_profile_image_url_large', + field=models.TextField(blank=True, null=True, verbose_name='we vote hosted large image url'), + ), + migrations.AlterField( + model_name='twitteruser', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True, verbose_name='we vote hosted medium image url'), + ), + migrations.AlterField( + model_name='twitteruser', + name='we_vote_hosted_profile_image_url_tiny', + field=models.TextField(blank=True, null=True, verbose_name='we vote hosted tiny image url'), + ), + ] diff --git a/twitter/migrations/0003_twitterapicounter_twitterapicounterdailysummary_twitterapicountermonthlysummary_twitterapicounterwee.py b/twitter/migrations/0003_twitterapicounter_twitterapicounterdailysummary_twitterapicountermonthlysummary_twitterapicounterwee.py new file mode 100644 index 000000000..815579d4e --- /dev/null +++ b/twitter/migrations/0003_twitterapicounter_twitterapicounterdailysummary_twitterapicountermonthlysummary_twitterapicounterwee.py @@ -0,0 +1,51 @@ +# Generated by Django 3.2.23 on 2024-01-27 16:24 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('twitter', '0002_auto_20230208_1449'), + ] + + operations = [ + migrations.CreateModel( + name='TwitterApiCounter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('kind_of_action', models.CharField(blank=True, db_index=True, max_length=50, null=True, verbose_name='kind of call to Twitter')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='TwitterApiCounterDailySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_of_action', models.DateField(verbose_name='date of action')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to Twitter')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='TwitterApiCounterMonthlySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('month_of_action', models.SmallIntegerField(verbose_name='number of the month')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to Twitter')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + migrations.CreateModel( + name='TwitterApiCounterWeeklySummary', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('year_of_action', models.SmallIntegerField(verbose_name='year of action')), + ('week_of_action', models.SmallIntegerField(verbose_name='number of the week')), + ('kind_of_action', models.CharField(blank=True, max_length=50, null=True, verbose_name='kind of call to Twitter')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ], + ), + ] diff --git a/twitter/migrations/0004_auto_20240308_1407.py b/twitter/migrations/0004_auto_20240308_1407.py new file mode 100644 index 000000000..e11883c2a --- /dev/null +++ b/twitter/migrations/0004_auto_20240308_1407.py @@ -0,0 +1,48 @@ +# Generated by Django 3.2.25 on 2024-03-08 22:07 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('twitter', '0003_twitterapicounter_twitterapicounterdailysummary_twitterapicountermonthlysummary_twitterapicounterwee'), + ] + + operations = [ + migrations.AddField( + model_name='twitterapicounter', + name='candidate_name', + field=models.CharField(max_length=255, null=True, verbose_name='twitter screen name / handle'), + ), + migrations.AddField( + model_name='twitterapicounter', + name='disambiguator', + field=models.PositiveIntegerField(default=0, null=True, verbose_name='disambiguate within the function'), + ), + migrations.AddField( + model_name='twitterapicounter', + name='function', + field=models.CharField(max_length=255, null=True, verbose_name='function'), + ), + migrations.AddField( + model_name='twitterapicounter', + name='search_term', + field=models.CharField(max_length=255, null=True, verbose_name='search term to API'), + ), + migrations.AddField( + model_name='twitterapicounter', + name='text', + field=models.CharField(max_length=255, null=True, verbose_name='text'), + ), + migrations.AddField( + model_name='twitterapicounter', + name='username', + field=models.CharField(max_length=64, null=True, verbose_name='twitter screen name / handle'), + ), + migrations.AddField( + model_name='twitterapicounter', + name='voter_we_vote_id', + field=models.CharField(max_length=255, null=True, verbose_name='voter we vote id'), + ), + ] diff --git a/twitter/migrations/0005_auto_20240311_1800.py b/twitter/migrations/0005_auto_20240311_1800.py new file mode 100644 index 000000000..e5371f74a --- /dev/null +++ b/twitter/migrations/0005_auto_20240311_1800.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.25 on 2024-03-12 01:00 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('twitter', '0004_auto_20240308_1407'), + ] + + operations = [ + migrations.AlterField( + model_name='twitteruser', + name='date_last_updated_from_twitter', + field=models.DateTimeField(db_index=True, null=True), + ), + migrations.AlterField( + model_name='twitteruser', + name='twitter_id', + field=models.BigIntegerField(blank=True, db_index=True, null=True, verbose_name='twitter big integer id'), + ), + ] diff --git a/twitter/migrations/0006_twitterapicounter_success.py b/twitter/migrations/0006_twitterapicounter_success.py new file mode 100644 index 000000000..edb35b8f7 --- /dev/null +++ b/twitter/migrations/0006_twitterapicounter_success.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.25 on 2024-03-14 03:51 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('twitter', '0005_auto_20240311_1800'), + ] + + operations = [ + migrations.AddField( + model_name='twitterapicounter', + name='success', + field=models.BooleanField(db_index=True, default=True, verbose_name='api call succeeded'), + ), + ] diff --git a/twitter/migrations/0007_alter_tweet_organization_we_vote_id_and_more.py b/twitter/migrations/0007_alter_tweet_organization_we_vote_id_and_more.py new file mode 100644 index 000000000..2bec8e7c2 --- /dev/null +++ b/twitter/migrations/0007_alter_tweet_organization_we_vote_id_and_more.py @@ -0,0 +1,43 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('twitter', '0006_twitterapicounter_success'), + ] + + operations = [ + migrations.AlterField( + model_name='tweet', + name='organization_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='we vote permanent id'), + ), + migrations.AlterField( + model_name='twitterapicounter', + name='voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, verbose_name='voter we vote id'), + ), + migrations.AlterField( + model_name='twitterlinkpossibility', + name='candidate_campaign_we_vote_id', + field=models.CharField(db_index=True, max_length=255, verbose_name='candidate we vote id'), + ), + migrations.AlterField( + model_name='twitterlinktoorganization', + name='organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, unique=True, verbose_name='we vote id for the org owner'), + ), + migrations.AlterField( + model_name='twitterlinktovoter', + name='twitter_id', + field=models.BigIntegerField(db_index=True, unique=True, verbose_name='twitter big integer id'), + ), + migrations.AlterField( + model_name='twitterlinktovoter', + name='voter_we_vote_id', + field=models.CharField(db_index=True, max_length=255, unique=True, verbose_name='we vote id for the voter owner'), + ), + ] diff --git a/volunteer_task/migrations/0001_initial.py b/volunteer_task/migrations/0001_initial.py new file mode 100644 index 000000000..9f85a632f --- /dev/null +++ b/volunteer_task/migrations/0001_initial.py @@ -0,0 +1,36 @@ +# Generated by Django 3.2.25 on 2024-03-11 19:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='VolunteerTaskCompleted', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('action_constant', models.PositiveSmallIntegerField(db_index=True, null=True)), + ('date_as_integer', models.PositiveIntegerField(db_index=True, null=True, verbose_name='YYYYMMDD of the action')), + ('exact_time', models.DateTimeField(auto_now_add=True, verbose_name='date and time of action')), + ('voter_id', models.PositiveIntegerField(default=None, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='VolunteerWeeklyMetrics', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('end_of_week_date_integer', models.PositiveIntegerField(db_index=True, null=True)), + ('voter_display_name', models.CharField(db_index=True, max_length=255, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('positions_saved', models.PositiveIntegerField(null=True)), + ('positions_written_saved', models.PositiveIntegerField(null=True)), + ], + ), + ] diff --git a/volunteer_task/migrations/0002_auto_20240313_2051.py b/volunteer_task/migrations/0002_auto_20240313_2051.py new file mode 100644 index 000000000..95169c7fd --- /dev/null +++ b/volunteer_task/migrations/0002_auto_20240313_2051.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.25 on 2024-03-14 03:51 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0001_initial'), + ] + + operations = [ + migrations.RenameField( + model_name='volunteerweeklymetrics', + old_name='positions_written_saved', + new_name='candidates_created', + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='position_comments_saved', + field=models.PositiveIntegerField(null=True), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='voter_date_unique_string', + field=models.CharField(db_index=True, max_length=255, null=True, unique=True), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='voter_guide_possibilities_created', + field=models.PositiveIntegerField(null=True), + ), + ] diff --git a/volunteer_task/migrations/0003_volunteerweeklymetrics_politicians_deduplicated.py b/volunteer_task/migrations/0003_volunteerweeklymetrics_politicians_deduplicated.py new file mode 100644 index 000000000..cdaf3785f --- /dev/null +++ b/volunteer_task/migrations/0003_volunteerweeklymetrics_politicians_deduplicated.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.25 on 2024-03-14 14:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0002_auto_20240313_2051'), + ] + + operations = [ + migrations.AddField( + model_name='volunteerweeklymetrics', + name='politicians_deduplicated', + field=models.PositiveIntegerField(null=True), + ), + ] diff --git a/volunteer_task/migrations/0004_volunteerteam_volunteerteammember.py b/volunteer_task/migrations/0004_volunteerteam_volunteerteammember.py new file mode 100644 index 000000000..ba8d800a6 --- /dev/null +++ b/volunteer_task/migrations/0004_volunteerteam_volunteerteammember.py @@ -0,0 +1,31 @@ +# Generated by Django 3.2.25 on 2024-04-03 13:42 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0003_volunteerweeklymetrics_politicians_deduplicated'), + ] + + operations = [ + migrations.CreateModel( + name='VolunteerTeam', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('team_name', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ('team_description', models.TextField(null=True)), + ('we_vote_id', models.CharField(blank=True, db_index=True, default=None, max_length=255, null=True, unique=True)), + ], + ), + migrations.CreateModel( + name='VolunteerTeamMember', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('team_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ], + ), + ] diff --git a/volunteer_task/migrations/0005_auto_20240407_1401.py b/volunteer_task/migrations/0005_auto_20240407_1401.py new file mode 100644 index 000000000..13c03036b --- /dev/null +++ b/volunteer_task/migrations/0005_auto_20240407_1401.py @@ -0,0 +1,53 @@ +# Generated by Django 3.2.25 on 2024-04-07 21:01 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0004_volunteerteam_volunteerteammember'), + ] + + operations = [ + migrations.AddField( + model_name='volunteerweeklymetrics', + name='politicians_augmented', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='politicians_photo_added', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='politicians_requested_changes', + field=models.PositiveIntegerField(default=0), + ), + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='candidates_created', + field=models.PositiveIntegerField(default=0), + ), + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='politicians_deduplicated', + field=models.PositiveIntegerField(default=0), + ), + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='position_comments_saved', + field=models.PositiveIntegerField(default=0), + ), + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='positions_saved', + field=models.PositiveIntegerField(default=0), + ), + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='voter_guide_possibilities_created', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/volunteer_task/migrations/0006_auto_20240407_2129.py b/volunteer_task/migrations/0006_auto_20240407_2129.py new file mode 100644 index 000000000..466a24a12 --- /dev/null +++ b/volunteer_task/migrations/0006_auto_20240407_2129.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.25 on 2024-04-08 04:29 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0005_auto_20240407_1401'), + ] + + operations = [ + migrations.AddField( + model_name='volunteerweeklymetrics', + name='duplicate_politician_analysis', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='election_retrieve_started', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='match_candidates_to_politicians', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='twitter_bulk_retrieve', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/volunteer_task/migrations/0007_volunteerteam_which_day_is_end_of_week_and_more.py b/volunteer_task/migrations/0007_volunteerteam_which_day_is_end_of_week_and_more.py new file mode 100644 index 000000000..65513bfa1 --- /dev/null +++ b/volunteer_task/migrations/0007_volunteerteam_which_day_is_end_of_week_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-04-28 22:17 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0006_auto_20240407_2129'), + ] + + operations = [ + migrations.AddField( + model_name='volunteerteam', + name='which_day_is_end_of_week', + field=models.PositiveIntegerField(default=6), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='which_day_is_end_of_week', + field=models.PositiveIntegerField(db_index=True, default=6), + ), + ] diff --git a/volunteer_task/migrations/0008_alter_volunteerweeklymetrics_voter_we_vote_id_and_more.py b/volunteer_task/migrations/0008_alter_volunteerweeklymetrics_voter_we_vote_id_and_more.py new file mode 100644 index 000000000..3c5afe687 --- /dev/null +++ b/volunteer_task/migrations/0008_alter_volunteerweeklymetrics_voter_we_vote_id_and_more.py @@ -0,0 +1,27 @@ +# Generated by Django 5.0.9 on 2024-11-11 21:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0007_volunteerteam_which_day_is_end_of_week_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='voter_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='which_day_is_end_of_week', + field=models.PositiveIntegerField(default=6), + ), + migrations.AddIndex( + model_name='volunteerweeklymetrics', + index=models.Index(fields=['voter_we_vote_id', 'which_day_is_end_of_week', 'end_of_week_date_integer'], name='vol_weekly_index'), + ), + ] diff --git a/volunteer_task/migrations/0009_alter_volunteerweeklymetrics_voter_date_unique_string_and_more.py b/volunteer_task/migrations/0009_alter_volunteerweeklymetrics_voter_date_unique_string_and_more.py new file mode 100644 index 000000000..e315411ca --- /dev/null +++ b/volunteer_task/migrations/0009_alter_volunteerweeklymetrics_voter_date_unique_string_and_more.py @@ -0,0 +1,22 @@ +# Generated by Django 5.0.9 on 2024-11-12 01:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0008_alter_volunteerweeklymetrics_voter_we_vote_id_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='volunteerweeklymetrics', + name='voter_date_unique_string', + field=models.CharField(max_length=255, null=True, unique=True), + ), + migrations.AddIndex( + model_name='volunteerweeklymetrics', + index=models.Index(fields=['voter_date_unique_string'], name='voter_date_unique_string'), + ), + ] diff --git a/volunteer_task/migrations/0010_volunteerweeklymetrics_date_last_updated_as_integer.py b/volunteer_task/migrations/0010_volunteerweeklymetrics_date_last_updated_as_integer.py new file mode 100644 index 000000000..117ad2827 --- /dev/null +++ b/volunteer_task/migrations/0010_volunteerweeklymetrics_date_last_updated_as_integer.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.9 on 2024-11-12 15:09 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0009_alter_volunteerweeklymetrics_voter_date_unique_string_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='volunteerweeklymetrics', + name='date_last_updated_as_integer', + field=models.PositiveIntegerField(null=True), + ), + ] diff --git a/volunteer_task/migrations/0011_volunteerweeklymetrics_organizations_augmented_and_more.py b/volunteer_task/migrations/0011_volunteerweeklymetrics_organizations_augmented_and_more.py new file mode 100644 index 000000000..50aa1bbe3 --- /dev/null +++ b/volunteer_task/migrations/0011_volunteerweeklymetrics_organizations_augmented_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.13 on 2025-06-15 23:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('volunteer_task', '0010_volunteerweeklymetrics_date_last_updated_as_integer'), + ] + + operations = [ + migrations.AddField( + model_name='volunteerweeklymetrics', + name='organizations_augmented', + field=models.PositiveIntegerField(default=0), + ), + migrations.AddField( + model_name='volunteerweeklymetrics', + name='organizations_deduplicated', + field=models.PositiveIntegerField(default=0), + ), + ] diff --git a/voter/migrations/0001_initial.py b/voter/migrations/0001_initial.py new file mode 100644 index 000000000..5b0fe29de --- /dev/null +++ b/voter/migrations/0001_initial.py @@ -0,0 +1,236 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +import django.core.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Voter', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('password', models.CharField(max_length=128, verbose_name='password')), + ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), + ('we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('linked_organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='we vote id for linked organization')), + ('email', models.EmailField(blank=True, max_length=255, null=True, unique=True, verbose_name='email address')), + ('primary_email_we_vote_id', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='we vote id for primary email for this voter')), + ('email_ownership_is_verified', models.BooleanField(default=False)), + ('normalized_sms_phone_number', models.CharField(blank=True, max_length=50, null=True)), + ('primary_sms_we_vote_id', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='we vote id for primary phone number')), + ('sms_ownership_is_verified', models.BooleanField(default=False)), + ('first_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='first name')), + ('middle_name', models.CharField(blank=True, max_length=255, null=True)), + ('last_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='last name')), + ('date_joined', models.DateTimeField(auto_now_add=True, verbose_name='date joined')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('data_to_preserve', models.BooleanField(default=False)), + ('is_active', models.BooleanField(default=True)), + ('is_admin', models.BooleanField(default=False)), + ('is_analytics_admin', models.BooleanField(default=False)), + ('is_partner_organization', models.BooleanField(default=False)), + ('is_political_data_manager', models.BooleanField(default=False)), + ('is_political_data_viewer', models.BooleanField(default=False)), + ('is_verified_volunteer', models.BooleanField(default=False)), + ('facebook_id', models.BigIntegerField(blank=True, null=True, verbose_name='facebook big integer id')), + ('facebook_email', models.EmailField(blank=True, max_length=255, null=True, verbose_name='facebook email address')), + ('fb_username', models.CharField(max_length=50, null=True, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z]*$', message='Only alphanumeric characters are allowed.')])), + ('facebook_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of image from facebook')), + ('twitter_id', models.BigIntegerField(blank=True, null=True, verbose_name='twitter big integer id')), + ('twitter_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='display name from twitter')), + ('twitter_screen_name', models.CharField(max_length=255, null=True, verbose_name='twitter screen name / handle')), + ('twitter_profile_image_url_https', models.TextField(blank=True, null=True, verbose_name='url of logo from twitter')), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True)), + ('profile_image_type_currently_active', models.CharField(choices=[('FACEBOOK', 'Facebook'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded')], default='UNKNOWN', max_length=10)), + ('we_vote_hosted_profile_facebook_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_facebook_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_facebook_image_url_tiny', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_twitter_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_twitter_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_twitter_image_url_tiny', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_uploaded_image_url_large', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_uploaded_image_url_medium', models.TextField(blank=True, null=True)), + ('we_vote_hosted_profile_uploaded_image_url_tiny', models.TextField(blank=True, null=True)), + ('twitter_request_token', models.TextField(blank=True, null=True, verbose_name='twitter request token')), + ('twitter_request_secret', models.TextField(blank=True, null=True, verbose_name='twitter request secret')), + ('twitter_access_token', models.TextField(blank=True, null=True, verbose_name='twitter access token')), + ('twitter_access_secret', models.TextField(blank=True, null=True, verbose_name='twitter access secret')), + ('twitter_connection_active', models.BooleanField(default=False)), + ('notification_settings_flags', models.PositiveIntegerField(default=1451)), + ('interface_status_flags', models.PositiveIntegerField(default=0, verbose_name='interface status flags')), + ('maintenance_status_flags', models.PositiveIntegerField(default=3)), + ], + options={ + 'abstract': False, + }, + ), + migrations.CreateModel( + name='ContactEmailAugmented', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('checked_against_open_people', models.BooleanField(db_index=True, default=False)), + ('checked_against_sendgrid', models.BooleanField(db_index=True, default=False)), + ('checked_against_snovio', models.BooleanField(db_index=True, default=False)), + ('checked_against_targetsmart', models.BooleanField(db_index=True, default=False)), + ('date_last_checked_against_open_people', models.DateTimeField(null=True)), + ('date_last_checked_against_sendgrid', models.DateTimeField(null=True)), + ('date_last_checked_against_snovio', models.DateTimeField(null=True)), + ('date_last_checked_against_targetsmart', models.DateTimeField(null=True)), + ('email_address_text', models.TextField(db_index=True, unique=True)), + ('has_known_bounces', models.BooleanField(default=False)), + ('has_mx_or_a_record', models.BooleanField(default=False)), + ('has_suspected_bounces', models.BooleanField(default=False)), + ('is_invalid', models.BooleanField(db_index=True, default=False)), + ('is_verified', models.BooleanField(db_index=True, default=False)), + ('open_people_first_name', models.CharField(max_length=255, null=True)), + ('open_people_last_name', models.CharField(max_length=255, null=True)), + ('open_people_middle_name', models.CharField(max_length=255, null=True)), + ('open_people_city', models.CharField(max_length=255, null=True)), + ('open_people_state_code', models.CharField(max_length=2, null=True)), + ('open_people_zip_code', models.CharField(max_length=10, null=True)), + ('snovio_id', models.CharField(max_length=255, null=True)), + ('snovio_locality', models.CharField(max_length=255, null=True)), + ('snovio_source_state', models.CharField(max_length=2, null=True)), + ('targetsmart_id', models.CharField(max_length=255, null=True)), + ('targetsmart_source_state', models.CharField(max_length=2, null=True)), + ], + ), + migrations.CreateModel( + name='ContactSMSAugmented', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('checked_against_open_people', models.BooleanField(db_index=True, default=False)), + ('checked_against_sendgrid', models.BooleanField(db_index=True, default=False)), + ('checked_against_targetsmart', models.BooleanField(db_index=True, default=False)), + ('date_last_checked_against_open_people', models.DateTimeField(null=True)), + ('date_last_checked_against_sendgrid', models.DateTimeField(null=True)), + ('date_last_checked_against_targetsmart', models.DateTimeField(null=True)), + ('is_augmented', models.BooleanField(db_index=True, default=False)), + ('is_invalid', models.BooleanField(db_index=True, default=False)), + ('is_verified', models.BooleanField(db_index=True, default=False)), + ('normalized_sms_phone_number', models.CharField(db_index=True, max_length=50, unique=True)), + ('open_people_city', models.CharField(max_length=255, null=True)), + ('open_people_state_code', models.CharField(max_length=2, null=True)), + ('open_people_zip_code', models.CharField(max_length=10, null=True)), + ('snovio_id', models.CharField(max_length=255, null=True)), + ('snovio_locality', models.CharField(max_length=255, null=True)), + ('snovio_source_state', models.CharField(max_length=2, null=True)), + ('targetsmart_id', models.CharField(max_length=255, null=True)), + ('targetsmart_source_state', models.CharField(max_length=2, null=True)), + ], + ), + migrations.CreateModel( + name='VoterAddress', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_id', models.BigIntegerField(db_index=True, verbose_name='voter unique identifier')), + ('address_type', models.CharField(choices=[('B', 'Address Where Registered to Vote'), ('M', 'Mailing Address'), ('F', 'Prior Address')], default='B', max_length=1, verbose_name='type of address')), + ('text_for_map_search', models.CharField(max_length=255, verbose_name='address as entered')), + ('latitude', models.CharField(blank=True, max_length=255, null=True, verbose_name='latitude returned from Google')), + ('longitude', models.CharField(blank=True, max_length=255, null=True, verbose_name='longitude returned from Google')), + ('normalized_line1', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized address line 1 returned from Google')), + ('normalized_line2', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized address line 2 returned from Google')), + ('normalized_city', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized city returned from Google')), + ('normalized_state', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized state returned from Google')), + ('normalized_zip', models.CharField(blank=True, max_length=255, null=True, verbose_name='normalized zip returned from Google')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id for this address')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('ballot_location_display_name', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='display name of ballot voter is viewing')), + ('ballot_returned_we_vote_id', models.CharField(blank=True, default=None, max_length=255, null=True, verbose_name='we vote id of the ballot')), + ('refreshed_from_google', models.BooleanField(db_index=True, default=False, verbose_name='have normalized fields been updated from Google since address change?')), + ('voter_entered_address', models.BooleanField(default=False, verbose_name='Did the voter manually enter an address?')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + ), + migrations.CreateModel( + name='VoterChangeLog', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True)), + ('date_of_change', models.DateTimeField(auto_now=True, null=True)), + ('change_table', models.CharField(choices=[('EmailAddress', 'EmailAddress'), ('VoterAddress', 'VoterAddress'), ('Voter', 'Voter')], default='Voter', max_length=50)), + ('change_field', models.CharField(max_length=255, null=True)), + ('change_description', models.CharField(max_length=255, null=True)), + ('is_system_update', models.BooleanField(default=False)), + ('value_type', models.CharField(choices=[('B', 'Boolean'), ('I', 'Integer'), ('S', 'String'), ('T', 'Text')], default='S', max_length=1, verbose_name='value_type')), + ('text_value_from', models.TextField(null=True)), + ('text_value_to', models.TextField(null=True)), + ('string_value_from', models.CharField(max_length=255, null=True)), + ('string_value_to', models.CharField(max_length=255, null=True)), + ('integer_value_from', models.BigIntegerField(null=True)), + ('integer_value_to', models.BigIntegerField(null=True)), + ('boolean_value_from', models.BooleanField(default=None, null=True)), + ('boolean_value_to', models.BooleanField(default=None, null=True)), + ], + ), + migrations.CreateModel( + name='VoterContactEmail', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('city', models.CharField(default=None, max_length=255, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True)), + ('display_name', models.CharField(default=None, max_length=255, null=True)), + ('email_address_text', models.TextField(blank=True, db_index=True, null=True)), + ('first_name', models.CharField(default=None, max_length=255, null=True)), + ('google_contact_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('google_date_last_updated', models.DateTimeField(null=True)), + ('google_display_name', models.CharField(default=None, max_length=255, null=True)), + ('google_first_name', models.CharField(default=None, max_length=255, null=True)), + ('google_last_name', models.CharField(default=None, max_length=255, null=True)), + ('has_data_from_google_people_api', models.BooleanField(default=False)), + ('ignore_contact', models.BooleanField(default=False)), + ('imported_by_voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('last_name', models.CharField(default=None, max_length=255, null=True)), + ('middle_name', models.CharField(default=None, max_length=255, null=True)), + ('state_code', models.CharField(db_index=True, default=None, max_length=2, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True)), + ('zip_code', models.CharField(default=None, max_length=10, null=True)), + ], + ), + migrations.CreateModel( + name='VoterDeviceLink', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_device_id', models.CharField(max_length=255, unique=True, verbose_name='voter device id')), + ('voter_id', models.BigIntegerField(verbose_name='voter unique identifier')), + ('google_civic_election_id', models.PositiveIntegerField(default=0, verbose_name='google civic election id')), + ('state_code', models.CharField(max_length=255, null=True, verbose_name='us state the device is most recently active in')), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('date_election_last_changed', models.DateTimeField(null=True)), + ('secret_code', models.CharField(max_length=6, null=True, verbose_name='single use secret code tied to this device')), + ('email_secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to verify ownership of email')), + ('sms_secret_key', models.CharField(blank=True, max_length=255, null=True, unique=True, verbose_name='secret key to verify ownership of sms')), + ('date_secret_code_generated', models.DateTimeField(null=True)), + ('secret_code_number_of_failed_tries_for_this_code', models.PositiveIntegerField(null=True)), + ('secret_code_number_of_failed_tries_all_time', models.PositiveIntegerField(null=True)), + ('platform_type', models.CharField(blank=True, max_length=32, null=True, verbose_name='Platform type string {IOS, ANDROID, WEBAPP}')), + ('firebase_fcm_token', models.CharField(blank=True, max_length=255, null=True, verbose_name='the Firebase Cloud Messaging (FCW) token for this device')), + ], + ), + migrations.CreateModel( + name='VoterPlan', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, default=None, null=True, verbose_name='google civic election id')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='us state code')), + ('voter_display_name', models.CharField(default=None, max_length=255, null=True)), + ('voter_display_city_state', models.CharField(default=None, max_length=255, null=True)), + ('voter_we_vote_id', models.CharField(db_index=True, default=None, max_length=255, null=True)), + ('voter_plan_data_serialized', models.TextField(blank=True, null=True)), + ('voter_plan_text', models.TextField(blank=True, null=True)), + ('show_to_public', models.BooleanField(default=False)), + ('date_entered', models.DateTimeField(auto_now_add=True, db_index=True, null=True, verbose_name='date entered')), + ('date_last_changed', models.DateTimeField(auto_now=True, db_index=True, null=True, verbose_name='date last changed')), + ], + ), + ] diff --git a/voter/migrations/0002_auto_20220429_1110.py b/voter/migrations/0002_auto_20220429_1110.py new file mode 100644 index 000000000..93a37256a --- /dev/null +++ b/voter/migrations/0002_auto_20220429_1110.py @@ -0,0 +1,13 @@ +# Generated by Django 3.2.13 on 2022-04-29 18:10 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0001_initial'), + ] + + operations = [ + ] diff --git a/voter/migrations/0003_auto_20220429_1358.py b/voter/migrations/0003_auto_20220429_1358.py new file mode 100644 index 000000000..e24a51e4a --- /dev/null +++ b/voter/migrations/0003_auto_20220429_1358.py @@ -0,0 +1,45 @@ +# Generated by Django 3.2.13 on 2022-04-29 20:58 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0002_auto_20220429_1110'), + ] + + operations = [ + migrations.RemoveField( + model_name='votercontactemail', + name='city', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='display_name', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='first_name', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='last_name', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='middle_name', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='voter_we_vote_id', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='we_vote_hosted_profile_image_url_medium', + ), + migrations.RemoveField( + model_name='votercontactemail', + name='zip_code', + ), + ] diff --git a/voter/migrations/0004_auto_20220429_1403.py b/voter/migrations/0004_auto_20220429_1403.py new file mode 100644 index 000000000..4b9060f5b --- /dev/null +++ b/voter/migrations/0004_auto_20220429_1403.py @@ -0,0 +1,53 @@ +# Generated by Django 3.2.13 on 2022-04-29 21:03 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0003_auto_20220429_1358'), + ] + + operations = [ + migrations.AddField( + model_name='votercontactemail', + name='city', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='display_name', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='first_name', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='last_name', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='middle_name', + field=models.CharField(default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='voter_we_vote_id', + field=models.CharField(db_index=True, default=None, max_length=255, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='we_vote_hosted_profile_image_url_medium', + field=models.TextField(blank=True, null=True), + ), + migrations.AddField( + model_name='votercontactemail', + name='zip_code', + field=models.CharField(default=None, max_length=10, null=True), + ), + ] diff --git a/voter/migrations/0005_auto_20220522_1747.py b/voter/migrations/0005_auto_20220522_1747.py new file mode 100644 index 000000000..167f5a35b --- /dev/null +++ b/voter/migrations/0005_auto_20220522_1747.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.13 on 2022-05-23 00:47 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0004_auto_20220429_1403'), + ] + + operations = [ + migrations.AddField( + model_name='voter', + name='state_code_for_display', + field=models.CharField(blank=True, max_length=2, null=True), + ), + migrations.AddField( + model_name='voter', + name='state_code_for_display_hidden', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='voter', + name='state_code_for_display_updated', + field=models.BooleanField(default=False), + ), + ] diff --git a/voter/migrations/0006_voter_friend_count.py b/voter/migrations/0006_voter_friend_count.py new file mode 100644 index 000000000..903f919fe --- /dev/null +++ b/voter/migrations/0006_voter_friend_count.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.13 on 2022-06-07 19:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0005_auto_20220522_1747'), + ] + + operations = [ + migrations.AddField( + model_name='voter', + name='friend_count', + field=models.PositiveIntegerField(default=None, null=True), + ), + ] diff --git a/voter/migrations/0007_votercontactemail_is_friend.py b/voter/migrations/0007_votercontactemail_is_friend.py new file mode 100644 index 000000000..233cdefe8 --- /dev/null +++ b/voter/migrations/0007_votercontactemail_is_friend.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.14 on 2022-07-25 22:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0006_voter_friend_count'), + ] + + operations = [ + migrations.AddField( + model_name='votercontactemail', + name='is_friend', + field=models.BooleanField(default=False), + ), + ] diff --git a/voter/migrations/0008_auto_20220915_0921.py b/voter/migrations/0008_auto_20220915_0921.py new file mode 100644 index 000000000..c61f4cb02 --- /dev/null +++ b/voter/migrations/0008_auto_20220915_0921.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.15 on 2022-09-15 16:21 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0007_votercontactemail_is_friend'), + ] + + operations = [ + migrations.AddField( + model_name='votercontactemail', + name='api_type', + field=models.CharField(default='google', max_length=16, verbose_name='apple google android etc'), + ), + migrations.AddField( + model_name='votercontactemail', + name='phone_number', + field=models.CharField(blank=True, max_length=64, null=True, verbose_name='contact phone number'), + ), + ] diff --git a/voter/migrations/0009_votermergelog_votermergestatus.py b/voter/migrations/0009_votermergelog_votermergestatus.py new file mode 100644 index 000000000..c751926dd --- /dev/null +++ b/voter/migrations/0009_votermergelog_votermergestatus.py @@ -0,0 +1,92 @@ +# Generated by Django 3.2.17 on 2023-02-22 22:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0008_auto_20220915_0921'), + ] + + operations = [ + migrations.CreateModel( + name='VoterMergeLog', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('from_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('log_datetime', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ('status', models.TextField(blank=True, null=True)), + ('step_duration', models.PositiveIntegerField(default=None, null=True)), + ('step_name', models.CharField(default=None, max_length=255, null=True)), + ('success', models.BooleanField(default=False)), + ('to_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ], + ), + migrations.CreateModel( + name='VoterMergeStatus', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('from_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('to_voter_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('from_linked_organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('to_linked_organization_we_vote_id', models.CharField(default=None, max_length=255, null=True)), + ('move_apple_user_complete', models.BooleanField(default=False)), + ('move_apple_user_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('repair_positions_complete', models.BooleanField(default=False)), + ('repair_positions_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_positions_complete', models.BooleanField(default=False)), + ('move_positions_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_organization_complete', models.BooleanField(default=False)), + ('move_organization_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_friends_complete', models.BooleanField(default=False)), + ('move_friends_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_follows_complete', models.BooleanField(default=False)), + ('move_follows_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_membership_link_complete', models.BooleanField(default=False)), + ('move_membership_link_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_org_team_complete', models.BooleanField(default=False)), + ('move_org_team_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_follow_issues_complete', models.BooleanField(default=False)), + ('move_follow_issues_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_email_complete', models.BooleanField(default=False)), + ('move_email_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_sms_complete', models.BooleanField(default=False)), + ('move_sms_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_facebook_complete', models.BooleanField(default=False)), + ('move_facebook_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_twitter_complete', models.BooleanField(default=False)), + ('move_twitter_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_voter_contact_complete', models.BooleanField(default=False)), + ('move_voter_contact_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_voter_plan_complete', models.BooleanField(default=False)), + ('move_voter_plan_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_donations_complete', models.BooleanField(default=False)), + ('move_donations_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_voter_guides_complete', models.BooleanField(default=False)), + ('move_voter_guides_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_shared_items_complete', models.BooleanField(default=False)), + ('move_shared_items_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_activity_notices_complete', models.BooleanField(default=False)), + ('move_activity_notices_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_activity_posts_complete', models.BooleanField(default=False)), + ('move_activity_posts_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_activity_comments_complete', models.BooleanField(default=False)), + ('move_activity_comments_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_campaignx_complete', models.BooleanField(default=False)), + ('move_campaignx_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_analytics_complete', models.BooleanField(default=False)), + ('move_analytics_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('merge_voter_complete', models.BooleanField(default=False)), + ('merge_voter_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('move_images_complete', models.BooleanField(default=False)), + ('move_images_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('send_emails_complete', models.BooleanField(default=False)), + ('send_emails_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('final_position_repair_complete', models.BooleanField(default=False)), + ('final_position_repair_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ('total_merge_complete', models.BooleanField(default=False)), + ('total_merge_milliseconds', models.PositiveIntegerField(default=None, null=True)), + ], + ), + ] diff --git a/voter/migrations/0010_auto_20230707_1616.py b/voter/migrations/0010_auto_20230707_1616.py new file mode 100644 index 000000000..98d05f760 --- /dev/null +++ b/voter/migrations/0010_auto_20230707_1616.py @@ -0,0 +1,38 @@ +# Generated by Django 3.2.19 on 2023-07-07 23:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0009_votermergelog_votermergestatus'), + ] + + operations = [ + migrations.AddField( + model_name='voter', + name='county_fips_code', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AddField( + model_name='voter', + name='county_id', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AddField( + model_name='voter', + name='county_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='voter', + name='latitude', + field=models.FloatField(default=None, null=True), + ), + migrations.AddField( + model_name='voter', + name='longitude', + field=models.FloatField(default=None, null=True), + ), + ] diff --git a/voter/migrations/0011_auto_20230709_0853.py b/voter/migrations/0011_auto_20230709_0853.py new file mode 100644 index 000000000..6d240b9be --- /dev/null +++ b/voter/migrations/0011_auto_20230709_0853.py @@ -0,0 +1,73 @@ +# Generated by Django 3.2.19 on 2023-07-09 15:53 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0010_auto_20230707_1616'), + ] + + operations = [ + migrations.CreateModel( + name='VoterIssuesLookup', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_we_vote_id', models.CharField(db_index=True, max_length=255, null=True, unique=True)), + ('likely_democrat_from_issues', models.BooleanField(default=None, null=True)), + ('likely_republican_from_issues', models.BooleanField(default=None, null=True)), + ('likely_party_from_issues_analyzed', models.BooleanField(default=False)), + ('affordable_housing', models.BooleanField(default=None, null=True)), + ('animals', models.BooleanField(default=None, null=True)), + ('bicycling', models.BooleanField(default=None, null=True)), + ('borders', models.BooleanField(default=None, null=True)), + ('climate_change', models.BooleanField(default=None, null=True)), + ('color', models.BooleanField(default=None, null=True)), + ('conservative', models.BooleanField(default=None, null=True)), + ('democratic_clubs', models.BooleanField(default=None, null=True)), + ('democratic_politicians', models.BooleanField(default=None, null=True)), + ('green_clubs', models.BooleanField(default=None, null=True)), + ('green_politicians', models.BooleanField(default=None, null=True)), + ('gun_reform', models.BooleanField(default=None, null=True)), + ('homeless', models.BooleanField(default=None, null=True)), + ('immigration', models.BooleanField(default=None, null=True)), + ('independent_politicians', models.BooleanField(default=None, null=True)), + ('justice_reform', models.BooleanField(default=None, null=True)), + ('lgbtq', models.BooleanField(default=None, null=True)), + ('libertarian_clubs', models.BooleanField(default=None, null=True)), + ('libertarian_politicians', models.BooleanField(default=None, null=True)), + ('low_income', models.BooleanField(default=None, null=True)), + ('maga', models.BooleanField(default=None, null=True)), + ('marijuana', models.BooleanField(default=None, null=True)), + ('money_in_politics', models.BooleanField(default=None, null=True)), + ('pro_choice', models.BooleanField(default=None, null=True)), + ('pro_life', models.BooleanField(default=None, null=True)), + ('pro_public_schools', models.BooleanField(default=None, null=True)), + ('pro_school_choice', models.BooleanField(default=None, null=True)), + ('progressive', models.BooleanField(default=None, null=True)), + ('public_healthcare', models.BooleanField(default=None, null=True)), + ('republican_clubs', models.BooleanField(default=None, null=True)), + ('republican_politicians', models.BooleanField(default=None, null=True)), + ('second_amendment', models.BooleanField(default=None, null=True)), + ('social_security', models.BooleanField(default=None, null=True)), + ('student_debt', models.BooleanField(default=None, null=True)), + ('voting_rights', models.BooleanField(default=None, null=True)), + ('womens_equality', models.BooleanField(default=None, null=True)), + ], + ), + migrations.RemoveField( + model_name='voter', + name='county_id', + ), + migrations.AddField( + model_name='voter', + name='voter_issues_lookup_updated', + field=models.BooleanField(default=False), + ), + migrations.AlterField( + model_name='voter', + name='county_fips_code', + field=models.CharField(max_length=5, null=True), + ), + ] diff --git a/voter/migrations/0012_auto_20230709_1344.py b/voter/migrations/0012_auto_20230709_1344.py new file mode 100644 index 000000000..f3509a334 --- /dev/null +++ b/voter/migrations/0012_auto_20230709_1344.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.19 on 2023-07-09 20:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0011_auto_20230709_0853'), + ] + + operations = [ + migrations.AddField( + model_name='voterissueslookup', + name='likely_green_from_issues', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='voterissueslookup', + name='likely_left_from_issues', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='voterissueslookup', + name='likely_libertarian_from_issues', + field=models.BooleanField(default=None, null=True), + ), + migrations.AddField( + model_name='voterissueslookup', + name='likely_right_from_issues', + field=models.BooleanField(default=None, null=True), + ), + ] diff --git a/voter/migrations/0013_auto_20230729_1248.py b/voter/migrations/0013_auto_20230729_1248.py new file mode 100644 index 000000000..0a92e104d --- /dev/null +++ b/voter/migrations/0013_auto_20230729_1248.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.20 on 2023-07-29 19:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0012_auto_20230709_1344'), + ] + + operations = [ + migrations.AddField( + model_name='voteraddress', + name='county_fips_code', + field=models.CharField(max_length=5, null=True, verbose_name='FIPS code for this county'), + ), + migrations.AddField( + model_name='voteraddress', + name='county_name', + field=models.CharField(max_length=255, null=True), + ), + migrations.AddField( + model_name='voteraddress', + name='invalid_address', + field=models.BooleanField(null=True, verbose_name='Garbage, misspelled, or unparsable address'), + ), + ] diff --git a/voter/migrations/0014_voter_is_signed_in_cached.py b/voter/migrations/0014_voter_is_signed_in_cached.py new file mode 100644 index 000000000..69ea7e5c3 --- /dev/null +++ b/voter/migrations/0014_voter_is_signed_in_cached.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.20 on 2023-09-02 16:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0013_auto_20230729_1248'), + ] + + operations = [ + migrations.AddField( + model_name='voter', + name='is_signed_in_cached', + field=models.BooleanField(db_index=True, default=None, null=True), + ), + ] diff --git a/voter/migrations/0015_alter_voter_profile_image_type_currently_active.py b/voter/migrations/0015_alter_voter_profile_image_type_currently_active.py new file mode 100644 index 000000000..1fcc39fde --- /dev/null +++ b/voter/migrations/0015_alter_voter_profile_image_type_currently_active.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2024-02-11 02:16 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0014_voter_is_signed_in_cached'), + ] + + operations = [ + migrations.AlterField( + model_name='voter', + name='profile_image_type_currently_active', + field=models.CharField(choices=[('FACEBOOK', 'Facebook'), ('TWITTER', 'Twitter'), ('UNKNOWN', 'Unknown'), ('UPLOADED', 'Uploaded')], default='UNKNOWN', max_length=11), + ), + ] diff --git a/voter/migrations/0016_voter_is_voter_manager.py b/voter/migrations/0016_voter_is_voter_manager.py new file mode 100644 index 000000000..d5ed7b65c --- /dev/null +++ b/voter/migrations/0016_voter_is_voter_manager.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.24 on 2024-02-24 22:32 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0015_alter_voter_profile_image_type_currently_active'), + ] + + operations = [ + migrations.AddField( + model_name='voter', + name='is_voter_manager', + field=models.BooleanField(default=False), + ), + ] diff --git a/voter/migrations/0017_auto_20240303_1539.py b/voter/migrations/0017_auto_20240303_1539.py new file mode 100644 index 000000000..d8a946d2f --- /dev/null +++ b/voter/migrations/0017_auto_20240303_1539.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.24 on 2024-03-03 23:39 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0016_voter_is_voter_manager'), + ] + + operations = [ + migrations.RenameField( + model_name='voter', + old_name='twitter_access_secret', + new_name='twitter_voters_access_secret', + ), + migrations.RenameField( + model_name='voter', + old_name='twitter_access_token', + new_name='twitter_voters_access_token_secret', + ), + ] diff --git a/voter/migrations/0018_auto_20240309_1804.py b/voter/migrations/0018_auto_20240309_1804.py new file mode 100644 index 000000000..33b157004 --- /dev/null +++ b/voter/migrations/0018_auto_20240309_1804.py @@ -0,0 +1,33 @@ +# Generated by Django 3.2.25 on 2024-03-10 02:04 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0017_auto_20240303_1539'), + ] + + operations = [ + migrations.AddField( + model_name='votermergestatus', + name='move_candidate_change_log_complete', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='votermergestatus', + name='move_candidate_change_log_milliseconds', + field=models.PositiveIntegerField(default=None, null=True), + ), + migrations.AddField( + model_name='votermergestatus', + name='move_voter_change_log_complete', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='votermergestatus', + name='move_voter_change_log_milliseconds', + field=models.PositiveIntegerField(default=None, null=True), + ), + ] diff --git a/voter/migrations/0019_alter_voter_linked_organization_we_vote_id.py b/voter/migrations/0019_alter_voter_linked_organization_we_vote_id.py new file mode 100644 index 000000000..7a50825cf --- /dev/null +++ b/voter/migrations/0019_alter_voter_linked_organization_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.25 on 2024-04-06 12:44 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0018_auto_20240309_1804'), + ] + + operations = [ + migrations.AlterField( + model_name='voter', + name='linked_organization_we_vote_id', + field=models.CharField(db_index=True, max_length=255, null=True, unique=True, verbose_name='we vote id for linked organization'), + ), + ] diff --git a/voter/migrations/0020_remove_voter_twitter_voters_access_secret_and_more.py b/voter/migrations/0020_remove_voter_twitter_voters_access_secret_and_more.py new file mode 100644 index 000000000..3aed7f9db --- /dev/null +++ b/voter/migrations/0020_remove_voter_twitter_voters_access_secret_and_more.py @@ -0,0 +1,27 @@ +# Generated by Django 5.0.3 on 2024-05-24 19:00 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0019_alter_voter_linked_organization_we_vote_id'), + ] + + operations = [ + migrations.RemoveField( + model_name='voter', + name='twitter_voters_access_secret', + ), + migrations.AddField( + model_name='voter', + name='twitter_voters_access_token', + field=models.TextField(blank=True, null=True, verbose_name='twitter access token'), + ), + migrations.AlterField( + model_name='voter', + name='twitter_voters_access_token_secret', + field=models.TextField(blank=True, null=True, verbose_name='twitter access token secret'), + ), + ] diff --git a/voter/migrations/0021_alter_voter_primary_email_we_vote_id_and_more.py b/voter/migrations/0021_alter_voter_primary_email_we_vote_id_and_more.py new file mode 100644 index 000000000..f030ce1b4 --- /dev/null +++ b/voter/migrations/0021_alter_voter_primary_email_we_vote_id_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.3 on 2024-07-13 04:37 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0020_remove_voter_twitter_voters_access_secret_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='voter', + name='primary_email_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True, verbose_name='we vote id for primary email for this voter'), + ), + migrations.AlterField( + model_name='voter', + name='primary_sms_we_vote_id', + field=models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True, verbose_name='we vote id for primary phone number'), + ), + ] diff --git a/voter/migrations/0022_voter_voter_fetch_voter_by_org_index_and_more.py b/voter/migrations/0022_voter_voter_fetch_voter_by_org_index_and_more.py new file mode 100644 index 000000000..7cc07dfcc --- /dev/null +++ b/voter/migrations/0022_voter_voter_fetch_voter_by_org_index_and_more.py @@ -0,0 +1,21 @@ +# Generated by Django 5.0.3 on 2024-07-13 14:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0021_alter_voter_primary_email_we_vote_id_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='voter', + index=models.Index(fields=['linked_organization_we_vote_id'], name='voter_fetch_voter_by_org_index'), + ), + migrations.AddIndex( + model_name='voter', + index=models.Index(fields=['primary_email_we_vote_id', 'primary_sms_we_vote_id', 'twitter_id', 'facebook_id'], name='voter_signin_count_index'), + ), + ] diff --git a/voter/migrations/0023_voter_fetch_voter_by_org2_index.py b/voter/migrations/0023_voter_fetch_voter_by_org2_index.py new file mode 100644 index 000000000..d5330875e --- /dev/null +++ b/voter/migrations/0023_voter_fetch_voter_by_org2_index.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.3 on 2024-07-13 15:58 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0022_voter_voter_fetch_voter_by_org_index_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='voter', + index=models.Index(fields=['linked_organization_we_vote_id', 'we_vote_id'], name='fetch_voter_by_org2_index'), + ), + ] diff --git a/voter/migrations/0024_alter_voter_linked_organization_we_vote_id.py b/voter/migrations/0024_alter_voter_linked_organization_we_vote_id.py new file mode 100644 index 000000000..3fa2a92b6 --- /dev/null +++ b/voter/migrations/0024_alter_voter_linked_organization_we_vote_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-07-16 20:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0023_voter_fetch_voter_by_org2_index'), + ] + + operations = [ + migrations.AlterField( + model_name='voter', + name='linked_organization_we_vote_id', + field=models.CharField(max_length=255, null=True, unique=True, verbose_name='we vote id for linked organization'), + ), + ] diff --git a/voter/migrations/0025_alter_voteraddress_voter_id_and_more.py b/voter/migrations/0025_alter_voteraddress_voter_id_and_more.py new file mode 100644 index 000000000..e7a1b26d6 --- /dev/null +++ b/voter/migrations/0025_alter_voteraddress_voter_id_and_more.py @@ -0,0 +1,26 @@ +# Generated by Django 5.0.8 on 2024-09-02 15:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0024_alter_voter_linked_organization_we_vote_id'), + ] + + operations = [ + migrations.AlterField( + model_name='voteraddress', + name='voter_id', + field=models.BigIntegerField(verbose_name='voter unique identifier'), + ), + migrations.AddIndex( + model_name='voteraddress', + index=models.Index(fields=['voter_id'], name='voter_id_address'), + ), + migrations.AddIndex( + model_name='voteraddress', + index=models.Index(fields=['voter_id', 'address_type'], name='voter_id_type'), + ), + ] diff --git a/voter/migrations/0026_voteraddress_voter_id_address_date.py b/voter/migrations/0026_voteraddress_voter_id_address_date.py new file mode 100644 index 000000000..89179667a --- /dev/null +++ b/voter/migrations/0026_voteraddress_voter_id_address_date.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.8 on 2024-09-04 18:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0025_alter_voteraddress_voter_id_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='voteraddress', + index=models.Index(fields=['voter_id', '-date_last_changed'], name='voter_id_address_date'), + ), + ] diff --git a/voter/migrations/0027_votermergestatus_move_challenges_complete_and_more.py b/voter/migrations/0027_votermergestatus_move_challenges_complete_and_more.py new file mode 100644 index 000000000..7d4aa91da --- /dev/null +++ b/voter/migrations/0027_votermergestatus_move_challenges_complete_and_more.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.8 on 2024-09-28 15:48 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0026_voteraddress_voter_id_address_date'), + ] + + operations = [ + migrations.AddField( + model_name='votermergestatus', + name='move_challenges_complete', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='votermergestatus', + name='move_challenges_milliseconds', + field=models.PositiveIntegerField(default=None, null=True), + ), + ] diff --git a/voter/migrations/0028_voter_app_review_date_voter_app_review_platform_and_more.py b/voter/migrations/0028_voter_app_review_date_voter_app_review_platform_and_more.py new file mode 100644 index 000000000..4cba30aaf --- /dev/null +++ b/voter/migrations/0028_voter_app_review_date_voter_app_review_platform_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.13 on 2026-01-13 02:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter', '0027_votermergestatus_move_challenges_complete_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='voter', + name='app_review_date', + field=models.DateTimeField(blank=True, null=True, verbose_name='app review (or negative bypass) date'), + ), + migrations.AddField( + model_name='voter', + name='app_review_platform', + field=models.CharField(blank=True, max_length=16, null=True, verbose_name='platform of reviewed app'), + ), + migrations.AddField( + model_name='voter', + name='app_review_state', + field=models.CharField(choices=[('NONE', 'None'), ('POSITIVE', 'Positive'), ('NEGATIVE', 'Negative')], default='NONE', max_length=11), + ), + migrations.AddField( + model_name='voter', + name='app_review_version', + field=models.CharField(blank=True, max_length=64, null=True, verbose_name='version of reviewed app'), + ), + ] diff --git a/voter_guide/migrations/0001_initial.py b/voter_guide/migrations/0001_initial.py new file mode 100644 index 000000000..2887dfcf8 --- /dev/null +++ b/voter_guide/migrations/0001_initial.py @@ -0,0 +1,108 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='VoterGuide', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, unique=True, verbose_name='we vote permanent id')), + ('organization_we_vote_id', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='organization we vote id')), + ('voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter who owns the organization')), + ('public_figure_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='public figure we vote id')), + ('owner_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name="individual voter's we vote id")), + ('owner_voter_id', models.PositiveIntegerField(default=0, null=True, verbose_name='the unique voter id of the voter who this guide is about')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True, verbose_name='google civic election id')), + ('election_day_text', models.CharField(blank=True, max_length=255, null=True, verbose_name='election day')), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='state the voter_guide is related to')), + ('vote_smart_time_span', models.CharField(blank=True, db_index=True, max_length=255, null=True, verbose_name='the period in which the organization stated this position')), + ('display_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='display title for this voter guide')), + ('image_url', models.TextField(blank=True, null=True, verbose_name='image url of logo/photo associated with voter guide')), + ('we_vote_hosted_profile_image_url_large', models.TextField(blank=True, null=True, verbose_name='large version image url of logo/photo associated with voter guide')), + ('we_vote_hosted_profile_image_url_medium', models.TextField(blank=True, null=True, verbose_name='medium version image url of logo/photo associated with voter guide')), + ('we_vote_hosted_profile_image_url_tiny', models.TextField(blank=True, null=True, verbose_name='tiny version image url of logo/photo associated with voter guide')), + ('voter_guide_owner_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='is owner org, public figure, or voter?')), + ('twitter_handle', models.CharField(max_length=255, null=True, verbose_name='twitter screen_name')), + ('twitter_description', models.CharField(blank=True, max_length=255, null=True, verbose_name='Text description of this organization from twitter.')), + ('twitter_followers_count', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='number of twitter followers')), + ('pledge_goal', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='target number of voters for pledge drive')), + ('pledge_count', models.PositiveIntegerField(blank=True, default=0, null=True, verbose_name='number of voters who have pledged')), + ('vote_smart_ratings_only', models.BooleanField(default=False)), + ('last_updated', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + options={ + 'ordering': ('last_updated',), + }, + ), + migrations.CreateModel( + name='VoterGuidePossibility', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_guide_possibility_url', models.TextField(blank=True, null=True, verbose_name='url of possible voter guide')), + ('voter_guide_possibility_pdf_url', models.TextField(blank=True, null=True, verbose_name='url of possible voter guide which is a PDF')), + ('organization_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization we vote id')), + ('candidate_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate name')), + ('candidate_twitter_handle', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate twitter handle')), + ('candidate_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='candidate we vote id')), + ('voter_who_submitted_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter name who submitted this')), + ('voter_who_submitted_we_vote_id', models.CharField(blank=True, max_length=255, null=True, verbose_name='voter we vote id who submitted this')), + ('assigned_to_name', models.CharField(blank=True, max_length=255, null=True)), + ('assigned_to_voter_we_vote_id', models.CharField(blank=True, max_length=255, null=True)), + ('state_code', models.CharField(max_length=2, null=True, verbose_name='state the voter guide is related to')), + ('voter_guide_owner_type', models.CharField(choices=[('C', 'Corporation'), ('G', 'Group'), ('I', 'Individual'), ('NW', 'News Corporation'), ('NP', 'Nonpartisan'), ('C3', 'Nonprofit 501c3'), ('C4', 'Nonprofit 501c4'), ('P', 'Political Action Committee'), ('PF', 'Public Figure'), ('TA', 'Trade Association or Union'), ('U', 'Unknown Type'), ('O', 'Group - Organization')], default='U', max_length=2, verbose_name='is owner org, public figure, or voter?')), + ('voter_guide_possibility_type', models.CharField(choices=[('ORG', 'Organization or News Website Endorsing Candidates'), ('CAND', 'List of Endorsements for One Candidate'), ('UNKNOWN', 'List of Endorsements for One Candidate')], default='UNKNOWN', max_length=7)), + ('organization_name', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization name')), + ('organization_twitter_handle', models.CharField(blank=True, max_length=255, null=True, verbose_name='organization twitter handle')), + ('organization_twitter_followers_count', models.PositiveIntegerField(blank=True, default=0)), + ('ballot_items_raw', models.TextField(blank=True, null=True)), + ('contributor_comments', models.TextField(blank=True, default=None, null=True)), + ('contributor_email', models.TextField(blank=True, default=None, null=True)), + ('target_google_civic_election_id', models.PositiveIntegerField(null=True)), + ('candidates_missing_from_we_vote', models.BooleanField(default=False)), + ('cannot_find_endorsements', models.BooleanField(default=False)), + ('capture_detailed_comments', models.BooleanField(default=False)), + ('from_prior_election', models.BooleanField(default=False)), + ('ignore_stored_positions', models.BooleanField(default=False)), + ('ignore_this_source', models.BooleanField(default=False)), + ('hide_from_active_review', models.BooleanField(default=False)), + ('batch_header_id', models.PositiveIntegerField(null=True)), + ('internal_notes', models.TextField(blank=True, default=None, null=True)), + ('date_created', models.DateTimeField(auto_now_add=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True, verbose_name='date last changed')), + ], + options={ + 'ordering': ('date_last_changed',), + }, + ), + migrations.CreateModel( + name='VoterGuidePossibilityPosition', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('voter_guide_possibility_parent_id', models.PositiveIntegerField(db_index=True, null=True)), + ('possibility_position_number', models.PositiveIntegerField(db_index=True, null=True)), + ('ballot_item_name', models.CharField(max_length=255, null=True)), + ('candidate_we_vote_id', models.CharField(max_length=255, null=True)), + ('candidate_twitter_handle', models.CharField(max_length=255, null=True)), + ('organization_name', models.CharField(max_length=255, null=True)), + ('organization_twitter_handle', models.CharField(max_length=255, null=True)), + ('organization_we_vote_id', models.CharField(max_length=255, null=True)), + ('position_we_vote_id', models.CharField(max_length=255, null=True)), + ('measure_we_vote_id', models.CharField(max_length=255, null=True)), + ('statement_text', models.TextField(blank=True, null=True)), + ('google_civic_election_id', models.PositiveIntegerField(null=True)), + ('position_stance', models.CharField(choices=[('SUPPORT', 'Supports'), ('NO_STANCE', 'No stance'), ('OPPOSE', 'Opposes')], default='SUPPORT', max_length=15)), + ('more_info_url', models.TextField(blank=True, null=True, verbose_name='url with more info about this position')), + ('possibility_should_be_ignored', models.BooleanField(default=False, verbose_name='Soft delete. Stop analyzing this entry.')), + ('position_should_be_removed', models.BooleanField(default=False, verbose_name='Delete saved position from PositionEntered.')), + ], + ), + ] diff --git a/voter_guide/migrations/0002_voterguidesgenerated.py b/voter_guide/migrations/0002_voterguidesgenerated.py new file mode 100644 index 000000000..b107ad10b --- /dev/null +++ b/voter_guide/migrations/0002_voterguidesgenerated.py @@ -0,0 +1,22 @@ +# Generated by Django 3.2.15 on 2022-09-13 03:02 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='VoterGuidesGenerated', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('google_civic_election_id', models.PositiveIntegerField(db_index=True, null=True)), + ('date_last_changed', models.DateTimeField(auto_now=True, null=True)), + ('number_of_voter_guides', models.PositiveIntegerField(null=True)), + ], + ), + ] diff --git a/voter_guide/migrations/0003_auto_20230608_1306.py b/voter_guide/migrations/0003_auto_20230608_1306.py new file mode 100644 index 000000000..a4e232c32 --- /dev/null +++ b/voter_guide/migrations/0003_auto_20230608_1306.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.18 on 2023-06-08 20:06 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0002_voterguidesgenerated'), + ] + + operations = [ + migrations.AddField( + model_name='voterguidepossibilityposition', + name='date_created', + field=models.DateTimeField(auto_now_add=True, null=True, verbose_name='date created'), + ), + migrations.AddField( + model_name='voterguidepossibilityposition', + name='date_updated', + field=models.DateTimeField(null=True), + ), + ] diff --git a/voter_guide/migrations/0004_alter_voterguide_twitter_handle.py b/voter_guide/migrations/0004_alter_voterguide_twitter_handle.py new file mode 100644 index 000000000..4f8ea3ca9 --- /dev/null +++ b/voter_guide/migrations/0004_alter_voterguide_twitter_handle.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.23 on 2024-01-29 13:55 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0003_auto_20230608_1306'), + ] + + operations = [ + migrations.AlterField( + model_name='voterguide', + name='twitter_handle', + field=models.CharField(max_length=255, null=True, verbose_name='twitter username'), + ), + ] diff --git a/voter_guide/migrations/0005_voterguidepossibilityposition_ballot_item_state_code.py b/voter_guide/migrations/0005_voterguidepossibilityposition_ballot_item_state_code.py new file mode 100644 index 000000000..002738f0a --- /dev/null +++ b/voter_guide/migrations/0005_voterguidepossibilityposition_ballot_item_state_code.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.25 on 2024-03-10 02:04 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0004_alter_voterguide_twitter_handle'), + ] + + operations = [ + migrations.AddField( + model_name='voterguidepossibilityposition', + name='ballot_item_state_code', + field=models.CharField(max_length=2, null=True), + ), + ] diff --git a/voter_guide/migrations/0006_alter_voterguidepossibilityposition_more_info_url.py b/voter_guide/migrations/0006_alter_voterguidepossibilityposition_more_info_url.py new file mode 100644 index 000000000..48572084f --- /dev/null +++ b/voter_guide/migrations/0006_alter_voterguidepossibilityposition_more_info_url.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-02 15:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0005_voterguidepossibilityposition_ballot_item_state_code'), + ] + + operations = [ + migrations.AlterField( + model_name='voterguidepossibilityposition', + name='more_info_url', + field=models.TextField(null=True, verbose_name='url with more info about this position'), + ), + ] diff --git a/voter_guide/migrations/0007_voterguidepossibility_done_needs_verification_and_more.py b/voter_guide/migrations/0007_voterguidepossibility_done_needs_verification_and_more.py new file mode 100644 index 000000000..f017632ac --- /dev/null +++ b/voter_guide/migrations/0007_voterguidepossibility_done_needs_verification_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.3 on 2024-06-24 15:23 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0006_alter_voterguidepossibilityposition_more_info_url'), + ] + + operations = [ + migrations.AddField( + model_name='voterguidepossibility', + name='done_needs_verification', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='voterguidepossibility', + name='done_verified', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='voterguidepossibility', + name='verified_by_name', + field=models.CharField(blank=True, max_length=255, null=True), + ), + migrations.AddField( + model_name='voterguidepossibility', + name='verified_by_we_vote_id', + field=models.CharField(blank=True, max_length=255, null=True), + ), + ] diff --git a/voter_guide/migrations/0008_voterguide_election_owner_followers.py b/voter_guide/migrations/0008_voterguide_election_owner_followers.py new file mode 100644 index 000000000..46bb4c6ce --- /dev/null +++ b/voter_guide/migrations/0008_voterguide_election_owner_followers.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.8 on 2024-09-02 13:19 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('voter_guide', '0007_voterguidepossibility_done_needs_verification_and_more'), + ] + + operations = [ + migrations.AddIndex( + model_name='voterguide', + index=models.Index(fields=['google_civic_election_id', 'voter_guide_owner_type', '-twitter_followers_count'], name='election_owner_followers'), + ), + ] diff --git a/wevote_settings/migrations/0001_initial.py b/wevote_settings/migrations/0001_initial.py new file mode 100644 index 000000000..ab3bdb538 --- /dev/null +++ b/wevote_settings/migrations/0001_initial.py @@ -0,0 +1,38 @@ +# Generated by Django 3.2.13 on 2022-04-17 00:28 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='RemoteRequestHistory', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('datetime_of_action', models.DateTimeField(auto_now=True, verbose_name='date and time of action')), + ('google_civic_election_id', models.PositiveIntegerField(null=True, verbose_name='google civic election id')), + ('kind_of_action', models.CharField(choices=[('RETRIEVE_UPDATE_DATA_FROM_TWITTER', 'Retrieve updated data from Twitter'), ('RETRIEVE_POSSIBLE_FACEBOOK_PHOTOS', 'Retrieve possible Facebook photos'), ('RETRIEVE_POSSIBLE_GOOGLE_LINKS', 'Retrieve possible google links'), ('RETRIEVE_POSSIBLE_TWITTER_HANDLES', 'Retrieve possible twitter handles'), ('STOP_BULK_SEARCH_TWITTER_LINK_POSSIBILITY', 'Stop search for Bulk twitter links')], max_length=50, null=True, verbose_name='kind of action to take')), + ('candidate_campaign_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='candidate we vote id')), + ('organization_we_vote_id', models.CharField(max_length=255, null=True, verbose_name='we vote id for the org owner')), + ('number_of_results', models.PositiveIntegerField(default=0, null=True, verbose_name='number of results')), + ('status', models.CharField(blank=True, default='', max_length=255, null=True, verbose_name='Request status message')), + ], + ), + migrations.CreateModel( + name='WeVoteSetting', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(blank=True, max_length=255, null=True, verbose_name='setting name')), + ('value_type', models.CharField(choices=[('S', 'String'), ('I', 'Integer'), ('B', 'Boolean')], default='S', max_length=1, verbose_name='value_type')), + ('string_value', models.CharField(blank=True, max_length=255, null=True, verbose_name='string value')), + ('integer_value', models.BigIntegerField(blank=True, null=True, verbose_name='integer value')), + ('boolean_value', models.BooleanField(blank=True, default=None, null=True, verbose_name='boolean value')), + ], + ), + ] diff --git a/wevote_settings/migrations/0002_alter_remoterequesthistory_status.py b/wevote_settings/migrations/0002_alter_remoterequesthistory_status.py new file mode 100644 index 000000000..17bf34f16 --- /dev/null +++ b/wevote_settings/migrations/0002_alter_remoterequesthistory_status.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.13 on 2022-04-27 21:40 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_settings', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='remoterequesthistory', + name='status', + field=models.TextField(blank=True, default='', null=True, verbose_name='Request status message'), + ), + ] diff --git a/wevote_settings/migrations/0003_wevotesetting_admin_app.py b/wevote_settings/migrations/0003_wevotesetting_admin_app.py new file mode 100644 index 000000000..3709320f1 --- /dev/null +++ b/wevote_settings/migrations/0003_wevotesetting_admin_app.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2.16 on 2023-01-03 22:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_settings', '0002_alter_remoterequesthistory_status'), + ] + + operations = [ + migrations.AddField( + model_name='wevotesetting', + name='admin_app', + field=models.BooleanField(default=False, verbose_name='allow changes via admin app'), + ), + ] diff --git a/wevote_settings/migrations/0004_auto_20230211_0733.py b/wevote_settings/migrations/0004_auto_20230211_0733.py new file mode 100644 index 000000000..8b0be4e9d --- /dev/null +++ b/wevote_settings/migrations/0004_auto_20230211_0733.py @@ -0,0 +1,28 @@ +# Generated by Django 3.2.17 on 2023-02-11 15:33 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_settings', '0003_wevotesetting_admin_app'), + ] + + operations = [ + migrations.AddField( + model_name='remoterequesthistory', + name='representative_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='remoterequesthistory', + name='candidate_campaign_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + migrations.AlterField( + model_name='remoterequesthistory', + name='organization_we_vote_id', + field=models.CharField(max_length=255, null=True), + ), + ] diff --git a/wevote_settings/migrations/0005_alter_remoterequesthistory_kind_of_action.py b/wevote_settings/migrations/0005_alter_remoterequesthistory_kind_of_action.py new file mode 100644 index 000000000..b091c6f54 --- /dev/null +++ b/wevote_settings/migrations/0005_alter_remoterequesthistory_kind_of_action.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-09 20:39 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_settings', '0004_auto_20230211_0733'), + ] + + operations = [ + migrations.AlterField( + model_name='remoterequesthistory', + name='kind_of_action', + field=models.CharField(choices=[('RETRIEVE_UPDATE_DATA_FROM_TWITTER', 'Retrieve updated data from Twitter'), ('RETRIEVE_POSSIBLE_BALLOTPEDIA_PHOTOS', 'Retrieve possible Ballotpedia photos'), ('RETRIEVE_POSSIBLE_FACEBOOK_PHOTOS', 'Retrieve possible Facebook photos'), ('RETRIEVE_POSSIBLE_GOOGLE_LINKS', 'Retrieve possible google links'), ('RETRIEVE_POSSIBLE_TWITTER_HANDLES', 'Retrieve possible twitter handles'), ('STOP_BULK_SEARCH_TWITTER_LINK_POSSIBILITY', 'Stop search for Bulk twitter links')], max_length=50, null=True, verbose_name='kind of action to take'), + ), + ] diff --git a/wevote_settings/migrations/0006_alter_remoterequesthistory_kind_of_action.py b/wevote_settings/migrations/0006_alter_remoterequesthistory_kind_of_action.py new file mode 100644 index 000000000..2ae96b534 --- /dev/null +++ b/wevote_settings/migrations/0006_alter_remoterequesthistory_kind_of_action.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-05-30 01:18 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_settings', '0005_alter_remoterequesthistory_kind_of_action'), + ] + + operations = [ + migrations.AlterField( + model_name='remoterequesthistory', + name='kind_of_action', + field=models.CharField(choices=[('RETRIEVE_UPDATE_DATA_FROM_TWITTER', 'Retrieve updated data from Twitter'), ('RETRIEVE_POSSIBLE_BALLOTPEDIA_PHOTOS', 'Retrieve possible Ballotpedia photos'), ('RETRIEVE_POSSIBLE_FACEBOOK_PHOTOS', 'Retrieve possible Facebook photos'), ('RETRIEVE_POSSIBLE_GOOGLE_LINKS', 'Retrieve possible google links'), ('RETRIEVE_POSSIBLE_TWITTER_HANDLES', 'Retrieve possible twitter handles'), ('RETRIEVE_POSSIBLE_WIKIPEDIA_PHOTOS', 'Retrieve possible Wikipedia photos'), ('STOP_BULK_SEARCH_TWITTER_LINK_POSSIBILITY', 'Stop search for Bulk twitter links')], max_length=50, null=True, verbose_name='kind of action to take'), + ), + ] diff --git a/wevote_settings/migrations/0007_alter_remoterequesthistory_kind_of_action.py b/wevote_settings/migrations/0007_alter_remoterequesthistory_kind_of_action.py new file mode 100644 index 000000000..ace1a2e42 --- /dev/null +++ b/wevote_settings/migrations/0007_alter_remoterequesthistory_kind_of_action.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.3 on 2024-06-11 05:41 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_settings', '0006_alter_remoterequesthistory_kind_of_action'), + ] + + operations = [ + migrations.AlterField( + model_name='remoterequesthistory', + name='kind_of_action', + field=models.CharField(choices=[('RETRIEVE_UPDATE_DATA_FROM_TWITTER', 'Retrieve updated data from Twitter'), ('RETRIEVE_POSSIBLE_BALLOTPEDIA_PHOTOS', 'Retrieve possible Ballotpedia photos'), ('RETRIEVE_POSSIBLE_FACEBOOK_PHOTOS', 'Retrieve possible Facebook photos'), ('RETRIEVE_POSSIBLE_GOOGLE_LINKS', 'Retrieve possible google links'), ('RETRIEVE_POSSIBLE_TWITTER_HANDLES', 'Retrieve possible twitter handles'), ('RETRIEVE_POSSIBLE_WIKIPEDIA_PHOTOS', 'Retrieve possible Wikipedia photos'), ('STOP_BULK_SEARCH_TWITTER_LINK_POSSIBILITY', 'Stop search for Bulk twitter links'), ('RETRIEVE_POSSIBLE_BALLOTPEDIA_CANDIDATES_LINKS', 'Retrieve possible Ballotpedia candidate links')], max_length=50, null=True, verbose_name='kind of action to take'), + ), + ] diff --git a/wevote_tokens/migrations/0001_initial.py b/wevote_tokens/migrations/0001_initial.py new file mode 100644 index 000000000..fb1ce5e72 --- /dev/null +++ b/wevote_tokens/migrations/0001_initial.py @@ -0,0 +1,33 @@ +# Generated by Django 5.0.13 on 2025-11-27 17:41 + +import django.db.models.deletion +import django.utils.timezone +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.CreateModel( + name='SingleUseToken', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('_validation', models.BinaryField(help_text='Field used to test if the passed validation key is valid.', verbose_name='Encoded Validation Data')), + ('_expiration_datetime', models.DateTimeField(help_text='When this token expires.', verbose_name='token expiration datetime')), + ('_json_data_encrypted', models.BinaryField(blank=True, default=None, help_text='Encrypted JSON blob for storing additional token data.', null=True, verbose_name='additional token data')), + ('_created_at', models.DateTimeField(db_index=True, default=django.utils.timezone.now, help_text='Timestamp when token was created.', verbose_name='token creation datetime')), + ('_user', models.ForeignKey(help_text='The user this token belongs to.', on_delete=django.db.models.deletion.CASCADE, related_name='single_use_tokens', to=settings.AUTH_USER_MODEL)), + ], + options={ + 'verbose_name': 'Single Use Token', + 'verbose_name_plural': 'Single Use Tokens', + }, + ), + ] diff --git a/wevote_tokens/migrations/0002_remove_singleusetoken__user_singleusetoken__user_id.py b/wevote_tokens/migrations/0002_remove_singleusetoken__user_singleusetoken__user_id.py new file mode 100644 index 000000000..ff5812855 --- /dev/null +++ b/wevote_tokens/migrations/0002_remove_singleusetoken__user_singleusetoken__user_id.py @@ -0,0 +1,23 @@ +# Generated by Django 5.0.13 on 2025-11-30 01:31 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_tokens', '0001_initial'), + ] + + operations = [ + migrations.RemoveField( + model_name='singleusetoken', + name='_user', + ), + migrations.AddField( + model_name='singleusetoken', + name='_user_id', + field=models.BinaryField(default=None, help_text='The user this token is assigned to.', verbose_name='user we_vote_id'), + preserve_default=False, + ), + ] diff --git a/wevote_tokens/migrations/0003_alter_singleusetoken__created_at_and_more.py b/wevote_tokens/migrations/0003_alter_singleusetoken__created_at_and_more.py new file mode 100644 index 000000000..3c335e220 --- /dev/null +++ b/wevote_tokens/migrations/0003_alter_singleusetoken__created_at_and_more.py @@ -0,0 +1,34 @@ +# Generated by Django 5.0.13 on 2025-11-30 01:43 + +import django.utils.timezone +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_tokens', '0002_remove_singleusetoken__user_singleusetoken__user_id'), + ] + + operations = [ + migrations.AlterField( + model_name='singleusetoken', + name='_created_at', + field=models.DateTimeField(db_index=True, default=django.utils.timezone.now, help_text='Timestamp when token was created.', null=True, verbose_name='token creation datetime'), + ), + migrations.AlterField( + model_name='singleusetoken', + name='_expiration_datetime', + field=models.DateTimeField(help_text='When this token expires.', null=True, verbose_name='token expiration datetime'), + ), + migrations.AlterField( + model_name='singleusetoken', + name='_user_id', + field=models.BinaryField(help_text='The user this token is assigned to.', null=True, verbose_name='user we_vote_id'), + ), + migrations.AlterField( + model_name='singleusetoken', + name='_validation', + field=models.BinaryField(help_text='Field used to test if the passed validation key is valid.', null=True, verbose_name='Encoded Validation Data'), + ), + ] diff --git a/wevote_tokens/migrations/0004_singleusetoken__scope.py b/wevote_tokens/migrations/0004_singleusetoken__scope.py new file mode 100644 index 000000000..e44337f9d --- /dev/null +++ b/wevote_tokens/migrations/0004_singleusetoken__scope.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-12-03 15:15 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_tokens', '0003_alter_singleusetoken__created_at_and_more'), + ] + + operations = [ + migrations.AddField( + model_name='singleusetoken', + name='_scope', + field=models.IntegerField(choices=[(0, 'none'), (1, 'backup_one_table_to_s3')], default=0, help_text='The scope of the token.', verbose_name='scope'), + ), + ] diff --git a/wevote_tokens/migrations/0005_remove_singleusetoken__user_id.py b/wevote_tokens/migrations/0005_remove_singleusetoken__user_id.py new file mode 100644 index 000000000..a0fadbf3c --- /dev/null +++ b/wevote_tokens/migrations/0005_remove_singleusetoken__user_id.py @@ -0,0 +1,17 @@ +# Generated by Django 5.0.13 on 2025-12-06 02:10 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_tokens', '0004_singleusetoken__scope'), + ] + + operations = [ + migrations.RemoveField( + model_name='singleusetoken', + name='_user_id', + ), + ] diff --git a/wevote_tokens/migrations/0006_singleusetoken__user_id.py b/wevote_tokens/migrations/0006_singleusetoken__user_id.py new file mode 100644 index 000000000..4236a5993 --- /dev/null +++ b/wevote_tokens/migrations/0006_singleusetoken__user_id.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0.13 on 2025-12-06 06:31 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('wevote_tokens', '0005_remove_singleusetoken__user_id'), + ] + + operations = [ + migrations.AddField( + model_name='singleusetoken', + name='_user_id', + field=models.CharField(db_index=True, default=None, help_text='The user this token is assigned to.', max_length=255, null=True, verbose_name='user we_vote_id'), + ), + ] From 775b4e336a8bbedd46f3cd86c7a4dfba56f59796 Mon Sep 17 00:00:00 2001 From: Joe Evans Date: Wed, 4 Mar 2026 16:30:48 +0000 Subject: [PATCH 2/2] Remove migrations files from .gitignore --- .gitignore | 2 -- 1 file changed, 2 deletions(-) diff --git a/.gitignore b/.gitignore index cc0c98f4b..3df59d325 100644 --- a/.gitignore +++ b/.gitignore @@ -151,8 +151,6 @@ staticfiles /geoip/import_data/* !/geoip/import_data/__init__.py /**/geoip-api-c -/**/migrations/*.py -!/**/migrations/__init__.py config/environment_variables.json config/environment_variables*.bak.json web_app/build/*