Skip to content

Instantly share code, notes, and snippets.

@david-mears-2
Created April 3, 2024 19:30
Show Gist options
  • Save david-mears-2/db93ad0656bcfb5c628790863501741c to your computer and use it in GitHub Desktop.
Save david-mears-2/db93ad0656bcfb5c628790863501741c to your computer and use it in GitHub Desktop.
note of what the partners' donor questions schema were before migration
Partner.where(name: ['One For The World', 'One For The World UK', 'One For The World Canada', 'One For The World Australia']).pluck(:name, :donor_questions_schema).to_s
=> "[[\"One For The World Canada\", {\"questions\"=>[{\"name\"=>\"phone_number\", \"type\"=>\"text\", \"title\"=>\"What is your phone number?\", \"options\"=>[], \"required\"=>true}, {\"name\"=>\"GDPR_static_text\", \"type\"=>\"statictext\", \"title\"=>\" One for the World would occasionally like to send you information about our charities, your impact and other initiatives. If you are happy to receive this information, please indicate here:\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_email\", \"type\"=>\"checkbox\", \"title\"=>\"By Email\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_phone\", \"type\"=>\"checkbox\", \"title\"=>\"By SMS (By selecting this box, you agree to receive donor engagement texts from One For The World. Message frequency varies. Message and data rates may apply. Reply STOP to unsubscribe at any time.)\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"chapter\", \"type\"=>\"select\", \"title\"=>\"What chapter are you associated with?\", \"options\"=>[\"N/A\", \"Bain Canada\", \"Brock University\", \"Concordia University\", \"Dalhousie University\", \"McGill University\", \"Queen's University\", \"Rotman at Toronto\", \"University of Alberta\", \"University of Calgary Law\", \"University of Calgary (Undergrad)\", \"University of Manitoba\", \"University of Saskatchewan\", \"University of Victoria\", \"University of Waterloo\", \"Western University\", \"Other\"], \"required\"=>true}, {\"name\"=>\"graduating_year\", \"type\"=>\"select\", \"title\"=>\"If you are still studying, in what year will you graduate? \", \"options\"=>[\"2022\", \"2023\", \"2024\", \"2025\", \"2026\"], \"required\"=>false}, {\"name\"=>\"givewell_comms\", \"type\"=>\"select\", \"title\"=>\"Share my name, contact info and donation info with the charities I support and with GiveWell, so that they can email me and track their donations better.\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_familiar\", \"type\"=>\"select\", \"title\"=>\"Were you familiar with GiveWell's recommended charities before you encountered One for the World?\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_amount\", \"type\"=>\"text\", \"title\"=>\"How much (if anything) are you currently giving per year to the GiveWell charities?\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"OFTW_discretion\", \"type\"=>\"checkbox\", \"title\"=>\"Like all regranting organizations, One for the World is legally required to retain final discretion over the destination of members’ donations. In practice, we faithfully follow our members' instructions to the fullest extent possible. Please tick here to acknowledge this and permit One for the World to redirect your donations in the future if our recommended charities change. We will contact you before any change to your donations' destination.*\", \"options\"=>[], \"required\"=>true}]}], [\"One For The World Australia\", {\"questions\"=>[{\"name\"=>\"phone_number\", \"type\"=>\"text\", \"title\"=>\"What is your phone number?\", \"options\"=>[], \"required\"=>true}, {\"name\"=>\"GDPR_static_text\", \"type\"=>\"statictext\", \"title\"=>\" One for the World would occasionally like to send you information about our charities, your impact and other initiatives. If you are happy to receive this information, please indicate here:\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_email\", \"type\"=>\"checkbox\", \"title\"=>\"By Email\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_phone\", \"type\"=>\"checkbox\", \"title\"=>\"By SMS (By selecting this box, you agree to receive donor engagement texts from One For The World. Message frequency varies. Message and data rates may apply. Reply STOP to unsubscribe at any time.)\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"chapter\", \"type\"=>\"select\", \"title\"=>\"What chapter are you associated with?\", \"options\"=>[\"N/A\", \"Australian National University\", \"Monash University\", \"Swinburne University of Technology\", \"University of Melbourne\", \"University of Queensland\", \"UTS\", \"Other\"], \"required\"=>true}, {\"name\"=>\"graduating_year\", \"type\"=>\"select\", \"title\"=>\"If you are still studying, in what year will you graduate? \", \"options\"=>[\"2022\", \"2023\", \"2024\", \"2025\", \"2026\", \"2027\", \"2028\"], \"required\"=>false}, {\"name\"=>\"givewell_comms\", \"type\"=>\"select\", \"title\"=>\"Share my name, contact info and donation info with the charities I support and with GiveWell, so that they can email me and track their donations better.\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_familiar\", \"type\"=>\"select\", \"title\"=>\"Were you familiar with GiveWell's recommended charities before you encountered One for the World?\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_amount\", \"type\"=>\"text\", \"title\"=>\"How much (if anything) are you currently giving per year to the GiveWell charities?\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"OFTW_discretion\", \"type\"=>\"checkbox\", \"title\"=>\"Like all regranting organisations, One for the World is legally required to retain final discretion over the destination of members’ donations. In practice, we faithfully follow our members' instructions to the fullest extent possible. Please tick here to acknowledge this and permit One for the World to redirect your donations in the future if our recommended charities change. We will contact you before any change to your donations' destination.*\", \"options\"=>[], \"required\"=>true}]}], [\"One For The World UK\", {\"questions\"=>[{\"name\"=>\"phone_number\", \"type\"=>\"text\", \"title\"=>\"What is your phone number?\", \"options\"=>[], \"required\"=>true}, {\"name\"=>\"GDPR_static_text\", \"type\"=>\"statictext\", \"title\"=>\" One for the World would occasionally like to send you information about our charities, your impact and other initiatives. If you are happy to receive this information, please indicate here:\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_email\", \"type\"=>\"checkbox\", \"title\"=>\"By Email\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_phone\", \"type\"=>\"checkbox\", \"title\"=>\"By SMS (By selecting this box, you agree to receive donor engagement texts from One For The World. Message frequency varies. Message and data rates may apply. Reply STOP to unsubscribe at any time.)\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"chapter\", \"type\"=>\"select\", \"title\"=>\"Are you associated with a One for the World chapter?\", \"options\"=>[\"N/A\", \"Durham University\", \"London School of Economics\", \"Manchester Metropolitan University (MBA)\", \"University of Cambridge\", \"University of Edinburgh\", \"University of Exeter\", \"University of Glasgow\", \"University of Manchester\", \"University of St Andrews\", \"Other\"], \"required\"=>true}, {\"name\"=>\"graduating_year\", \"type\"=>\"select\", \"title\"=>\"If you are still studying, in what year will you graduate? \", \"options\"=>[\"2022\", \"2023\", \"2024\", \"2025\", \"2026\"], \"required\"=>false}, {\"name\"=>\"givewell_comms\", \"type\"=>\"select\", \"title\"=>\"Share my name, contact info and donation info with the charities I support and with GiveWell, so that they can email me and track their donations better.\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_familiar\", \"type\"=>\"select\", \"title\"=>\"Were you familiar with GiveWell's recommended charities before you encountered One for the World?\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_amount\", \"type\"=>\"text\", \"title\"=>\"How much (if anything) are you currently giving per year to the GiveWell charities?\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"GiveWell_static_text\", \"type\"=>\"statictext\", \"title\"=>\"(GiveWell is one of the world's leading charity evaluators, and is also a primary funder of OFTW)\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"OFTW_discretion\", \"type\"=>\"checkbox\", \"title\"=>\"Like all regranting organisations, One for the World is legally required to retain final discretion over the destination of members’ donations. In practice, we faithfully follow our members' instructions to the fullest extent possible. Please tick here to acknowledge this and permit One for the World to redirect your donations in the future if our recommended charities change. We will contact you before any change to your donations' destination.*\", \"options\"=>[], \"required\"=>true}]}], [\"One For The World\", {\"questions\"=>[{\"name\"=>\"phone_number\", \"type\"=>\"text\", \"title\"=>\"What is your phone number?\", \"options\"=>[], \"required\"=>true}, {\"name\"=>\"GDPR_static_text\", \"type\"=>\"statictext\", \"title\"=>\" One for the World would occasionally like to send you information about our charities, your impact and other initiatives. If you are happy to receive this information, please indicate here:\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_email\", \"type\"=>\"checkbox\", \"title\"=>\"By Email\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"comms_phone\", \"type\"=>\"checkbox\", \"title\"=>\"By SMS (By selecting this box, you agree to receive donor engagement texts from One For The World. Message frequency varies. Message and data rates may apply. Reply STOP to unsubscribe at any time.)\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"chapter\", \"type\"=>\"select\", \"title\"=>\"Are you associated with a One for the World chapter?\", \"options\"=>[\"N/A\", \"Australian National University\", \"Brown University\", \"Bridgewater\", \"Brock University\", \"Cardozo Law School\", \"California Institute of Technology\", \"California State University - Los Angeles\", \"Columbia University\", \"Darden School of Business (UVA)\", \"Durham University\", \"Epic Systems\", \"George Washington University\", \"Harvard Business School\", \"Harvard Law School\", \"Kansas University Medical Center\", \"McGill University\", \"Ohio State University\", \"New England School of Law\", \"New York Law School\", \"Northeastern University\", \"Princeton University\", \"Queen's University\", \"Rotman (MBA)\", \"Seminole High School\", \"Stanford Graduate School of Business\", \"Stanford Law School\", \"Syracuse University\", \"Texas A&M University\", \"Thomas Jefferson University\", \"Tuck School of Business\", \"University of Calgary\", \"University of Cambridge\", \"University of Chicago Booth School of Business\", \"University of Cincinnati\", \"University of Miami\", \"University of Manchester\", \"University of Maryland\", \"University of Melbourne\", \"University of Michigan\", \"UNC Chapel Hill (Undergrad)\", \"UNC Kenan-Flagler (MBA)\", \"University of Nebraska Medical Center\", \"University of Pennsylvania (UG)\", \"University of Pennsylvania Wharton MBA\", \"University of St Andrews\", \"University of Texas Austin\", \"Vanderbilt University\", \"University of Virginia Law\", \"Virginia Commonwealth University\", \"Wake Forest University (MBA)\", \"Yale SOM (MBA)\", \"Other\"], \"required\"=>true}, {\"name\"=>\"graduating_year\", \"type\"=>\"select\", \"title\"=>\"If you are still studying, in what year will you graduate? \", \"options\"=>[\"2022\", \"2023\", \"2024\", \"2025\", \"2026\", \"2027\"], \"required\"=>false}, {\"name\"=>\"givewell_comms\", \"type\"=>\"select\", \"title\"=>\"Share my name, contact info and donation info with the charities I support and with GiveWell, so that they can email me and track their donations better.\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_familiar\", \"type\"=>\"select\", \"title\"=>\"Were you familiar with GiveWell's recommended nonprofits before you encountered One for the World?\", \"options\"=>[\"Yes\", \"No\"], \"required\"=>true}, {\"name\"=>\"givewell_amount\", \"type\"=>\"text\", \"title\"=>\"How much (if anything) are you currently giving per year to the GiveWell charities?\", \"options\"=>[], \"required\"=>false}, {\"name\"=>\"OFTW_discretion\", \"type\"=>\"checkbox\", \"title\"=>\"Like all regranting organizations, One for the World is legally required to retain final discretion over the destination of members’ donations. In practice, we faithfully follow our members' instructions to the fullest extent possible. Please tick here to acknowledge this and permit One for the World to redirect your donations in the future if our recommended charities change. We will contact you before any change to your donations' destination.*\", \"options\"=>[], \"required\"=>true}]}]]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment