├── .dockerignore
├── .gitignore
├── .gitmodules
├── .rubocop.yml
├── Gemfile
├── Gemfile.lock
├── LICENSE
├── README.md
├── Rakefile
├── app
├── assets
│ ├── attachments
│ │ └── HUMVLiabilityWaivers.pdf
│ ├── config
│ │ └── manifest.js
│ ├── images
│ │ ├── .keep
│ │ ├── dashboard-logo.png
│ │ ├── favicon.png
│ │ └── rubric.png
│ ├── javascripts
│ │ ├── application.js
│ │ ├── cable.js
│ │ ├── channels
│ │ │ └── .keep
│ │ ├── countdown.js
│ │ ├── custom_rsvp.coffee
│ │ ├── event_application.js
│ │ ├── event_attendance.coffee
│ │ ├── init.js
│ │ ├── judging.js
│ │ ├── mentorship_notifications.coffee
│ │ ├── paper_judging.coffee
│ │ ├── project.js
│ │ └── slackintegration.coffee
│ └── stylesheets
│ │ ├── application.scss
│ │ ├── custom_rsvp.scss
│ │ ├── devise.scss
│ │ ├── event_application.scss
│ │ ├── event_attendance.scss
│ │ ├── judging.scss
│ │ ├── mentorship_notifications.scss
│ │ ├── paper_judging.scss
│ │ ├── scaffolds.scss
│ │ └── slackintegration.scss
├── channels
│ └── application_cable
│ │ ├── channel.rb
│ │ └── connection.rb
├── controllers
│ ├── api
│ │ └── api_controller.rb
│ ├── application_controller.rb
│ ├── concerns
│ │ └── .keep
│ ├── custom_rsvps_controller.rb
│ ├── emails_controller.rb
│ ├── event_applications_controller.rb
│ ├── event_attendance_controller.rb
│ ├── events_controller.rb
│ ├── feature_flags_controller.rb
│ ├── hardware_checkouts_controller.rb
│ ├── hardware_items_controller.rb
│ ├── judging_controller.rb
│ ├── mentorship_notifications_controller.rb
│ ├── mentorship_requests_controller.rb
│ ├── pages_controller.rb
│ ├── paper_judging_controller.rb
│ ├── prizes_controller.rb
│ ├── projects_controller.rb
│ ├── registrations_controller.rb
│ ├── slackintegration_controller.rb
│ └── users_controller.rb
├── helpers
│ ├── application_helper.rb
│ ├── custom_rsvp_helper.rb
│ ├── devise_helper.rb
│ ├── event_applications_helper.rb
│ ├── event_attendance_helper.rb
│ ├── judging_helper.rb
│ ├── mentorship_notifications_helper.rb
│ ├── pages_helper.rb
│ ├── paper_judging_helper.rb
│ └── slackintegration_helper.rb
├── jobs
│ └── application_job.rb
├── mailers
│ ├── application_mailer.rb
│ └── user_mailer.rb
├── models
│ ├── application_record.rb
│ ├── concerns
│ │ └── .keep
│ ├── custom_rsvp.rb
│ ├── email.rb
│ ├── event.rb
│ ├── event_application.rb
│ ├── event_attendance.rb
│ ├── feature_flag.rb
│ ├── hardware_checkout.rb
│ ├── hardware_checkout_log.rb
│ ├── hardware_item.rb
│ ├── judgement.rb
│ ├── judging_assignment.rb
│ ├── major.rb
│ ├── mentorship_notification.rb
│ ├── mentorship_request.rb
│ ├── prize.rb
│ ├── project.rb
│ ├── university.rb
│ └── user.rb
└── views
│ ├── custom_rsvp
│ ├── _form.html.erb
│ └── show.html.erb
│ ├── devise
│ ├── confirmations
│ │ └── new.html.erb
│ ├── mailer
│ │ ├── confirmation_instructions.html.erb
│ │ ├── password_change.html.erb
│ │ ├── reset_password_instructions.html.erb
│ │ └── unlock_instructions.html.erb
│ ├── passwords
│ │ ├── edit.html.erb
│ │ └── new.html.erb
│ ├── registrations
│ │ ├── edit.html.erb
│ │ └── new.html.erb
│ ├── sessions
│ │ └── new.html.erb
│ ├── shared
│ │ └── _links.html.erb
│ └── unlocks
│ │ └── new.html.erb
│ ├── emails
│ ├── _form.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── new.html.erb
│ └── show.html.erb
│ ├── event_applications
│ ├── _form.html.erb
│ ├── application_mode.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── new.html.erb
│ ├── search.html.erb
│ └── show.html.erb
│ ├── events
│ ├── _event.html.erb
│ ├── _event.json.jbuilder
│ ├── _form.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── index.json.jbuilder
│ ├── new.html.erb
│ └── show.html.erb
│ ├── feature_flags
│ ├── _feature_flag.erb
│ └── index.html.erb
│ ├── hardware_items
│ ├── _barcode.html.erb
│ ├── _checked_out_items.html.erb
│ ├── _checkout.html.erb
│ ├── _checkout_log.html.erb
│ ├── _form.html.erb
│ ├── _hardware_item.json.jbuilder
│ ├── all_checked_out.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── index.json.jbuilder
│ ├── new.html.erb
│ ├── search.html.erb
│ └── show.html.erb
│ ├── judging
│ ├── _all_projects.html.erb
│ ├── _assigned_projects.html.erb
│ ├── _judged_projects.html.erb
│ ├── _judging_fields.erb
│ ├── _score.html.erb
│ ├── assign.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── mass_assign.html.erb
│ ├── new.html.erb
│ ├── results.html.erb
│ ├── show.html.erb
│ └── tag_assign.html.erb
│ ├── layouts
│ ├── application.html.erb
│ ├── mailer.html.erb
│ └── mailer.text.erb
│ ├── mentorship_notifications
│ ├── _form.html.erb
│ ├── _mentorship_notification.json.jbuilder
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── index.json.jbuilder
│ ├── new.html.erb
│ ├── show.html.erb
│ └── show.json.jbuilder
│ ├── mentorship_requests
│ ├── _attendee_view.html.erb
│ ├── _form.html.erb
│ ├── _mentor_view.html.erb
│ ├── _tech_form_options.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── new.html.erb
│ ├── search.html.erb
│ └── show.html.erb
│ ├── pages
│ ├── admin.html.erb
│ ├── check_in.html.erb
│ ├── index.html.erb
│ ├── join_slack.html.erb
│ ├── permissions.html.erb
│ └── redeem_code.html.erb
│ ├── paper_judging
│ └── index.html.erb
│ ├── partial
│ ├── _hackathonfooter.html.erb
│ └── _hackathonlogo.html.erb
│ ├── prizes
│ ├── _form.html.erb
│ ├── assign.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── new.html.erb
│ └── show.html.erb
│ ├── projects
│ ├── _form.html.erb
│ ├── _public_navigation.html.erb
│ ├── _public_project.html.erb
│ ├── edit.html.erb
│ ├── index.html.erb
│ ├── new.html.erb
│ ├── project_submit_info.html.erb
│ ├── public.html.erb
│ ├── search.html.erb
│ ├── show.html.erb
│ └── team.html.erb
│ ├── shared
│ ├── _footer.html.erb
│ ├── _navigation.html.erb
│ ├── _organizer_view.html.erb
│ ├── _permissions.html.erb
│ ├── _users.html.erb
│ └── home_pages
│ │ ├── _accepted_view.html.erb
│ │ ├── _admin_view.html.erb
│ │ ├── _checked_in_view.html.erb
│ │ ├── _denied_view.html.erb
│ │ ├── _mentor_view.html.erb
│ │ ├── _new_user_view.html.erb
│ │ ├── _organizer_view.html.erb
│ │ ├── _rsvp_view.html.erb
│ │ ├── _undecided_view.html.erb
│ │ └── _waitlisted_view.html.erb
│ ├── slackintegration
│ └── admin.html.erb
│ └── user_mailer
│ ├── accepted_email.html.erb
│ ├── accepted_email.text.erb
│ ├── denied_email.html.erb
│ ├── denied_email.text.erb
│ ├── reminder_email.html.erb
│ ├── reminder_email.text.erb
│ ├── submit_email.html.erb
│ ├── submit_email.text.erb
│ ├── template_email.html.erb
│ ├── template_email.txt.erb
│ ├── waitlisted_email.html.erb
│ ├── waitlisted_email.text.erb
│ ├── welcome_email.html.erb
│ └── welcome_email.text.erb
├── bin
├── bundle
├── rails
├── rake
├── setup
├── spring
└── update
├── config.ru
├── config
├── application.rb
├── boot.rb
├── cable.yml
├── database.yml
├── environment.rb
├── environments
│ ├── development.rb
│ ├── production.rb
│ └── test.rb
├── initializers
│ ├── arel.rb
│ ├── assets.rb
│ ├── cookies_serializer.rb
│ ├── devise.rb
│ ├── devise_token_auth.rb
│ ├── filter_parameter_logging.rb
│ ├── formats_filter.rb
│ ├── new_framework_defaults.rb
│ ├── ransack.rb
│ ├── recaptcha.rb
│ ├── session_store.rb
│ └── wrap_parameters.rb
├── locales
│ ├── devise.en.yml
│ └── en.yml
├── puma.rb
├── routes.rb
├── secrets.yml
└── spring.rb
├── db
├── application_autocomplete
│ ├── .~lock.colleges.csv#
│ ├── colleges.csv
│ └── majors-list.csv
├── migrate
│ ├── 20170415164547_devise_create_users.rb
│ ├── 20170416004110_create_event_applications.rb
│ ├── 20170424014343_create_hardware_items.rb
│ ├── 20170425211535_add_type_to_user.rb
│ ├── 20170427165952_create_hardware_checkouts.rb
│ ├── 20170512164743_remove_item_upc_from_hardware_checkouts.rb
│ ├── 20170512171123_add_references_to_hardware_checkouts.rb
│ ├── 20170521042440_add_missing_variable_to_event_applications.rb
│ ├── 20170522053550_add_other_text_field_option_to_event_applications.rb
│ ├── 20170524233707_create_mentorship_requests.rb
│ ├── 20170525164515_add_type_to_mentorship_requests.rb
│ ├── 20170531224502_add_urgency_to_mentorship_requests.rb
│ ├── 20170609212338_renaming_reordering_removing_event_application_variables.rb
│ ├── 20170614024614_numbers.rb
│ ├── 20170614025022_number2.rb
│ ├── 20170701032201_remove_programmer_type.rb
│ ├── 20170701032834_remove_default_value_in_boolean_value.rb
│ ├── 20170709180501_create_events.rb
│ ├── 20170714015410_create_universities.rb
│ ├── 20170714015601_create_majors.rb
│ ├── 20170719225344_hardware_skills.rb
│ ├── 20170722060404_add_flag_to_event_applications.rb
│ ├── 20170823144753_remove_thumbnail.rb
│ ├── 20170903192617_change_events_time.rb
│ ├── 20171014030325_add_rsvp_to_event_applications.rb
│ ├── 20171029034814_add_check_in_to_event_applications.rb
│ ├── 20171030002802_create_emails.rb
│ ├── 20180711001332_add_resume_file_size_to_event_applications.rb
│ ├── 20180728205939_create_active_storage_tables.active_storage.rb
│ ├── 20180729035032_remove_old_variables_from_event_application.rb
│ ├── 20180804035430_clean_up_event_application_table.rb
│ ├── 20180804185413_drop_active_storage.rb
│ ├── 20180807223040_create_feature_flags.rb
│ ├── 20180808024842_create_projects.rb
│ ├── 20180811040748_update_event_application_table.rb
│ ├── 20180818171735_add_user_graduation_year_to_event_application.rb
│ ├── 20180905015844_add_user_to_project.rb
│ ├── 20180909180945_add_rsv_pand_check_in_to_user.rb
│ ├── 20180909190233_create_prizes.rb
│ ├── 20180909211902_add_paperclip_to_projects.rb
│ ├── 20180928153649_change_events_fields.rb
│ ├── 20180929224811_add_tech_to_mentorship_requests.rb
│ ├── 20180930015740_add_attachment_screenshot_to_mentorship_requests.rb
│ ├── 20181004212657_add_new_fields_to_projects.rb
│ ├── 20181005154209_add_prize_field_to_projects.rb
│ ├── 20181011053411_edit_project_fields.rb
│ ├── 20181011233048_add_power_tableid_to_projects.rb
│ ├── 20190721155954_add_display_name_to_feature_flags.rb
│ ├── 20190721160412_add_description_to_feature_flags.rb
│ ├── 20190726233422_add_mlh_agreement_to_event_applications.rb
│ ├── 20190818212050_add_gender_pronoun_to_event_applications.rb
│ ├── 20190818212123_add_pronoun_to_event_applications.rb
│ ├── 20190818212159_remove_sex_from_event_applications.rb
│ ├── 20190818213423_add_custom_fields_to_event_applications.rb
│ ├── 20190818222059_update_custom_fields_for_event_applications.rb
│ ├── 20190819205021_modify_default_value_for_custom_fields_in_event_applications.rb
│ ├── 20190820044737_delete_unneeded_fields_in_event_applications.rb
│ ├── 20190908192614_add_project_id_to_users.rb
│ ├── 20190909193239_remove_team_members_from_projects.rb
│ ├── 20190909193614_remove_user_id_from_projects.rb
│ ├── 20190915231752_create_custom_rsvp.rb
│ ├── 20191003044524_create_event_attendances.rb
│ ├── 20191003045039_add_max_seats_to_event.rb
│ ├── 20191003045056_add_rsvpable_to_event.rb
│ ├── 20191003051058_add_event_id_to_event_attendance.rb
│ ├── 20191003051120_add_user_id_to_event_attendance.rb
│ ├── 20191003200336_add_slack_to_user.rb
│ ├── 20191003222330_remove_slack_from_user.rb
│ ├── 20191004004936_delete_slack_username_from_user.rb
│ ├── 20191010222403_add_checked_in_to_event_attendance.rb
│ ├── 20191013175841_add_youtube_link_to_projects.rb
│ ├── 20191013190410_add_tech_to_projects.rb
│ ├── 20191013192723_update_tech_in_projects.rb
│ ├── 20191013193206_update_tech_default_in_projects.rb
│ ├── 20191013200730_add_prizes_won_to_projects.rb
│ ├── 20191013201513_add_project_selectable_to_prizes.rb
│ ├── 20191013203003_update_prizes_in_projects.rb
│ ├── 20191013204218_update_prizes_array_in_projects.rb
│ ├── 20191013204303_update_prizes_won_array_in_projects.rb
│ ├── 20191014004914_create_hardware_checkout_logs.rb
│ ├── 20191014005345_add_message_to_hardware_checkout_logs.rb
│ ├── 20191017194803_fix_defaults.rb
│ ├── 20191018035814_create_mentorship_notifications.rb
│ ├── 20200109051747_add_location_to_hardware_items.rb
│ ├── 20200112194204_create_judgements.rb
│ ├── 20200112194527_add_score_to_judgement.rb
│ ├── 20200112203807_add_user_id_to_judgements.rb
│ ├── 20200112204046_add_project_id_to_judgements.rb
│ ├── 20200112210254_set_default_score.rb
│ ├── 20200117234839_create_judging_assignments.rb
│ ├── 20200121200442_update_judge_assignment_primary_key.rb
│ ├── 20200126000717_add_custom_scores_to_judgements.rb
│ ├── 20200126192626_add_tag_to_judging_assignments.rb
│ ├── 20200126193225_add_tag_to_judgements.rb
│ ├── 20200126201720_update_assignment_index.rb
│ ├── 20200128031347_update_custom_scores_to_judgements.rb
│ ├── 20200206212235_devise_token_auth_edit_users.rb
│ ├── 20200618042555_add_confirmable_to_devise.rb
│ ├── 20221013150340_add_mlh_communications_to_event_applications.rb
│ ├── 20221102014907_change_upc_to_uid.rb
│ ├── 20221109013144_change_uid_to_string_in_hardware_items.rb
│ ├── 20231002032542_rename_prize_model_fields.rb
│ ├── 20231008213425_add_consent_to_marketing_emails_to_users.rb
│ ├── 20231008224238_rename_email_marketing_consent_to_match_naming_convention.rb
│ └── 20231009025205_rename_email_marketing_consent_to_non_transactional_email_consent.rb
├── schema.rb
└── seeds.rb
├── deploy.sh
├── docker-compose.yml
├── docker
├── Dockerfile
├── docker_run.sh
└── docker_set_up.sh
├── docker_shell.sh
├── download_resumes.py
├── lib
├── assets
│ └── .keep
└── tasks
│ ├── .keep
│ ├── admissions.rake
│ ├── autocomplete.rake
│ ├── csv.rake
│ ├── db_clean.rake
│ ├── feature_flags.rake
│ ├── hardware_data.csv
│ ├── load_events.rake
│ ├── load_hardware.rake
│ ├── reminder.rake
│ ├── sample_events_data.csv
│ ├── sample_hardware_data.csv
│ └── template_email.rake
├── log
└── .keep
├── output.csv
├── public
├── 404.html.erb
├── 422.html.erb
├── 500.html.erb
├── apple-touch-icon-precomposed.png
├── apple-touch-icon.png
├── favicon.ico
├── judging
│ └── judging.pdf
└── robots.txt
├── resume_urls.csv
├── test
├── controllers
│ ├── .keep
│ ├── custom_rsvp_controller_test.rb
│ ├── emails_controller_test.rb
│ ├── event_applications_controller_test.rb
│ ├── event_attendance_controller_test.rb
│ ├── events_controller_test.rb
│ ├── hardware_checkouts_controller_test.rb
│ ├── hardware_items_controller_test.rb
│ ├── judging_controller_test.rb
│ ├── mentorship_notifications_controller_test.rb
│ ├── mentorship_requests_controller_test.rb
│ ├── navigation_controller_test.rb
│ ├── paper_judging_controller_test.rb
│ ├── prizes_controller_test.rb
│ └── slackintegration_controller_test.rb
├── fixtures
│ ├── .keep
│ ├── custom_rsvps.yml
│ ├── emails.yml
│ ├── event_applications.yml
│ ├── event_attendances.yml
│ ├── events.yml
│ ├── files
│ │ └── .keep
│ ├── hardware_checkout_logs.yml
│ ├── hardware_checkouts.yml
│ ├── hardware_items.yml
│ ├── judgements.yml
│ ├── judging_assignments.yml
│ ├── majors.yml
│ ├── mentorship_notifications.yml
│ ├── mentorship_requests.yml
│ ├── prizes.yml
│ ├── universities.yml
│ └── users.yml
├── helpers
│ └── .keep
├── integration
│ └── .keep
├── mailers
│ ├── .keep
│ ├── previews
│ │ └── user_mailer_preview.rb
│ └── user_mailer_test.rb
├── models
│ ├── .keep
│ ├── custom_rsvp_test.rb
│ ├── email_test.rb
│ ├── event_application_test.rb
│ ├── event_attendance_test.rb
│ ├── event_test.rb
│ ├── hardware_checkout_log_test.rb
│ ├── hardware_checkout_test.rb
│ ├── hardware_item_test.rb
│ ├── judgement_test.rb
│ ├── judging_assignment_test.rb
│ ├── major_test.rb
│ ├── mentorship_notification_test.rb
│ ├── mentorship_request_test.rb
│ ├── prize_test.rb
│ ├── university_test.rb
│ └── user_test.rb
├── system
│ ├── mentorship_notifications_test.rb
│ └── prizes_test.rb
└── test_helper.rb
├── tmp
└── .keep
└── vendor
└── assets
├── javascripts
├── .keep
└── highcharts.js
└── stylesheets
└── .keep
/.dockerignore:
--------------------------------------------------------------------------------
1 | # Files to ignore when building the docker container
2 |
3 | # Ignores Git files
4 | .git
5 | .gitignore
6 | README.md
7 |
8 | # Ignore the docker-compose postgres volume
9 | /db/postgres
10 |
11 | # Ignore all logfiles and tempfiles.
12 | /log/*
13 | /tmp/*
14 | !/log/.keep
15 | !/tmp/.keep
16 |
17 | #
18 | # OS X
19 | #
20 | .DS_Store
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files for more about ignoring files.
2 | #
3 | # If you find yourself ignoring temporary files generated by your text editor
4 | # or operating system, you probably want to add a global ignore instead:
5 | # git config --global core.excludesfile '~/.gitignore_global'
6 |
7 | # Ignore bundler config.
8 | /.bundle
9 |
10 | # Ignore docker Postgres files
11 | /db/postgres/
12 |
13 | # Ignore all logfiles and tempfiles.
14 | /log/*
15 | /tmp/*
16 | !/log/.keep
17 | !/tmp/.keep
18 |
19 | # Ignore Byebug command history file.
20 | .byebug_history
21 |
22 | # Ignore text editor and workspace preferences files
23 | .vscode
24 | .idea
25 |
26 | *.code-workspace
27 | # Ignore macOS .DS_Store files
28 | .DS_Store
29 |
30 | # Ignore secrets file
31 | config/secrets.yml
32 |
33 | public/assets/**
34 | public/assets/.sprocket*
35 | .gitmodules
36 |
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
1 | [submodule "hackathon-config"]
2 | path = hackathon-config
3 | url = https://github.com/ammuiyer/HackUMass-XI-Config
4 |
--------------------------------------------------------------------------------
/.rubocop.yml:
--------------------------------------------------------------------------------
1 | Metrics/LineLength:
2 | Max: 100
--------------------------------------------------------------------------------
/Rakefile:
--------------------------------------------------------------------------------
1 | # Add your own tasks in files placed in lib/tasks ending in .rake,
2 | # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
3 |
4 | require_relative 'config/application'
5 |
6 | Rails.application.load_tasks
7 |
--------------------------------------------------------------------------------
/app/assets/attachments/HUMVLiabilityWaivers.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/assets/attachments/HUMVLiabilityWaivers.pdf
--------------------------------------------------------------------------------
/app/assets/config/manifest.js:
--------------------------------------------------------------------------------
1 | //= link_tree ../images
2 | //= link_directory ../javascripts .js
3 | //= link_directory ../stylesheets .css
4 |
--------------------------------------------------------------------------------
/app/assets/images/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/assets/images/.keep
--------------------------------------------------------------------------------
/app/assets/images/dashboard-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/assets/images/dashboard-logo.png
--------------------------------------------------------------------------------
/app/assets/images/favicon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/assets/images/favicon.png
--------------------------------------------------------------------------------
/app/assets/images/rubric.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/assets/images/rubric.png
--------------------------------------------------------------------------------
/app/assets/javascripts/application.js:
--------------------------------------------------------------------------------
1 | // This is a manifest file that'll be compiled into application.js, which will include all the files
2 | // listed below.
3 | //
4 | // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5 | // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6 | //
7 | // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8 | // compiled file. JavaScript code in this file should be added after the last require_* statement.
9 | //
10 | // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11 | // about supported directives.
12 | //
13 | //= require tabler
14 | //= require tabler.plugins
15 | //= require Chart.bundle
16 | //= require chartkick
17 | //= require highcharts
18 | //= require jquery
19 | //= require countdown
20 | //= require jquery_ujs
21 | //= require jquery-ui
22 | //= require autocomplete-rails
23 | //= require turbolinks
24 | //= require cable
25 | //= require event_application
26 | //= require judging
27 | //= require_tree .
28 |
--------------------------------------------------------------------------------
/app/assets/javascripts/cable.js:
--------------------------------------------------------------------------------
1 | // Action Cable provides the framework to deal with WebSockets in Rails.
2 | // You can generate new channels where WebSocket features live using the rails generate channel command.
3 | //
4 | //= require action_cable
5 | //= require_self
6 | //= require_tree ./channels
7 |
8 | (function() {
9 | this.App || (this.App = {});
10 |
11 | App.cable = ActionCable.createConsumer();
12 |
13 | }).call(this);
14 |
--------------------------------------------------------------------------------
/app/assets/javascripts/channels/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/assets/javascripts/channels/.keep
--------------------------------------------------------------------------------
/app/assets/javascripts/custom_rsvp.coffee:
--------------------------------------------------------------------------------
1 | # Place all the behaviors and hooks related to the matching controller here.
2 | # All this logic will automatically be available in application.js.
3 | # You can use CoffeeScript in this file: http://coffeescript.org/
4 |
--------------------------------------------------------------------------------
/app/assets/javascripts/event_attendance.coffee:
--------------------------------------------------------------------------------
1 | # Place all the behaviors and hooks related to the matching controller here.
2 | # All this logic will automatically be available in application.js.
3 | # You can use CoffeeScript in this file: http://coffeescript.org/
4 |
--------------------------------------------------------------------------------
/app/assets/javascripts/init.js:
--------------------------------------------------------------------------------
1 | /* code source: https://www.driftingruby.com/episodes/page-specific-javascript-in-ruby-on-rails */
2 |
3 | var Page, bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
4 | Page = (function() {
5 | function Page() {
6 | this.action = bind(this.action, this);
7 | this.controller = bind(this.controller, this);
8 | }
9 | Page.prototype.controller = function() {
10 | return $('meta[name=page_specific]').attr('controller');
11 | };
12 | Page.prototype.action = function() {
13 | return $('meta[name=page_specific]').attr('action');
14 | };
15 | return Page;
16 | })();
17 |
18 | this.page = new Page;
--------------------------------------------------------------------------------
/app/assets/javascripts/mentorship_notifications.coffee:
--------------------------------------------------------------------------------
1 | # Place all the behaviors and hooks related to the matching controller here.
2 | # All this logic will automatically be available in application.js.
3 | # You can use CoffeeScript in this file: http://coffeescript.org/
4 |
--------------------------------------------------------------------------------
/app/assets/javascripts/paper_judging.coffee:
--------------------------------------------------------------------------------
1 | # Place all the behaviors and hooks related to the matching controller here.
2 | # All this logic will automatically be available in application.js.
3 | # You can use CoffeeScript in this file: http://coffeescript.org/
4 |
--------------------------------------------------------------------------------
/app/assets/javascripts/project.js:
--------------------------------------------------------------------------------
1 | $(document).on('turbolinks:load', function () {
2 | if (!(page.controller() === 'event_applications' && page.action() === 'new' || page.action() === 'edit')) {
3 | return;
4 | }
5 | });
6 |
7 |
8 | $(document).on('ready', function () {
9 | if (!(page.controller() === 'event_applications' && page.action() === 'create' || page.action() === 'update')) {
10 | return;
11 | }
12 | });
13 |
14 |
15 | function updateProjectImageFileLabel() {
16 | var fileLabel = document.getElementsByClassName('custom-file-label')[0];
17 | var resumeFileField = document.getElementById('project_projectimage');
18 | if(resumeFileField) {
19 | var pathArray = resumeFileField.value.split('\\');
20 | var fileName = pathArray[pathArray.length-1];
21 | fileLabel.innerHTML = fileName;
22 | }
23 | }
24 |
25 | function updateRequestImageFileLabel() {
26 | var fileLabel = document.getElementsByClassName('custom-file-label')[0];
27 | var resumeFileField = document.getElementById('request_requestimage');
28 | if(resumeFileField) {
29 | var pathArray = resumeFileField.value.split('\\');
30 | var fileName = pathArray[pathArray.length-1];
31 | fileLabel.innerHTML = fileName;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/app/assets/javascripts/slackintegration.coffee:
--------------------------------------------------------------------------------
1 | # Place all the behaviors and hooks related to the matching controller here.
2 | # All this logic will automatically be available in application.js.
3 | # You can use CoffeeScript in this file: http://coffeescript.org/
4 |
--------------------------------------------------------------------------------
/app/assets/stylesheets/custom_rsvp.scss:
--------------------------------------------------------------------------------
1 | // Place all the styles related to the CustomRSVP controller here.
2 | // They will automatically be included in application.css.
3 | // You can use Sass (SCSS) here: http://sass-lang.com/
4 |
--------------------------------------------------------------------------------
/app/assets/stylesheets/devise.scss:
--------------------------------------------------------------------------------
1 | .devise-error-card-margin-top {
2 | margin-top: 20px;
3 | }
4 |
5 | .devise-error-card-padding {
6 | padding: 20px 0px;
7 | }
--------------------------------------------------------------------------------
/app/assets/stylesheets/event_attendance.scss:
--------------------------------------------------------------------------------
1 | // Place all the styles related to the EventAttendance controller here.
2 | // They will automatically be included in application.css.
3 | // You can use Sass (SCSS) here: http://sass-lang.com/
4 |
--------------------------------------------------------------------------------
/app/assets/stylesheets/judging.scss:
--------------------------------------------------------------------------------
1 | // Place all the styles related to the judging controller here.
2 | // They will automatically be included in application.css.
3 | // You can use Sass (SCSS) here: http://sass-lang.com/
4 |
5 |
6 | .card-input-element + .judge_button {
7 | color: var(--primary);
8 | box-shadow: none;
9 | border: 2px solid transparent;
10 | border-radius: 4px;
11 | }
12 |
13 | .card-input-element + .judge_button:hover {
14 | cursor: pointer;
15 | }
16 |
17 | .card-input-element:checked + .judge_button {
18 | border: 2px solid var(--primary);
19 | transition: border .3s;
20 | }
21 |
22 | // Judging form
23 | .judge_button_style {
24 | min-width: 160px;
25 | }
26 |
27 | // Pop up for project description
28 | .modal {
29 | display: none; /* Hidden by default */
30 | position: fixed; /* Stay in place */
31 | z-index: 1; /* Sit on top */
32 | left: 0;
33 | top: 0;
34 | width: 100%; /* Full width */
35 | height: 100%; /* Full height */
36 | overflow: auto; /* Enable scroll if needed */
37 | background-color: rgb(0,0,0); /* Fallback color */
38 | background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
39 | }
40 |
41 | .modal-content {
42 | background-color: #fefefe;
43 | margin: 15% auto; /* 15% from the top and centered */
44 | padding: 20px;
45 | border: 1px solid #888;
46 | width: 80%; /* Could be more or less, depending on screen size */
47 | }
48 |
49 |
50 | .main-row-header {
51 | display: flex;
52 | }
53 | .card-header-padding {
54 | padding-top: 9px;
55 | }
--------------------------------------------------------------------------------
/app/assets/stylesheets/mentorship_notifications.scss:
--------------------------------------------------------------------------------
1 | // Place all the styles related to the MentorshipNotifications controller here.
2 | // They will automatically be included in application.css.
3 | // You can use Sass (SCSS) here: http://sass-lang.com/
4 |
--------------------------------------------------------------------------------
/app/assets/stylesheets/paper_judging.scss:
--------------------------------------------------------------------------------
1 | // Place all the styles related to the PaperJudging controller here.
2 | // They will automatically be included in application.css.
3 | // You can use Sass (SCSS) here: http://sass-lang.com/
4 |
--------------------------------------------------------------------------------
/app/assets/stylesheets/scaffolds.scss:
--------------------------------------------------------------------------------
1 | body {
2 | background-color: #fff;
3 | color: #333;
4 | margin: 33px;
5 | font-family: verdana, arial, helvetica, sans-serif;
6 | font-size: 13px;
7 | line-height: 18px;
8 | }
9 |
10 | p, ol, ul, td {
11 | font-family: verdana, arial, helvetica, sans-serif;
12 | font-size: 13px;
13 | line-height: 18px;
14 | }
15 |
16 | pre {
17 | background-color: #eee;
18 | padding: 10px;
19 | font-size: 11px;
20 | }
21 |
22 | a {
23 | color: #000;
24 |
25 | &:visited {
26 | color: #666;
27 | }
28 |
29 | &:hover {
30 | color: #fff;
31 | background-color: #000;
32 | }
33 | }
34 |
35 | th {
36 | padding-bottom: 5px;
37 | }
38 |
39 | td {
40 | padding: 0 5px 7px;
41 | }
42 |
43 | div {
44 | &.field, &.actions {
45 | margin-bottom: 10px;
46 | }
47 | }
48 |
49 | #notice {
50 | color: green;
51 | }
52 |
53 | .field_with_errors {
54 | padding: 2px;
55 | background-color: red;
56 | display: table;
57 | }
58 |
59 | #error_explanation {
60 | width: 450px;
61 | border: 2px solid red;
62 | padding: 7px 7px 0;
63 | margin-bottom: 20px;
64 | background-color: #f0f0f0;
65 |
66 | h2 {
67 | text-align: left;
68 | font-weight: bold;
69 | padding: 5px 5px 5px 15px;
70 | font-size: 12px;
71 | margin: -7px -7px 0;
72 | background-color: #c00;
73 | color: #fff;
74 | }
75 |
76 | ul li {
77 | font-size: 12px;
78 | list-style: square;
79 | }
80 | }
81 |
82 | label {
83 | display: block;
84 | }
85 |
--------------------------------------------------------------------------------
/app/assets/stylesheets/slackintegration.scss:
--------------------------------------------------------------------------------
1 | // Place all the styles related to the slackintegration controller here.
2 | // They will automatically be included in application.css.
3 | // You can use Sass (SCSS) here: http://sass-lang.com/
4 |
--------------------------------------------------------------------------------
/app/channels/application_cable/channel.rb:
--------------------------------------------------------------------------------
1 | module ApplicationCable
2 | class Channel < ActionCable::Channel::Base
3 | end
4 | end
5 |
--------------------------------------------------------------------------------
/app/channels/application_cable/connection.rb:
--------------------------------------------------------------------------------
1 | module ApplicationCable
2 | class Connection < ActionCable::Connection::Base
3 | end
4 | end
5 |
--------------------------------------------------------------------------------
/app/controllers/api/api_controller.rb:
--------------------------------------------------------------------------------
1 | module Api
2 | class Api::ApiController < ApplicationController
3 | include DeviseTokenAuth::Concerns::SetUserByToken
4 |
5 | skip_before_action :auth_user
6 | before_action :configure_permitted_parameters, if: :devise_controller?
7 |
8 | def configure_permitted_parameters
9 | devise_parameter_sanitizer.permit(:sign_in, keys: [:email, :password])
10 | end
11 |
12 | def index
13 | render json: {}
14 | end
15 | end
16 | end
17 |
--------------------------------------------------------------------------------
/app/controllers/concerns/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/controllers/concerns/.keep
--------------------------------------------------------------------------------
/app/controllers/event_attendance_controller.rb:
--------------------------------------------------------------------------------
1 | class EventAttendanceController < ApplicationController
2 | def create
3 | EventAttendance.new()
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/app/controllers/registrations_controller.rb:
--------------------------------------------------------------------------------
1 | class RegistrationsController < Devise::RegistrationsController
2 | def create
3 | if verify_recaptcha
4 | super
5 | else
6 | build_resource(sign_up_params)
7 | clean_up_passwords(resource)
8 | flash.now[:alert] = "There was an error with the recaptcha code below. Please re-enter the code."
9 | flash.delete :recaptcha_error
10 | render :new
11 | end
12 | end
13 | end
--------------------------------------------------------------------------------
/app/controllers/users_controller.rb:
--------------------------------------------------------------------------------
1 | class UsersController < ApplicationController
2 | before_action :authenticate_user!
3 |
4 | def go_to_forgot
5 | current_user.send_reset_password_instructions
6 | sign_out current_user
7 | flash[:notice] = "Send an email to you"
8 | redirect_to index_path
9 | end
10 | end
--------------------------------------------------------------------------------
/app/helpers/application_helper.rb:
--------------------------------------------------------------------------------
1 | module ApplicationHelper
2 | # Called when deciding colors for alert badge
3 | def bootstrap_class_for(flash_type)
4 | case flash_type
5 | when 'success', 'notice'
6 | 'alert-success' # Green
7 | when 'error', 'alert'
8 | 'alert-danger' # Red
9 | when 'warning'
10 | 'alert-warning' # Yellow
11 | else
12 | flash_type.to_s
13 | end
14 | end
15 |
16 | end
17 |
--------------------------------------------------------------------------------
/app/helpers/custom_rsvp_helper.rb:
--------------------------------------------------------------------------------
1 | module CustomRsvpHelper
2 | end
3 |
--------------------------------------------------------------------------------
/app/helpers/devise_helper.rb:
--------------------------------------------------------------------------------
1 | module DeviseHelper
2 | def devise_error_messages!
3 | return "" unless devise_error_messages?
4 |
5 | messages = resource.errors.full_messages.map { |msg| content_tag(:li, msg.downcase.capitalize) }.join
6 | sentence = I18n.t("errors.messages.not_saved",
7 | :count => resource.errors.count,
8 | :resource => resource.class.model_name.human.downcase)
9 |
10 | html = <<-HTML
11 |
20 | HTML
21 |
22 | html.html_safe
23 | end
24 |
25 | def devise_error_messages?
26 | !resource.errors.empty?
27 | end
28 |
29 | end
30 |
31 |
--------------------------------------------------------------------------------
/app/helpers/event_applications_helper.rb:
--------------------------------------------------------------------------------
1 | module EventApplicationsHelper
2 |
3 | def denied_is_active?(params)
4 | params[:status].present? && params[:status] == 'denied'
5 | end
6 |
7 | def waitlisted_is_active?(params)
8 | params[:status].present? && params[:status] == 'waitlisted'
9 | end
10 |
11 | def accepted_is_active?(params)
12 | params[:status].present? && params[:status] == 'accepted'
13 | end
14 |
15 | def undecided_is_active?(params)
16 | params[:status].present? && params[:status] == 'undecided'
17 | end
18 |
19 | def rsvp_is_active?(params)
20 | params[:rsvp].present?
21 | end
22 |
23 | def flagged_is_active?(params)
24 | params[:flagged].present?
25 | end
26 |
27 | def rsvp_is_active?(params)
28 | params[:rsvp].present?
29 | end
30 |
31 | def all_is_active?(params)
32 | !(params[:status].present? || params[:flagged].present?)
33 | end
34 |
35 | def editing_application?
36 | params[:action] == 'edit'
37 | end
38 |
39 | def admin_or_organizer?
40 | current_user.user_type == 'admin' || current_user.user_type == 'organizer'
41 | end
42 |
43 | def admin?
44 | current_user.user_type == 'admin'
45 | end
46 |
47 |
48 | def lack_permission_msg
49 | 'Sorry, but you seem to lack the permission to go to that part of the website.'
50 | end
51 | end
--------------------------------------------------------------------------------
/app/helpers/event_attendance_helper.rb:
--------------------------------------------------------------------------------
1 | module EventAttendanceHelper
2 | end
3 |
--------------------------------------------------------------------------------
/app/helpers/judging_helper.rb:
--------------------------------------------------------------------------------
1 | module JudgingHelper
2 | end
3 |
--------------------------------------------------------------------------------
/app/helpers/mentorship_notifications_helper.rb:
--------------------------------------------------------------------------------
1 | module MentorshipNotificationsHelper
2 | end
3 |
--------------------------------------------------------------------------------
/app/helpers/paper_judging_helper.rb:
--------------------------------------------------------------------------------
1 | module PaperJudgingHelper
2 | end
3 |
--------------------------------------------------------------------------------
/app/helpers/slackintegration_helper.rb:
--------------------------------------------------------------------------------
1 | module SlackintegrationHelper
2 | end
3 |
--------------------------------------------------------------------------------
/app/jobs/application_job.rb:
--------------------------------------------------------------------------------
1 | class ApplicationJob < ActiveJob::Base
2 | end
3 |
--------------------------------------------------------------------------------
/app/mailers/application_mailer.rb:
--------------------------------------------------------------------------------
1 | class ApplicationMailer < ActionMailer::Base
2 | default from: "#{HackumassWeb::Application::CONTACT_EMAIL}"
3 | layout 'mailer'
4 | end
5 |
--------------------------------------------------------------------------------
/app/mailers/user_mailer.rb:
--------------------------------------------------------------------------------
1 | class UserMailer < ApplicationMailer
2 |
3 | default from: "#{HackumassWeb::Application::CONTACT_EMAIL}"
4 |
5 | def welcome_email(user)
6 | @user = user;
7 | mail(to: @user.email, subject: "Thank you for signing up for #{HackumassWeb::Application::HACKATHON_NAME} #{HackumassWeb::Application::HACKATHON_VERSION}!")
8 | end
9 |
10 | def submit_email(user)
11 | @user = user;
12 | mail(to: @user.email, subject: "Thank you for submitting your #{HackumassWeb::Application::HACKATHON_NAME} #{HackumassWeb::Application::HACKATHON_VERSION} application!")
13 | end
14 |
15 | def accepted_email(user)
16 | @user = user;
17 | mail(to: @user.email, subject: "Congratulations! Welcome to #{HackumassWeb::Application::HACKATHON_NAME}!")
18 | end
19 |
20 | def denied_email(user)
21 | @user = user;
22 | mail(to: @user.email, subject: "#{HackumassWeb::Application::HACKATHON_NAME} #{HackumassWeb::Application::HACKATHON_VERSION} Application Status Update")
23 | end
24 |
25 | def waitlisted_email(user)
26 | @user = user;
27 | mail(to: @user.email, subject: "#{HackumassWeb::Application::HACKATHON_NAME} #{HackumassWeb::Application::HACKATHON_VERSION} Application Status Update")
28 | end
29 |
30 | def reminder_email(user, subject, message)
31 | @user = user
32 | @message = message
33 | @subject = subject
34 | mail(to: @user.email, subject: @subject)
35 | end
36 |
37 | def template_email(user, subject)
38 | @user = user
39 | @subject = subject
40 | mail(to: @user.email, subject: @subject)
41 | end
42 |
43 | end
44 |
--------------------------------------------------------------------------------
/app/models/application_record.rb:
--------------------------------------------------------------------------------
1 | class ApplicationRecord < ActiveRecord::Base
2 | self.abstract_class = true
3 | end
4 |
--------------------------------------------------------------------------------
/app/models/concerns/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/app/models/concerns/.keep
--------------------------------------------------------------------------------
/app/models/custom_rsvp.rb:
--------------------------------------------------------------------------------
1 | class CustomRsvp < ApplicationRecord
2 | belongs_to :user
3 |
4 | validate :custom_field_validation
5 |
6 | private
7 |
8 | def custom_field_validation
9 | HackumassWeb::Application::RSVP_CUSTOM_FIELDS.each do |c|
10 | if c['required']
11 | if answers[c['name']] == nil or answers[c['name']] == '' or answers[c['name']].length == 0
12 | errors.add("missing_custom_field_#{c['name']}".to_sym, "Please fill out this field: #{c['label']}")
13 | end
14 | end
15 | if c['validate_regex'] and answers[c['name']] and answers[c['name']].length > 0
16 | r = Regexp.new c['validate_regex']
17 | if !r.match?(answers[c['name']])
18 | errors.add("regex_answers_#{c['name']}".to_sym, c['validate_error'] ? c['validate_error'] : "Invalid entry for field: #{c['label']}")
19 | end
20 | end
21 | if c['max_chars']
22 | if answers[c['name']] and answers[c['name']].length > c['max_chars']
23 | errors.add("too_long_answers_#{c['name']}".to_sym, "The value for '#{c['label']}' is too long! The maximum length is #{c['max_chars']} characters")
24 | end
25 | end
26 | end
27 | end
28 |
29 | end
30 |
--------------------------------------------------------------------------------
/app/models/email.rb:
--------------------------------------------------------------------------------
1 | class Email < ApplicationRecord
2 | # TODO: Add Validations for emails i.e. message is present, title is present etc.
3 | end
4 |
--------------------------------------------------------------------------------
/app/models/event.rb:
--------------------------------------------------------------------------------
1 | class Event < ApplicationRecord
2 | # TODO: Add a bunch of checks here
3 | # after_validation :remove_image_repeat
4 | validates_presence_of :start_time, :location, :title, :description
5 | has_many :event_attendances
6 | has_many :users, through: :event_attendances
7 | def self.to_csv
8 | CSV.generate do |csv|
9 |
10 | csv << Event.attribute_names
11 |
12 | Event.find_each do |event|
13 | csv << event.attributes.values
14 | end
15 | end
16 | end
17 | end
18 |
--------------------------------------------------------------------------------
/app/models/event_attendance.rb:
--------------------------------------------------------------------------------
1 | class EventAttendance < ApplicationRecord
2 | belongs_to :user
3 | belongs_to :event
4 | end
5 |
--------------------------------------------------------------------------------
/app/models/feature_flag.rb:
--------------------------------------------------------------------------------
1 | class FeatureFlag < ApplicationRecord
2 | validates_uniqueness_of :name
3 | end
4 |
--------------------------------------------------------------------------------
/app/models/hardware_checkout.rb:
--------------------------------------------------------------------------------
1 | class HardwareCheckout < ApplicationRecord
2 |
3 | validates_presence_of :user
4 | validates_presence_of :hardware_item
5 |
6 | belongs_to :user
7 | belongs_to :hardware_item
8 | end
9 |
--------------------------------------------------------------------------------
/app/models/hardware_checkout_log.rb:
--------------------------------------------------------------------------------
1 | class HardwareCheckoutLog < ApplicationRecord
2 | belongs_to :user
3 | belongs_to :hardware_item
4 | end
5 |
--------------------------------------------------------------------------------
/app/models/hardware_item.rb:
--------------------------------------------------------------------------------
1 | class HardwareItem < ApplicationRecord
2 | validates_presence_of :name, :count, :category, :location
3 | validates_numericality_of :count
4 | validates_uniqueness_of :uid
5 |
6 | has_many :hardware_checkouts, dependent: :destroy
7 | has_many :users, through: :hardware_checkouts
8 |
9 | def is_available?
10 | if count > 0
11 | 'Yes'
12 | else
13 | 'No'
14 | end
15 | end
16 |
17 | def to_csv
18 | attributes = %w{name uid}
19 | CSV.generate do |csv|
20 | item = self
21 | count = item.count
22 | while count >= 1
23 | csv << item.attributes.values_at(*attributes)
24 | count -= 1
25 | end
26 | end
27 | end
28 |
29 | end
30 |
--------------------------------------------------------------------------------
/app/models/judging_assignment.rb:
--------------------------------------------------------------------------------
1 | class JudgingAssignment < ApplicationRecord
2 | belongs_to :project
3 | belongs_to :user
4 |
5 | validates :user_id, presence: true
6 | validates :project_id, presence: true
7 | end
8 |
--------------------------------------------------------------------------------
/app/models/major.rb:
--------------------------------------------------------------------------------
1 | class Major < ApplicationRecord
2 | end
3 |
--------------------------------------------------------------------------------
/app/models/mentorship_notification.rb:
--------------------------------------------------------------------------------
1 | class MentorshipNotification < ApplicationRecord
2 | belongs_to :user
3 | end
4 |
--------------------------------------------------------------------------------
/app/models/mentorship_request.rb:
--------------------------------------------------------------------------------
1 | class MentorshipRequest < ApplicationRecord
2 | validates_presence_of :user, :title, :status, :urgency
3 | has_attached_file :screenshot
4 | validates_attachment_content_type :screenshot, :content_type => /image/
5 | belongs_to :user
6 |
7 | def urgency_str
8 | if urgency == 0
9 | return "Not Urgent"
10 | elsif urgency == 1
11 | return "Mildly Urgent"
12 | elsif urgency == 2
13 | return "Urgent"
14 | else
15 | return "Drastically Urgent"
16 | end
17 | end
18 |
19 | end
20 |
--------------------------------------------------------------------------------
/app/models/prize.rb:
--------------------------------------------------------------------------------
1 | class Prize < ApplicationRecord
2 | validates_presence_of :award, :description, :title, :sponsor, :priority
3 | end
4 |
--------------------------------------------------------------------------------
/app/models/university.rb:
--------------------------------------------------------------------------------
1 | class University < ApplicationRecord
2 | end
3 |
--------------------------------------------------------------------------------
/app/views/custom_rsvp/show.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 | <% if @applicant %>
10 | <%= link_to 'View Application',
11 | event_application_path(@applicant.id),
12 | class: 'btn btn-purple event-application-nav-button' %>
13 | <% else %>
14 | The user does not have an event application.
15 | <% end %>
16 |
17 |
18 |
19 | <%= render "custom_rsvp/form" %>
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/app/views/devise/confirmations/new.html.erb:
--------------------------------------------------------------------------------
1 | Resend confirmation instructions
2 |
3 | <%= form_for(resource, as: resource_name, url: confirmation_path(resource_name), html: { method: :post }) do |f| %>
4 | <%= devise_error_messages! %>
5 |
6 |
7 | <%= f.label :email %>
8 | <%= f.email_field :email, autofocus: true, value: (resource.pending_reconfirmation? ? resource.unconfirmed_email : resource.email) %>
9 |
10 |
11 |
12 | <%= f.submit "Resend confirmation instructions" %>
13 |
14 | <% end %>
15 |
16 | <%= render "devise/shared/links" %>
17 |
--------------------------------------------------------------------------------
/app/views/devise/passwords/edit.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 | <%= render 'partial/hackathonlogo', local_assigns: {width: "70%", height: "70%"}%>
4 | <%= form_for(resource, as: resource_name, url: password_path(resource_name), html:{class: "card", method: :put}) do |f| %>
5 | <%= f.hidden_field :reset_password_token %>
6 |
7 |
Please update your password below
8 |
9 | Password
10 | <%= f.password_field :password, placeholder: "New Password", autofocus: true, autocomplete: "off", class: "form-control" %>
11 |
12 |
13 | Confirm Password
14 | <%= f.password_field :password_confirmation, placeholder: "Confirm Password", autocomplete: "off", class: "form-control" %>
15 |
16 |
19 |
20 | <% end %>
21 |
22 | <%= render "devise/shared/links" %>
23 |
24 |
25 |
--------------------------------------------------------------------------------
/app/views/devise/passwords/new.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 | <%= render 'partial/hackathonlogo', local_assigns: {width: "70%", height: "70%"}%>
4 | <%= form_for(resource, as: resource_name, url: password_path(resource_name), html:{class: "card"}) do |f| %>
5 |
6 |
Forgot password
7 |
Enter your email address and you will receive a link to reset your password.
8 |
9 | Email address
10 | <%= f.email_field :email, autofocus: true, class: "form-control", placeholder: "Enter Email" %>
11 |
12 |
15 |
16 | <% end %>
17 |
18 | <%= render "devise/shared/links" %>
19 |
20 |
21 |
--------------------------------------------------------------------------------
/app/views/devise/sessions/new.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 | <%= render 'partial/hackathonlogo', local_assigns: {width: "90%", height: "90%"}%>
4 |
5 | <% if HackumassWeb::Application::PROJECTS_PUBLIC and Project.all.count > 0 %>
6 | <%= link_to "View #{HackumassWeb::Application::HACKATHON_NAME} #{HackumassWeb::Application::HACKATHON_VERSION} Projects", public_projects_path, class: 'btn btn-primary btn-block' %>
7 |
8 | <% end %>
9 |
10 |
11 | <%= form_for(resource, as: resource_name, url: session_path(resource_name), html:{class: "card"}) do |f| %>
12 |
13 |
Login to your account
14 |
15 | Email address
16 | <%= f.email_field :email, placeholder: "Enter Email", autofocus: true, class: "form-control" %>
17 |
18 |
19 | Password
20 | <%= f.password_field :password, placeholder: "Password", autocomplete: "off", class: "form-control"%>
21 |
22 |
23 |
24 |
25 | Remember me
26 |
27 |
28 |
31 |
32 | <% end %>
33 |
34 | <%= render "devise/shared/links" %>
35 |
36 | <%= render 'partial/hackathonfooter' %>
37 |
38 |
39 |
--------------------------------------------------------------------------------
/app/views/devise/shared/_links.html.erb:
--------------------------------------------------------------------------------
1 | <%- if controller_name != 'sessions' %>
2 | <%= link_to "Already have an account? Log in", new_session_path(resource_name) %>
3 | <% end -%>
4 |
5 | <%- if devise_mapping.registerable? && controller_name != 'registrations' %>
6 | <%= link_to "Don't have an account? Sign up!", new_registration_path(resource_name)%>
7 | <% end -%>
8 |
9 | <%- if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations' %>
10 | <%= link_to "Forgot your password?", new_password_path(resource_name) %>
11 | <% end -%>
12 |
13 | <%- if devise_mapping.omniauthable? %>
14 | <%- resource_class.omniauth_providers.each do |provider| %>
15 | <%= link_to "Sign in with #{OmniAuth::Utils.camelize(provider)}", omniauth_authorize_path(resource_name, provider) %>
16 | <% end -%>
17 | <% end -%>
18 |
--------------------------------------------------------------------------------
/app/views/devise/unlocks/new.html.erb:
--------------------------------------------------------------------------------
1 | Resend unlock instructions
2 |
3 | <%= form_for(resource, as: resource_name, url: unlock_path(resource_name), html: { method: :post }) do |f| %>
4 | <%= devise_error_messages! %>
5 |
6 |
7 | <%= f.label :email %>
8 | <%= f.email_field :email, autofocus: true %>
9 |
10 |
11 |
12 | <%= f.submit "Resend unlock instructions" %>
13 |
14 | <% end %>
15 |
16 | <%= render "devise/shared/links" %>
17 |
--------------------------------------------------------------------------------
/app/views/emails/_form.html.erb:
--------------------------------------------------------------------------------
1 | <%= form_for(email) do |f| %>
2 |
3 | <% if email.errors.any? %>
4 |
5 |
6 |
7 |
<%= pluralize(email.errors.count, "error") %> prohibited this email from being saved:
8 |
9 |
10 |
11 | <% email.errors.full_messages.each do |message| %>
12 | <%= message %>
13 | <% end %>
14 |
15 |
16 |
17 | <%= email.errors.keys %>
18 | <% end %>
19 |
20 |
21 | <%= f.label :subject, class:'control-label' %>
22 | <%= f.text_field :subject, class: 'form-control', placeholder: 'Type email subject here' %>
23 |
24 |
25 |
26 |
27 | <%= f.label :message, class:'control-label' %>
28 | <%= f.text_area :message, class: 'form-control', placeholder: 'Type the email you want to send here. Exclude the opening statement (e.g. Hello @name... That will be automatically added.)'%>
29 |
30 |
31 |
32 | <%= f.label :mailing_list, class:'control-label' %>
33 | <%= f.select(:mailing_list, ['Accepted Applicants', 'Waitlisted Applicants', 'Denied Applicants', 'Undecided Applicants', 'All Applicants', 'Send Test Email to Myself', 'Send Email To Those Who Have Not Applied','All Users'], {include_blank: "Select a category"}, { :class => 'form-control' }) %>
34 |
35 |
36 |
37 | <%= f.submit class: 'btn btn-primary' %>
38 |
39 | <% end %>
40 |
41 |
--------------------------------------------------------------------------------
/app/views/emails/edit.html.erb:
--------------------------------------------------------------------------------
1 | Editing Email
2 |
3 | <%= render 'form', email: @email %>
4 |
5 | <%= link_to 'Show', @email %> |
6 | <%= link_to 'Back', emails_path %>
7 |
--------------------------------------------------------------------------------
/app/views/emails/index.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 | <% if @emails.empty? %>
8 | There aren't any emails... Yet.
9 | <% else %>
10 |
11 |
12 |
13 |
14 |
15 |
16 | Subject
17 | Message
18 | Mailing List
19 | Status
20 | Sent by
21 | Created at
22 |
23 |
24 |
25 | <% @emails.each do |email| %>
26 |
27 | <%= link_to email.subject, email %>
28 | <%= truncate(email.message , length: 30)%>
29 | <%= email.mailing_list %>
30 | <%= email.status %>
31 | <%= email.sent_by %>
32 | <%= email.created_at.strftime('%A, %b %d at %I:%M %p') %>
33 |
34 | <% end %>
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 | <% end %>
43 |
44 | <%= link_to 'Return to Admin Page', admin_path, class: 'btn btn-secondary'%>
45 | <%= link_to 'Create New Email', new_email_path, class: 'btn btn-primary' %>
46 |
--------------------------------------------------------------------------------
/app/views/emails/new.html.erb:
--------------------------------------------------------------------------------
1 | New Email
2 |
3 |
4 |
5 | Just FYI: This email will not be sent automatically. Once you create the email you will have to preview it and then send it.
6 |
7 |
8 | <%= render 'form', email: @email %>
9 |
10 | <%= link_to 'Back', emails_path %>
11 |
--------------------------------------------------------------------------------
/app/views/event_applications/edit.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | <% if @application.errors.any? %>
7 |
8 |
9 |
15 |
16 |
17 | <% @application.errors.values.each do |message| %>
18 |
19 | <%= message.to_s.gsub(%r{[\[\]"]}, '').gsub(%r{\\n}, '') %>
20 |
21 | <% end %>
22 |
23 |
24 |
25 | <% end %>
26 |
27 | <% if !@application.errors.any? %>
28 |
29 | <% end %>
30 |
35 | <%= render 'form', event_application: @event_application %>
36 |
37 |
38 |
39 |
40 |
41 |
--------------------------------------------------------------------------------
/app/views/event_applications/new.html.erb:
--------------------------------------------------------------------------------
1 | <%
2 | =begin%>
3 | This file handles how creating a new application looks in the browser.
4 | If an application errors in some way it lets the user know why.
5 | <%
6 | =end%>
7 |
8 |
9 |
10 |
11 | <% if @application.errors.any? %>
12 |
13 |
14 |
20 |
21 |
22 | <% @application.errors.values.each do |message| %>
23 |
24 | <%= message.to_s.gsub(%r{[\[\]"]}, '').gsub(%r{\\n}, '') %>
25 |
26 | <% end %>
27 |
28 |
29 |
30 | <% end %>
31 |
32 | <% if !@application.errors.any? %>
33 |
34 | <% end %>
35 |
40 | <%= render 'form', event_application: @event_application %>
41 |
42 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/app/views/events/_event.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.extract! event, :id, :title, :description, :location, :start_time, :end_time, :host, :created_by, :created_at, :updated_at
2 | json.url event_url(event, format: :json)
3 |
--------------------------------------------------------------------------------
/app/views/events/edit.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | <%= render 'form', event: @event %>
7 |
8 |
9 | <%= link_to 'Show', @event %> |
10 | <%= link_to 'Back', events_path %>
11 |
--------------------------------------------------------------------------------
/app/views/events/index.html.erb:
--------------------------------------------------------------------------------
1 |
4 | <% if current_user.is_admin? or current_user.is_organizer? %>
5 | <%= link_to 'Download CSV', events_path(@event, format: 'csv'), class: 'btn btn-secondary' %>
6 |
7 |
8 | <% end %>
9 |
10 | <% if [true, false].sample %>
11 |
12 | Just FYI: This is a live schedule! More events, workshops, and talks will be added before the hackathon begins and even during the hackathon.
13 |
14 | <% end %>
15 |
16 | <% if @events.empty? %>
17 | Looks like there aren't any events yet....
18 | <% end %>
19 |
20 |
21 |
22 | <% @events.each do |event| %>
23 | <%= render 'event', event: event, show_edit_and_delete: true%>
24 | <% end %>
25 |
26 |
27 | <%= will_paginate @events %>
28 |
29 |
30 |
31 |
32 |
33 | <% if current_user.is_admin? or current_user.is_organizer? %>
34 | <%= link_to 'New Event', new_event_path, class: 'btn btn-secondary' %>
35 | <% end %>
36 |
--------------------------------------------------------------------------------
/app/views/events/index.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.array! @all_events, partial: 'events/event', as: :event
2 |
--------------------------------------------------------------------------------
/app/views/events/new.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | <%= render 'form', event: @event %>
7 |
8 |
9 |
10 | <%= link_to 'Back', events_path %>
11 |
--------------------------------------------------------------------------------
/app/views/feature_flags/_feature_flag.erb:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 | <% if feature_flag.value == true %>
6 |
7 |
8 |
9 | <% else %>
10 |
11 |
12 |
13 | <% end %>
14 |
15 | <%= feature_flag.display_name %>
16 |
17 | <% if feature_flag.value == true%>
18 | <%= button_to 'Disable',
19 | {controller:'feature_flags', action: 'disable',
20 | params: {flag: feature_flag}},
21 | {class: 'btn btn-secondary btn-sm'} %>
22 | <% else %>
23 | <%= button_to 'Enable',
24 | {controller:'feature_flags', action: 'enable',
25 | params: {flag: feature_flag}},
26 | {class: 'btn btn-secondary btn-sm'} %>
27 | <% end %>
28 |
29 |
--------------------------------------------------------------------------------
/app/views/hardware_items/_barcode.html.erb:
--------------------------------------------------------------------------------
1 |
2 | <%= @hardware_item.name %>
3 |
4 | <%= @hardware_item.uid %>
5 |
--------------------------------------------------------------------------------
/app/views/hardware_items/_checked_out_items.html.erb:
--------------------------------------------------------------------------------
1 | <% if @checked_out_items.empty? %>
2 | This item hasn't been checked out yet
3 | <% else %>
4 | <% if HackumassWeb::Application::SLACK_ENABLED %>
5 |
11 |
12 | <% end %>
13 | <% end %>
14 |
15 |
16 |
17 | <% @checked_out_items.each do |item| %>
18 |
19 | <%= item.user.full_name.titleize %> on <%= item.created_at.strftime('%A, %b %d at %I:%M %p')%>
20 |
21 | <% if HackumassWeb::Application::SLACK_ENABLED %>
22 |
28 | <% end %>
29 |
30 | <%= link_to 'Return', item, class: 'btn btn-sm btn-danger', method: :delete, data: { confirm: 'Are you sure you want to return this item?' } %>
31 |
32 | <% end %>
33 |
34 |
35 |
--------------------------------------------------------------------------------
/app/views/hardware_items/_checkout.html.erb:
--------------------------------------------------------------------------------
1 | <%= form_for(@hardware_checkout) do |f| %>
2 | <% if @hardware_checkout.errors.any? %>
3 |
4 |
<%= pluralize(hardware_checkout.errors.count, "error") %> prohibited this hardware_checkout from being saved:
5 |
6 |
7 | <% @hardware_checkout.errors.full_messages.each do |message| %>
8 | <%= message %>
9 | <% end %>
10 |
11 |
12 | <% end %>
13 |
14 |
15 |
16 |
17 | <%= f.text_field :user_id, class: 'form-control', placeholder: 'Scan QR Code or Type email', :autofocus => true, data: {autocomplete: autocomplete_user_email_hardware_checkouts_path}, 'min-length' => 1 %>
18 |
19 |
20 |
21 |
22 | <%= f.number_field :hardware_item_id, hidden: true, value: @hardware_item.id %>
23 |
24 |
25 |
26 |
27 | <%= f.submit 'Checkout Item', class: 'btn btn-warning'%>
28 |
29 | <% end %>
30 |
--------------------------------------------------------------------------------
/app/views/hardware_items/_checkout_log.html.erb:
--------------------------------------------------------------------------------
1 | <% if @checkout_log.empty? %>
2 | There is no checkout history for this item.
3 | <% end %>
4 |
5 |
6 | <% unless @checkout_log.empty? %>
7 |
8 |
9 | Time
10 | User
11 | Action
12 | Message
13 |
14 |
15 | <% end %>
16 |
17 | <% @checkout_log.each do |item| %>
18 |
19 | <%= item.created_at.strftime('%A, %b %d at %I:%M %p')%>
20 | <%= item.user.full_name.titleize %> (<%= item.user.email %>)
21 | <%= item.action %>
22 | <%= item.message %>
23 |
24 | <% end %>
25 |
26 |
27 |
--------------------------------------------------------------------------------
/app/views/hardware_items/_hardware_item.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.extract! hardware_item, :id, :name, :count, :link, :category, :available, :uid, :created_at, :updated_at
2 | json.url hardware_item_url(hardware_item, format: :json)
3 |
--------------------------------------------------------------------------------
/app/views/hardware_items/edit.html.erb:
--------------------------------------------------------------------------------
1 | Editing Hardware Item
2 |
3 | <%= render 'form', hardware_item: @hardware_item %>
4 |
5 | <%= link_to 'Show', @hardware_item %> |
6 | <%= link_to 'Back', hardware_items_path %>
7 |
--------------------------------------------------------------------------------
/app/views/hardware_items/index.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.array! @all_hardware_items, partial: 'hardware_items/hardware_item', as: :hardware_item
2 |
--------------------------------------------------------------------------------
/app/views/hardware_items/new.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 | <%= render 'form', hardware_item: @hardware_item %>
6 |
7 | <%= link_to 'Back', hardware_items_path, class: 'btn btn-default', style: 'color: #2196F3' %>
8 |
--------------------------------------------------------------------------------
/app/views/judging/_assigned_projects.html.erb:
--------------------------------------------------------------------------------
1 | <% if !@assigned.nil? and !@assigned.empty? %>
2 | Assigned to Me
3 |
4 |
5 |
6 |
7 |
8 | Table #
9 | Title
10 | Tag
11 | Times Judged
12 | Action
13 |
14 |
15 |
16 |
17 | <% @assigned.each do |asn| %>
18 |
19 | <% if asn.project.table_id.nil? %>
20 | TBD
21 | <% else %>
22 | <%= asn.project.table_id %>
23 | <% if asn.project.power %>
24 | (Outlet)
25 | <% end %>
26 |
27 | <% end %>
28 |
29 | <%= link_to truncate(asn.project.title, length: 30), asn.project %>
30 |
31 |
32 | <% unless asn.tag.nil? %> <%= asn.tag %>
33 | <% end %>
34 |
35 | <%= @times_judged[asn.project.id] %>
36 |
37 | <%= link_to "Judge", new_judging_path(:project_id => asn.project.id, :tag => asn.tag), class: 'btn btn-primary' %>
38 |
39 | <% end %>
40 |
41 |
42 |
43 | <% else %>
44 | You have no projects assigned to judge.
45 | <% end %>
--------------------------------------------------------------------------------
/app/views/judging/_judged_projects.html.erb:
--------------------------------------------------------------------------------
1 | <% if !@judged_by_me.nil? and !@judged_by_me.empty? %>
2 | Judged By Me
3 |
4 |
5 |
6 |
7 |
8 | Table #
9 | Title
10 | Tag
11 | Times Judged
12 | Action
13 |
14 |
15 |
16 |
17 | <% @judged_by_me.each do |judgement| %>
18 |
19 | <% if judgement.project.table_id.nil? %>
20 | TBD
21 | <% else %>
22 |
23 | <%= judgement.project.table_id %>
24 | <% if judgement.project.power %>
25 | (Outlet)
26 | <% end %>
27 |
28 | <% end %>
29 |
30 | <%= link_to truncate(judgement.project.title, length: 30), judgement.project %>
31 |
32 |
33 | <% if !judgement.tag.nil? %> <%= judgement.tag %>
34 | <% end %>
35 |
36 | <%= @times_judged[judgement.project.id] %> (including you)
37 |
38 | <%= link_to "View", judgement_path(:id => judgement.id), class: 'btn btn-primary' %>
39 | <%= link_to "Edit", edit_judgement_path(:id => judgement.id), class: 'btn btn-primary' %>
40 |
41 |
42 | <% end %>
43 |
44 |
45 |
46 | <% else %>
47 | You have not judged any projects.
48 | <% end %>
--------------------------------------------------------------------------------
/app/views/judging/_score.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Field
5 | Score
6 |
7 |
8 |
9 | <% score.custom_scores.keys.each do |field| %>
10 |
11 | <%= field.titleize %>
12 |
13 | <% if score.custom_scores[field].length > 4 %>
14 |
15 |
16 |
17 | <%= score.custom_scores[field] %>
18 |
19 | <% else %>
20 | <%= score.custom_scores[field] %>
21 | / <%= @field_max_scores[field] %>
22 | <% end %>
23 |
24 |
25 | <% end %>
26 |
27 |
28 |
29 | Total Score
30 |
31 | <%= score.score %>
32 | / <%= @max_score %>
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/app/views/judging/edit.html.erb:
--------------------------------------------------------------------------------
1 | <%= render :file => "judging/new.html.erb" %>
2 |
--------------------------------------------------------------------------------
/app/views/judging/show.html.erb:
--------------------------------------------------------------------------------
1 |
11 |
12 |
13 |
14 |
Project: <%= @score.project.title %>
15 | Judge: <%= @score.user.full_name %>
16 | <%= render 'score', score: @score, max_width: '600px' %>
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/app/views/judging/tag_assign.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
Assign a judge to all projects competing in a prize category.
10 | <%= form_tag add_judge_to_tag_path, method: :post do %>
11 |
12 |
25 | <% end %>
26 |
27 |
28 |
29 |
30 |
31 | <%= link_to 'Return to Judging Home', judging_index_path, class: 'btn btn-secondary' %>
32 |
33 |
34 |
--------------------------------------------------------------------------------
/app/views/layouts/application.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | <%= HackumassWeb::Application::HACKATHON_NAME %> Dashboard
5 |
6 | <%= csrf_meta_tags %>
7 | <% if HackumassWeb::Application::FAVICON_URL != nil %>
8 | <%= favicon_link_tag HackumassWeb::Application::FAVICON_URL %>
9 | <% end %>
10 | <%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %>
11 | <%= stylesheet_link_tag 'custom', media: 'all', 'data-turbolinks-track': 'reload' %>
12 | <%= javascript_include_tag 'application', 'data-turbolinks-track': 'reload' %>
13 | <%= javascript_include_tag 'custom', 'data-turbolinks-track': 'reload' %>
14 | <%= tag :meta, name: :page_specific, action: action_name, controller: controller_name %>
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 | <% if user_signed_in? %>
23 | <%= render 'shared/navigation' %>
24 | <% end %>
25 |
26 |
27 | <% flash.each do |type, message| %>
28 |
29 |
30 | <%= message %>
31 |
32 | <% end %>
33 |
34 |
35 | <%= yield %>
36 |
37 |
38 | <% if user_signed_in? %>
39 | <%= render 'shared/footer' %>
40 | <% end %>
41 |
42 |
43 |
44 |
45 |
--------------------------------------------------------------------------------
/app/views/layouts/mailer.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
8 |
9 |
10 |
11 | <%= yield %>
12 |
13 |
14 |
--------------------------------------------------------------------------------
/app/views/layouts/mailer.text.erb:
--------------------------------------------------------------------------------
1 | <%= yield %>
2 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/_form.html.erb:
--------------------------------------------------------------------------------
1 | <%= form_with(model: mentorship_notification, local: true) do |form| %>
2 | <% if mentorship_notification.errors.any? %>
3 |
4 |
<%= pluralize(mentorship_notification.errors.count, "error") %> prohibited this mentorship_notification from being saved:
5 |
6 |
7 | <% mentorship_notification.errors.full_messages.each do |message| %>
8 | <%= message %>
9 | <% end %>
10 |
11 |
12 | <% end %>
13 |
14 |
22 |
23 |
24 | OR, Receive notifications for all new mentorship requests:
25 | <%= form.check_box :all %>
26 |
27 |
28 |
29 | <% end %>
30 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/_mentorship_notification.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.extract! mentorship_notification, :id, :user_id, :tech, :all, :created_at, :updated_at
2 | json.url mentorship_notification_url(mentorship_notification, format: :json)
3 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/edit.html.erb:
--------------------------------------------------------------------------------
1 |
4 | <%= render 'form', mentorship_notification: @mentorship_notification %>
5 |
6 | <%= link_to 'Click here to DISABLE ALL NOTIFICATIONS', @mentorship_notification, method: :delete, data: { confirm: 'Are you sure?' }, class: 'btn btn-primary', style: "display: inline-block" %>
7 | <%= link_to 'Back', mentorship_requests_path, class: 'btn btn-danger' %>
8 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/index.html.erb:
--------------------------------------------------------------------------------
1 | <%= notice %>
2 |
3 | Mentorship Notifications
4 |
5 |
6 |
7 |
8 | User
9 | Tech
10 | All
11 |
12 |
13 |
14 |
15 |
16 | <% @mentorship_notifications.each do |mentorship_notification| %>
17 |
18 | <%= mentorship_notification.user_id %>
19 | <%= mentorship_notification.tech %>
20 | <%= mentorship_notification.all %>
21 | <%= link_to 'Show', mentorship_notification %>
22 | <%= link_to 'Edit', edit_mentorship_notification_path(mentorship_notification) %>
23 | <%= link_to 'Destroy', mentorship_notification, method: :delete, data: { confirm: 'Are you sure?' } %>
24 |
25 | <% end %>
26 |
27 |
28 |
29 |
30 |
31 | <%= link_to 'New Mentorship Notification', new_mentorship_notification_path %>
32 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/index.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.array! @mentorship_notifications, partial: 'mentorship_notifications/mentorship_notification', as: :mentorship_notification
2 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/new.html.erb:
--------------------------------------------------------------------------------
1 |
4 | <%= render 'form', mentorship_notification: @mentorship_notification %>
5 | <%= link_to 'Back', mentorship_notifications_path, class: 'btn btn-danger'%>
6 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/show.html.erb:
--------------------------------------------------------------------------------
1 | <%= notice %>
2 |
3 |
4 | User:
5 | <%= @mentorship_notification.user %>
6 |
7 |
8 |
9 | Tech:
10 | <%= @mentorship_notification.tech %>
11 |
12 |
13 |
14 | All:
15 | <%= @mentorship_notification.all %>
16 |
17 |
18 | <%= link_to 'Edit', edit_mentorship_notification_path(@mentorship_notification) %> |
19 | <%= link_to 'Back', mentorship_notifications_path %>
20 |
--------------------------------------------------------------------------------
/app/views/mentorship_notifications/show.json.jbuilder:
--------------------------------------------------------------------------------
1 | json.partial! "mentorship_notifications/mentorship_notification", mentorship_notification: @mentorship_notification
2 |
--------------------------------------------------------------------------------
/app/views/mentorship_requests/edit.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 | <%= render 'form', mentorship_request: @mentorship_request %>
6 |
--------------------------------------------------------------------------------
/app/views/mentorship_requests/index.html.erb:
--------------------------------------------------------------------------------
1 | <% if @current_user.is_attendee? %>
2 | <%= render 'attendee_view'%>
3 | <% else %>
4 | <%= render 'mentor_view'%>
5 | <% end %>
6 |
--------------------------------------------------------------------------------
/app/views/mentorship_requests/new.html.erb:
--------------------------------------------------------------------------------
1 |
2 | <%= current_user.first_name %>'s Mentorship Request
3 |
4 | <%= render 'form', mentorship_request: @mentorship_request %>
5 |
--------------------------------------------------------------------------------
/app/views/pages/check_in.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
<%= @check_in_count %>
14 | Check-In Attendees
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
<%= @rsvp_count %>
27 | RSVP'd Users
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 | <%= form_tag check_in_path, method: :get, class:'col-lg-12' do%>
37 |
38 | <%= text_field_tag :email,'', class: 'form-control', placeholder: 'Scan QR Code or Type email', :autofocus => true, :onfocus => 'this.select()', :onmouseup => 'return false', data: {autocomplete: autocomplete_user_email_pages_path}, 'min-length' => 1%>
39 |
40 | <%= submit_tag 'Check In', class: 'btn btn-primary' %>
41 |
42 |
43 |
44 | Force check in, even if participant wasn't accepted or didn't apply
45 |
46 | <%end%>
47 |
48 |
49 |
--------------------------------------------------------------------------------
/app/views/pages/index.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | <% if current_user.is_admin? %>
7 | <%= render 'shared/home_pages/admin_view'%>
8 | <% elsif current_user.is_organizer? %>
9 | <%= render 'shared/home_pages/organizer_view'%>
10 | <% elsif current_user.is_mentor? %>
11 | <%= render 'shared/home_pages/mentor_view'%>
12 | <% elsif current_user.check_in %>
13 | <%= render 'shared/home_pages/checked_in_view'%>
14 | <% else %>
15 | <% if current_user.has_applied? %>
16 | <% if current_user.event_application.status == 'undecided' %>
17 | <%= render 'shared/home_pages/undecided_view'%>
18 | <% elsif current_user.event_application.status == 'accepted' %>
19 | <% if current_user.rsvp %>
20 | <% if current_user.check_in %>
21 | <%= render 'shared/home_pages/checked_in_view'%>
22 | <% else %>
23 | <%= render 'shared/home_pages/rsvp_view'%>
24 | <% end %>
25 | <% else %>
26 | <%= render 'shared/home_pages/accepted_view'%>
27 | <% end %>
28 | <% elsif current_user.event_application.status == 'waitlisted' %>
29 | <%= render 'shared/home_pages/waitlisted_view'%>
30 | <% elsif current_user.event_application.status == 'denied' %>
31 | <%= render 'shared/home_pages/denied_view'%>
32 | <% end %>
33 | <% else %>
34 | <%= render 'shared/home_pages/new_user_view'%>
35 | <% end %>
36 | <% end %>
37 |
38 |
39 |
--------------------------------------------------------------------------------
/app/views/pages/join_slack.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | <% if HackumassWeb::Application::SLACK_ENABLED %>
7 | <%= render file: HackumassWeb::Application::copy_for('pages/join_slack') %>
8 |
18 | <% else %>
19 |
20 |
21 |
Slack integration is disabled. Please contact a hackathon organizer if you encounter this page while trying to access a feature.
22 |
23 |
24 | <% end %>
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/app/views/pages/permissions.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | <%= render 'shared/permissions' %>
7 |
8 |
9 | <%= link_to 'Return to Admin Page', admin_path, class: 'btn btn-secondary'%>
--------------------------------------------------------------------------------
/app/views/pages/redeem_code.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
14 |
15 |
16 |
17 |
18 |
19 | <%= form_tag use_code_path, method: :post, class:'col-lg-12', id: 'id-form' do %>
20 |
21 |
22 | <%= text_field_tag :code, params[:code], class: 'form-control', placeholder: 'Code (Case Insensitive)', :id => 'id-code', :autofocus => true %>
23 |
24 |
25 | <%= submit_tag 'Redeem Code', name: nil, id: 'id-submit', class: 'btn btn-primary btn-raised' %>
26 |
27 |
28 | <%end%>
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/app/views/paper_judging/index.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
Generate paper judging forms
9 |
Only click this button once. You will be brought to a new page containing a PDF with judging forms for each submitted project.
10 | <%= button_to 'Generate Judging Forms',
11 | {controller: 'paper_judging', action: 'generate_forms'},
12 | {class: 'btn btn-primary btn-block', form: {target: '_blank', id: 'makebutton', onsubmit: "onSubmit()"}} %>
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/app/views/partial/_hackathonfooter.html.erb:
--------------------------------------------------------------------------------
1 |
2 | Made with ❤ by the <%= HackumassWeb::Application::HACKATHON_NAME %> Tech Team.
3 |
4 |
5 | Powered by the
6 |
7 | <%= image_tag("dashboard-logo.png", height: 16, class: 'dashboard-logo') %>
8 | FuseUMass Platform
9 |
10 |
--------------------------------------------------------------------------------
/app/views/partial/_hackathonlogo.html.erb:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/app/views/prizes/assign.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 | <% if @project.nil? %>
10 | <%= form_tag prize_assign_prize_path, method: :post do %>
11 |
22 | <% end %>
23 | <% else %>
24 |
This Prize Has Been Assigned to a Winning Project.
25 |
Project Name: <%= @project.title %>
26 | <%= link_to "View Project", @project, class: 'btn btn-primary' %>
27 | <%= link_to "Remove Prize From Project", prize_unassign_prize_path(:project_name => @project.title, :prize_id => @prize.id), class: 'btn btn-danger', method: :post %>
28 |
29 | <% end %>
30 |
31 |
32 |
33 |
34 |
35 | <%= link_to 'Return to Prizes', prizes_path, class: 'btn btn-secondary' %>
36 |
37 |
38 |
--------------------------------------------------------------------------------
/app/views/prizes/edit.html.erb:
--------------------------------------------------------------------------------
1 | Editing Prize
2 |
3 | <%= render 'form', prize: @prize %>
4 |
5 | <%= link_to 'Show', @prize %> |
6 | <%= link_to 'Back', prizes_path %>
7 |
--------------------------------------------------------------------------------
/app/views/prizes/index.html.erb:
--------------------------------------------------------------------------------
1 | <%= notice %>
2 |
9 | Prizes
10 |
11 |
12 |
13 | <% @prizes.each do |prize| %>
14 |
15 |
16 | <% if prize.priority <= 1 %>
17 |
18 | <% end %>
19 | <% if prize.priority == 2 %>
20 |
21 | <% end %>
22 | <% if prize.priority == 3 %>
23 |
24 | <% end %>
25 |
32 |
33 |
Title: <%= prize.title %>
34 |
Description: <%= prize.description %>
35 |
Sponsored by: <%= prize.sponsor %>
36 | <% if prize.project_selectable %>
37 |
You need to apply for this prize by selecting it on your project.
38 | <% end %>
39 |
40 |
41 |
42 | <% end %>
43 |
44 |
45 |
46 |
47 | <% if current_user.is_organizer? %>
48 | <%= link_to 'New Prize', new_prize_path, class: 'btn btn-secondary' %>
49 | <% end %>
50 |
--------------------------------------------------------------------------------
/app/views/prizes/new.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | <%= render 'form', prize: @prize %>
7 |
8 |
9 |
10 |
11 | <%= link_to 'Back', prizes_path, class: 'btn btn-secondary'%>
12 |
--------------------------------------------------------------------------------
/app/views/prizes/show.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 | <%= notice %>
6 |
7 |
8 |
9 |
10 |
13 |
14 |
15 | Title:
16 | <%= @prize.title %>
17 |
18 |
19 |
20 | Description:
21 | <%= @prize.description %>
22 |
23 |
24 |
25 | Sponsor:
26 | <%= @prize.sponsor %>
27 |
28 |
29 |
30 | Priority:
31 | <%= @prize.priority %>
32 |
33 |
34 | <% if @prize.project_selectable %>
You need to apply for this prize by selecting it on your project. <% end %>
35 |
36 | <%= link_to 'Edit', edit_prize_path(@prize), class: 'btn btn-warning' %>
37 | <% if current_user.is_admin? %>
38 | <%= link_to "Assign to Project", prize_assign_path(:prize_id => @prize.id), class: 'btn btn-primary' %>
39 | <%= link_to 'Delete', prize_path(@prize), :method => :delete, class: 'btn btn-danger' %>
40 | <% end %>
41 |
42 |
43 |
44 | <%= link_to 'Go Back to Prizes', prizes_path, class: 'btn btn-secondary' %>
45 |
--------------------------------------------------------------------------------
/app/views/projects/_public_navigation.html.erb:
--------------------------------------------------------------------------------
1 |
29 |
46 |
--------------------------------------------------------------------------------
/app/views/projects/edit.html.erb:
--------------------------------------------------------------------------------
1 | Editing Project
2 |
3 | <%= render 'form', project: @project %>
4 |
5 | <%= link_to 'Show', @project %> |
6 | <%= link_to 'Back', projects_path %>
7 |
--------------------------------------------------------------------------------
/app/views/projects/new.html.erb:
--------------------------------------------------------------------------------
1 |
4 | <%= render 'form', project: @project %>
5 |
--------------------------------------------------------------------------------
/app/views/projects/project_submit_info.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 | To win prizes and have your hack judged, you must first create and submit an overview of your project on Dashboard. Please review the following requirements before creating the project.
9 |
10 |
11 |
12 |
13 | Project Creation
14 | You should only create one project page per team.
15 |
16 | Editing
17 | Project submissions may be edited after creation until the deadline.
18 |
19 | Team Members
20 | Every member of the project team must be included in the submission to receive credit.
21 |
22 | Prizes
23 | Up to 4 individual prizes are given per team. If there are more than 4 team members, only 4 will receive prizes.
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 | The email address associated with your account is: <%= current_user.email%> .
32 |
33 | In order to be added to a project as a contributor, the person creating the new project must add the email address above as a team member.
34 |
35 |
36 |
37 | <% if has_access_to_projects? %>
38 | <%= link_to new_project_path, class: "nav-link #{'active' if is_projects_create_active?}" do %>
39 |
Create New Project
40 | <% end %>
41 | <% end %>
42 |
43 |
44 |
--------------------------------------------------------------------------------
/app/views/shared/_footer.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
25 |
--------------------------------------------------------------------------------
/app/views/shared/_users.html.erb:
--------------------------------------------------------------------------------
1 | <% @all_users.each do |user| %>
2 | <%= user.full_name %>
3 | <% end %>
--------------------------------------------------------------------------------
/app/views/shared/home_pages/_denied_view.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | <%= render file: HackumassWeb::Application::copy_for('shared/home_pages/denied_participant') %>
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/app/views/shared/home_pages/_new_user_view.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | <% if check_feature_flag?($Applications) and @event_application_mode == 'open' %>
7 | <%= render file: HackumassWeb::Application::copy_for('shared/home_pages/new_user_applications_open') %>
8 | <% else %>
9 | <% if @event_application_mode == 'waitlist' %>
10 | <%= render file: HackumassWeb::Application::copy_for('shared/home_pages/new_user_applications_waitlisted') %>
11 | <% else %>
12 | <%= render file: HackumassWeb::Application::copy_for('shared/home_pages/new_user_applications_closed') %>
13 | <% end %>
14 | <% end %>
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/app/views/shared/home_pages/_undecided_view.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | <%= render file: HackumassWeb::Application::copy_for('shared/home_pages/undecided_participant') %>
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/app/views/shared/home_pages/_waitlisted_view.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | <%= render file: HackumassWeb::Application::copy_for('shared/home_pages/waitlisted_participant') %>
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/app/views/slackintegration/admin.html.erb:
--------------------------------------------------------------------------------
1 |
4 |
5 | <% if !HackumassWeb::Application::SLACK_ENABLED %>
6 |
7 |
8 |
9 |
Slack Integration Not Enabled
10 |
Changes on this page will not have any effect unless Slack integration is enabled.
11 |
12 |
13 |
14 | <% end %>
15 |
16 |
17 |
18 |
21 |
22 |
This will re-link all Slack users who do not have a slack_id set based on the email addresses currently in the Slack workspace.
23 |
24 |
Reassociate all users
25 |
26 |
27 |
28 |
This will re-link all Slack users in the workspace, overriding the slack_id of any users in Dashboard.
29 |
30 |
Force reassociate all users
31 |
32 |
33 |
34 | <%= link_to 'Return to Admin Page', admin_path, class: 'btn btn-secondary'%>
35 |
--------------------------------------------------------------------------------
/app/views/user_mailer/accepted_email.text.erb:
--------------------------------------------------------------------------------
1 | <%= render file: HackumassWeb::Application::copy_for('user_mailer/accepted_email_body.text.erb') %>
--------------------------------------------------------------------------------
/app/views/user_mailer/denied_email.text.erb:
--------------------------------------------------------------------------------
1 | <%= render file: HackumassWeb::Application::copy_for('user_mailer/denied_email_body.text.erb') %>
--------------------------------------------------------------------------------
/app/views/user_mailer/reminder_email.text.erb:
--------------------------------------------------------------------------------
1 | Hi <%= @user.first_name %>,
2 |
3 | <%= @message %>
4 |
5 |
--------------------------------------------------------------------------------
/app/views/user_mailer/submit_email.text.erb:
--------------------------------------------------------------------------------
1 | <%= render file: HackumassWeb::Application::copy_for('user_mailer/submit_email_body.text.erb') %>
--------------------------------------------------------------------------------
/app/views/user_mailer/template_email.txt.erb:
--------------------------------------------------------------------------------
1 | <%= render file: HackumassWeb::Application::copy_for('user_mailer/template_email_body.text.erb') %>
--------------------------------------------------------------------------------
/app/views/user_mailer/waitlisted_email.text.erb:
--------------------------------------------------------------------------------
1 | <%= render file: HackumassWeb::Application::copy_for('user_mailer/waitlisted_email_body.text.erb') %>
--------------------------------------------------------------------------------
/app/views/user_mailer/welcome_email.text.erb:
--------------------------------------------------------------------------------
1 | <%= render file: HackumassWeb::Application::copy_for('user_mailer/welcome_email_body.text.erb') %>
--------------------------------------------------------------------------------
/bin/bundle:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env ruby
2 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
3 | load Gem.bin_path('bundler', 'bundle')
4 |
--------------------------------------------------------------------------------
/bin/rails:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env ruby
2 | begin
3 | load File.expand_path('../spring', __FILE__)
4 | rescue LoadError => e
5 | raise unless e.message.include?('spring')
6 | end
7 | APP_PATH = File.expand_path('../config/application', __dir__)
8 | require_relative '../config/boot'
9 | require 'rails/commands'
10 |
--------------------------------------------------------------------------------
/bin/rake:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env ruby
2 | begin
3 | load File.expand_path('../spring', __FILE__)
4 | rescue LoadError => e
5 | raise unless e.message.include?('spring')
6 | end
7 | require_relative '../config/boot'
8 | require 'rake'
9 | Rake.application.run
10 |
--------------------------------------------------------------------------------
/bin/setup:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env ruby
2 | require 'pathname'
3 | require 'fileutils'
4 | include FileUtils
5 |
6 | # path to your application root.
7 | APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
8 |
9 | def system!(*args)
10 | system(*args) || abort("\n== Command #{args} failed ==")
11 | end
12 |
13 | chdir APP_ROOT do
14 | # This script is a starting point to setup your application.
15 | # Add necessary setup steps to this file.
16 |
17 | puts '== Installing dependencies =='
18 | system! 'gem install bundler --conservative'
19 | system('bundle check') || system!('bundle install')
20 |
21 | # puts "\n== Copying sample files =="
22 | # unless File.exist?('config/database.yml')
23 | # cp 'config/database.yml.sample', 'config/database.yml'
24 | # end
25 |
26 | puts "\n== Preparing database =="
27 | system! 'bin/rails db:setup'
28 |
29 | puts "\n== Removing old logs and tempfiles =="
30 | system! 'bin/rails log:clear tmp:clear'
31 |
32 | puts "\n== Restarting application server =="
33 | system! 'bin/rails restart'
34 | end
35 |
--------------------------------------------------------------------------------
/bin/spring:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env ruby
2 |
3 | # This file loads spring without using Bundler, in order to be fast.
4 | # It gets overwritten when you run the `spring binstub` command.
5 |
6 | unless defined?(Spring)
7 | require 'rubygems'
8 | require 'bundler'
9 |
10 | lockfile = Bundler::LockfileParser.new(Bundler.default_lockfile.read)
11 | spring = lockfile.specs.detect { |spec| spec.name == "spring" }
12 | if spring
13 | Gem.use_paths Gem.dir, Bundler.bundle_path.to_s, *Gem.path
14 | gem 'spring', spring.version
15 | require 'spring/binstub'
16 | end
17 | end
18 |
--------------------------------------------------------------------------------
/bin/update:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env ruby
2 | require 'pathname'
3 | require 'fileutils'
4 | include FileUtils
5 |
6 | # path to your application root.
7 | APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
8 |
9 | def system!(*args)
10 | system(*args) || abort("\n== Command #{args} failed ==")
11 | end
12 |
13 | chdir APP_ROOT do
14 | # This script is a way to update your development environment automatically.
15 | # Add necessary update steps to this file.
16 |
17 | puts '== Installing dependencies =='
18 | system! 'gem install bundler --conservative'
19 | system('bundle check') || system!('bundle install')
20 |
21 | puts "\n== Updating database =="
22 | system! 'bin/rails db:migrate'
23 |
24 | puts "\n== Removing old logs and tempfiles =="
25 | system! 'bin/rails log:clear tmp:clear'
26 |
27 | puts "\n== Restarting application server =="
28 | system! 'bin/rails restart'
29 | end
30 |
--------------------------------------------------------------------------------
/config.ru:
--------------------------------------------------------------------------------
1 | # This file is used by Rack-based servers to start the application.
2 |
3 | require_relative 'config/environment'
4 |
5 | run Rails.application
6 |
--------------------------------------------------------------------------------
/config/boot.rb:
--------------------------------------------------------------------------------
1 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__)
2 |
3 | require 'bundler/setup' # Set up gems listed in the Gemfile.
4 |
--------------------------------------------------------------------------------
/config/cable.yml:
--------------------------------------------------------------------------------
1 | development:
2 | adapter: async
3 |
4 | test:
5 | adapter: async
6 |
7 | production:
8 | adapter: redis
9 | url: redis://localhost:6379/1
10 |
--------------------------------------------------------------------------------
/config/database.yml:
--------------------------------------------------------------------------------
1 | # PostgreSQL
2 | # Sets the default db config to be Postgres for both Development and Production
3 | #
4 | default: &default
5 | adapter: postgresql
6 | encoding: unicode
7 | pool: 5
8 | username: dashboard
9 | password: dashboardpass
10 | host: postgres
11 |
12 | development:
13 | <<: *default
14 | database: dashboard_development
15 |
16 | # Warning: The database defined as "test" will be erased and
17 | # re-generated from your development database when you run "rake".
18 | # Do not set this db to the same as development or production.
19 | test:
20 | <<: *default
21 | database: dashboard_test
22 |
23 | production:
24 | <<: *default
25 | database: dashboard_production
26 |
--------------------------------------------------------------------------------
/config/environment.rb:
--------------------------------------------------------------------------------
1 | # Load the Rails application.
2 | require_relative 'application'
3 |
4 | # Initialize the Rails application.
5 | Rails.application.initialize!
6 |
7 | # remove fields_with_error divs
8 | ActionView::Base.field_error_proc = Proc.new do |html_tag, instance|
9 | html_tag.html_safe
10 | end
--------------------------------------------------------------------------------
/config/environments/test.rb:
--------------------------------------------------------------------------------
1 | Rails.application.configure do
2 | # Settings specified here will take precedence over those in config/application.rb.
3 |
4 | # The test environment is used exclusively to run your application's
5 | # test suite. You never need to work with it otherwise. Remember that
6 | # your test database is "scratch space" for the test suite and is wiped
7 | # and recreated between test runs. Don't rely on the data there!
8 | config.cache_classes = true
9 |
10 | # Do not eager load code on boot. This avoids loading your whole application
11 | # just for the purpose of running a single test. If you are using a tool that
12 | # preloads Rails for running tests, you may have to set it to true.
13 | config.eager_load = false
14 |
15 | # Configure public file server for tests with Cache-Control for performance.
16 | config.public_file_server.enabled = true
17 | config.public_file_server.headers = {
18 | 'Cache-Control' => 'public, max-age=3600'
19 | }
20 |
21 | # Show full error reports and disable caching.
22 | config.consider_all_requests_local = true
23 | config.action_controller.perform_caching = false
24 |
25 | # Raise exceptions instead of rendering exception templates.
26 | config.action_dispatch.show_exceptions = false
27 |
28 | # Disable request forgery protection in test environment.
29 | config.action_controller.allow_forgery_protection = false
30 | config.action_mailer.perform_caching = false
31 |
32 | # Tell Action Mailer not to deliver emails to the real world.
33 | # The :test delivery method accumulates sent emails in the
34 | # ActionMailer::Base.deliveries array.
35 | config.action_mailer.delivery_method = :test
36 |
37 | # Print deprecation notices to the stderr.
38 | config.active_support.deprecation = :stderr
39 |
40 | # Raises error for missing translations
41 | # config.action_view.raise_on_missing_translations = true
42 | end
43 |
--------------------------------------------------------------------------------
/config/initializers/arel.rb:
--------------------------------------------------------------------------------
1 | # app/config/initializers/arel.rb
2 |
3 | require 'arel/nodes/binary'
4 | require 'arel/predications'
5 | require 'arel/visitors/postgresql'
6 |
7 | module Arel
8 | class Nodes::ContainsArray < Arel::Nodes::Binary
9 | def operator
10 | :"@>"
11 | end
12 | end
13 |
14 | class Visitors::PostgreSQL
15 | private
16 |
17 | def visit_Arel_Nodes_ContainsArray(o, collector)
18 | infix_value o, collector, ' @> '
19 | end
20 | end
21 |
22 | module Predications
23 | def contains(other)
24 | Nodes::ContainsArray.new self, Nodes.build_quoted(other, self)
25 | end
26 | end
27 | end
--------------------------------------------------------------------------------
/config/initializers/assets.rb:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 |
3 | # Version of your assets, change this if you want to expire all your assets.
4 | Rails.application.config.assets.version = '1.0'
5 |
6 | # Add additional assets to the asset load path
7 | # Rails.application.config.assets.paths << Emoji.images_path
8 |
9 | Rails.application.config.assets.paths << Rails.root.join("hackathon-config", "assets", "images")
10 | Rails.application.config.assets.paths << Rails.root.join("hackathon-config", "assets", "stylesheets")
11 | Rails.application.config.assets.paths << Rails.root.join("hackathon-config", "assets", "javascripts")
12 |
13 | # Precompile additional assets.
14 | # application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
15 | # Rails.application.config.assets.precompile += %w( search.js )
16 | Rails.application.config.assets.precompile += %w( event_application.js )
17 | # Manually add PNG and CSS files in the custom hackathon-config assets folders
18 | Rails.application.config.assets.precompile += ['*.png']
19 | Rails.application.config.assets.precompile += %w( custom.css custom.js )
20 |
21 |
--------------------------------------------------------------------------------
/config/initializers/cookies_serializer.rb:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 |
3 | # Specify a serializer for the signed and encrypted cookie jars.
4 | # Valid options are :json, :marshal, and :hybrid.
5 | Rails.application.config.action_dispatch.cookies_serializer = :json
6 |
--------------------------------------------------------------------------------
/config/initializers/filter_parameter_logging.rb:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 |
3 | # Configure sensitive parameters which will be filtered from the log file.
4 | Rails.application.config.filter_parameters += [:password]
5 |
--------------------------------------------------------------------------------
/config/initializers/formats_filter.rb:
--------------------------------------------------------------------------------
1 | # frozen_string_literal: true
2 |
3 | # see https://groups.google.com/forum/#!topic/rubyonrails-security/zRNVOUhKHrg
4 |
5 | ActionDispatch::Request.prepend(Module.new do
6 | def formats
7 | super().select do |format|
8 | format.symbol || format.ref == "*/*"
9 | end
10 | end
11 | end)
--------------------------------------------------------------------------------
/config/initializers/new_framework_defaults.rb:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 | #
3 | # This file contains migration options to ease your Rails 5.0 upgrade.
4 | #
5 | # Read the Guide for Upgrading Ruby on Rails for more info on each option.
6 |
7 | # Enable per-form CSRF tokens. Previous versions had false.
8 | Rails.application.config.action_controller.per_form_csrf_tokens = true
9 |
10 | # Enable origin-checking CSRF mitigation. Previous versions had false.
11 | Rails.application.config.action_controller.forgery_protection_origin_check = true
12 |
13 | # Make Ruby 2.4 preserve the timezone of the receiver when calling `to_time`.
14 | # Previous versions had false.
15 | ActiveSupport.to_time_preserves_timezone = true
16 |
17 | # Require `belongs_to` associations by default. Previous versions had false.
18 | Rails.application.config.active_record.belongs_to_required_by_default = true
19 |
20 | # Configure SSL options to enable HSTS with subdomains. Previous versions had false.
21 | Rails.application.config.ssl_options = { hsts: { subdomains: true } }
22 |
--------------------------------------------------------------------------------
/config/initializers/ransack.rb:
--------------------------------------------------------------------------------
1 | # app/config/initializers/ransack.rb
2 |
3 | Ransack.configure do |config|
4 | config.add_predicate 'contains',
5 | arel_predicate: 'contains',
6 | formatter: proc { |v| "{#{v}}" },
7 | validator: proc { |v| v.present? },
8 | type: :string
9 | end
--------------------------------------------------------------------------------
/config/initializers/recaptcha.rb:
--------------------------------------------------------------------------------
1 | Recaptcha.configure do |config|
2 | if ENV['RAILS_ENV'] == 'production'
3 | config.site_key = ENV['RECAPTCHA_SITE_KEY']
4 | config.secret_key = ENV['RECAPTCHA_SECRET_KEY']
5 | else
6 | config.site_key = 'development_site_key'
7 | config.secret_key = 'development_secret_key'
8 | config.skip_verify_env << 'development'
9 | end
10 | end
--------------------------------------------------------------------------------
/config/initializers/session_store.rb:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 |
3 | Rails.application.config.session_store :cookie_store, key: '_hackumass-web_session'
4 |
--------------------------------------------------------------------------------
/config/initializers/wrap_parameters.rb:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 |
3 | # This file contains settings for ActionController::ParamsWrapper which
4 | # is enabled by default.
5 |
6 | # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
7 | ActiveSupport.on_load(:action_controller) do
8 | wrap_parameters format: [:json]
9 | end
10 |
11 | # To enable root element in JSON for ActiveRecord objects.
12 | # ActiveSupport.on_load(:active_record) do
13 | # self.include_root_in_json = true
14 | # end
15 |
--------------------------------------------------------------------------------
/config/locales/en.yml:
--------------------------------------------------------------------------------
1 | # Files in the config/locales directory are used for internationalization
2 | # and are automatically loaded by Rails. If you want to use locales other
3 | # than English, add the necessary files in this directory.
4 | #
5 | # To use the locales, use `I18n.t`:
6 | #
7 | # I18n.t 'hello'
8 | #
9 | # In views, this is aliased to just `t`:
10 | #
11 | # <%= t('hello') %>
12 | #
13 | # To use a different locale, set it with `I18n.locale`:
14 | #
15 | # I18n.locale = :es
16 | #
17 | # This would use the information in config/locales/es.yml.
18 | #
19 | # To learn more, please read the Rails Internationalization guide
20 | # available at http://guides.rubyonrails.org/i18n.html.
21 |
22 | en:
23 | activerecord:
24 | attributes:
25 | event_application:
26 | name: "full name"
27 | email: "email"
28 | phone: "phone number"
29 | age: "age"
30 | gender: "gender"
31 | university: "university"
32 | major: "major"
33 | grad_year: "graduation year"
34 | food_restrictions: "Do you have any food allergies or dietary
35 | restrictions that we should know about?"
36 | t_shirt_size: "t-shirt size"
37 | resume: "resume"
38 | prev_attendance: "Have you been to a hackathon before?"
39 | referral_info: "How did you hear about hackumass?"
40 | future_hardware_suggestion: "What hardware do you want to see at HackUMass VI or future HackUMass?"
41 | education_lvl: "education level"
42 |
--------------------------------------------------------------------------------
/config/secrets.yml:
--------------------------------------------------------------------------------
1 | # Be sure to restart your server when you modify this file.
2 |
3 | # Your secret key is used for verifying the integrity of signed cookies.
4 | # If you change this key, all old signed cookies will become invalid!
5 |
6 | # Make sure the secret is at least 30 characters and all random,
7 | # no regular words or you'll be exposed to dictionary attacks.
8 | # You can use `rails secret` to generate a secure secret key.
9 |
10 | # Make sure the secrets in this file are kept private
11 | # if you're sharing your code publicly.
12 |
13 | development:
14 | secret_key_base: f1077de79cb9bb9ae1188e28154c892e7ecc04bd9a6e0264514bb148f34e28c6caf54d0b5c9388de66fcef04db5485c3672d41c6af4540b9c65fd82aeeb4c358
15 |
16 | test:
17 | secret_key_base: 242f75594ec85a36c32535d6271241f8fb34c66a358104dd9daef5c86afd89eab473a24cc7d10260ca42d54f54aa080cb2bcad71a9bfb25915fa8616469d4b00
18 |
19 | # Do not keep production secrets in the repository,
20 | # instead read values from the environment.
21 | production:
22 | secret_key_base: <%= ENV["SECRET_KEY_BASE"] %>
23 |
24 | slack: SL4CK_T0K3N
--------------------------------------------------------------------------------
/config/spring.rb:
--------------------------------------------------------------------------------
1 | %w(
2 | .ruby-version
3 | .rbenv-vars
4 | tmp/restart.txt
5 | tmp/caching-dev.txt
6 | ).each { |path| Spring.watch(path) }
7 |
--------------------------------------------------------------------------------
/db/application_autocomplete/.~lock.colleges.csv#:
--------------------------------------------------------------------------------
1 | ,grob,grob-Inspiron-7559,13.07.2017 23:51,file:///home/grob/.config/libreoffice/4;
--------------------------------------------------------------------------------
/db/migrate/20170415164547_devise_create_users.rb:
--------------------------------------------------------------------------------
1 | class DeviseCreateUsers < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :users do |t|
4 | ## Basic info
5 | t.string :first_name, null:false
6 | t.string :last_name, null:false
7 |
8 | ## Database authenticatable
9 | t.string :email, null: false, default: ""
10 | t.string :encrypted_password, null: false, default: ""
11 |
12 | ## Recoverable
13 | t.string :reset_password_token
14 | t.datetime :reset_password_sent_at
15 |
16 | ## Rememberable
17 | t.datetime :remember_created_at
18 |
19 | ## Trackable
20 | t.integer :sign_in_count, default: 0, null: false
21 | t.datetime :current_sign_in_at
22 | t.datetime :last_sign_in_at
23 | t.string :current_sign_in_ip
24 | t.string :last_sign_in_ip
25 |
26 | ## Confirmable
27 | # t.string :confirmation_token
28 | # t.datetime :confirmed_at
29 | # t.datetime :confirmation_sent_at
30 | # t.string :unconfirmed_email # Only if using reconfirmable
31 |
32 | ## Lockable
33 | # t.integer :failed_attempts, default: 0, null: false # Only if lock strategy is :failed_attempts
34 | # t.string :unlock_token # Only if unlock strategy is :email or :both
35 | # t.datetime :locked_at
36 |
37 |
38 | t.timestamps null: false
39 | end
40 |
41 | add_index :users, :email, unique: true
42 | add_index :users, :reset_password_token, unique: true
43 | # add_index :users, :confirmation_token, unique: true
44 | # add_index :users, :unlock_token, unique: true
45 | end
46 | end
47 |
--------------------------------------------------------------------------------
/db/migrate/20170416004110_create_event_applications.rb:
--------------------------------------------------------------------------------
1 | class CreateEventApplications < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :event_applications do |t|
4 | t.integer :user_id
5 | t.string :name
6 | t.string :university
7 | t.string :major
8 | t.string :grad_year
9 | t.string :food_restrictions
10 |
11 | t.timestamps
12 | end
13 | end
14 | end
15 |
--------------------------------------------------------------------------------
/db/migrate/20170424014343_create_hardware_items.rb:
--------------------------------------------------------------------------------
1 | class CreateHardwareItems < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :hardware_items do |t|
4 | t.integer :upc
5 | t.string :name
6 | t.string :link
7 | t.string :category
8 | t.integer :count
9 | t.boolean :available
10 |
11 | t.timestamps
12 | end
13 | end
14 | end
15 |
--------------------------------------------------------------------------------
/db/migrate/20170425211535_add_type_to_user.rb:
--------------------------------------------------------------------------------
1 | class AddTypeToUser < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :users, :user_type, :string, :default => 'attendee'
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170427165952_create_hardware_checkouts.rb:
--------------------------------------------------------------------------------
1 | class CreateHardwareCheckouts < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :hardware_checkouts do |t|
4 | t.integer :user_id
5 | t.string :user_email
6 | t.integer :item_id
7 | t.integer :item_upc
8 | t.integer :checked_out_by
9 |
10 | t.timestamps
11 | end
12 | end
13 | end
14 |
--------------------------------------------------------------------------------
/db/migrate/20170512164743_remove_item_upc_from_hardware_checkouts.rb:
--------------------------------------------------------------------------------
1 | class RemoveItemUpcFromHardwareCheckouts < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :hardware_checkouts, :user_email
4 | remove_column :hardware_checkouts, :item_upc
5 | remove_column :hardware_checkouts, :checked_out_by
6 | end
7 | end
8 |
--------------------------------------------------------------------------------
/db/migrate/20170512171123_add_references_to_hardware_checkouts.rb:
--------------------------------------------------------------------------------
1 | class AddReferencesToHardwareCheckouts < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :hardware_checkouts, :user_id
4 | remove_column :hardware_checkouts, :item_id
5 | add_reference :hardware_checkouts, :user, foreign_key: true
6 | add_reference :hardware_checkouts, :hardware_item, foreign_key: true
7 | end
8 | end
9 |
--------------------------------------------------------------------------------
/db/migrate/20170522053550_add_other_text_field_option_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddOtherTextFieldOptionToEventApplications < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :event_applications, :programming_skills_other_field, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170524233707_create_mentorship_requests.rb:
--------------------------------------------------------------------------------
1 | class CreateMentorshipRequests < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :mentorship_requests do |t|
4 | t.integer :user_id
5 | t.integer :mentor_id
6 | t.string :title
7 | t.string :type
8 | t.string :status
9 |
10 | t.timestamps
11 | end
12 | end
13 | end
14 |
--------------------------------------------------------------------------------
/db/migrate/20170525164515_add_type_to_mentorship_requests.rb:
--------------------------------------------------------------------------------
1 | class AddTypeToMentorshipRequests < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :mentorship_requests, :help_type, :string
4 | remove_column :mentorship_requests, :type
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20170531224502_add_urgency_to_mentorship_requests.rb:
--------------------------------------------------------------------------------
1 | class AddUrgencyToMentorshipRequests < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :mentorship_requests, :urgency, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170609212338_renaming_reordering_removing_event_application_variables.rb:
--------------------------------------------------------------------------------
1 | class RenamingReorderingRemovingEventApplicationVariables < ActiveRecord::Migration[5.0]
2 | def change
3 | drop_table :event_applications
4 |
5 | create_table :event_applications do |t|
6 | t.integer :user_id
7 | t.string :application_status, default: 'undecided'
8 | t.string :name
9 | t.string :email
10 | t.string :phone
11 | t.string :age
12 | t.string :sex
13 | t.string :university
14 | t.string :major
15 | t.string :grad_year
16 | t.boolean :food_restrictions
17 | t.text :food_restrictions_info
18 | t.string :t_shirt
19 | t.binary :resume_file
20 | t.string :resume_file_name
21 | t.string :linkedin
22 | t.string :github
23 | t.boolean :previous_hackathon_attendance
24 | t.boolean :transportation
25 | t.string :transportation_location
26 | t.string :programmer_type_list, array:true, default: '{}'
27 | t.string :programming_skills_list, array:true, default: '{}'
28 | t.boolean :interested_in_hardware_hacks, default: false
29 | t.string :interested_hardware_hacks_list, array:true, default: '{}'
30 | t.text :how_did_you_hear_about_hackumass
31 | t.text :future_hardware_for_hackumass
32 | t.boolean :waiver_liability_agreement
33 |
34 | t.timestamps
35 | end
36 | end
37 | end
38 |
--------------------------------------------------------------------------------
/db/migrate/20170614024614_numbers.rb:
--------------------------------------------------------------------------------
1 | class Numbers < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :event_applications, :accepted_applicants, :integer, default: 0
4 | add_column :event_applications, :rejected_applicants, :integer, default: 0
5 | add_column :event_applications, :waitlisted_applicants, :integer, default: 0
6 | end
7 | end
8 |
--------------------------------------------------------------------------------
/db/migrate/20170614025022_number2.rb:
--------------------------------------------------------------------------------
1 | class Number2 < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :event_applications, :accepted_applicants, :integer
4 | remove_column :event_applications, :rejected_applicants, :integer
5 | remove_column :event_applications, :waitlisted_applicants, :integer
6 |
7 | add_column :event_applications, :accepted_applicants, :integer, default: 0
8 | add_column :event_applications, :rejected_applicants, :integer, default: 0
9 | add_column :event_applications, :waitlisted_applicants, :integer, default: 0
10 | end
11 | end
12 |
--------------------------------------------------------------------------------
/db/migrate/20170701032201_remove_programmer_type.rb:
--------------------------------------------------------------------------------
1 | class RemoveProgrammerType < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :event_applications, :programmer_type_list, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170701032834_remove_default_value_in_boolean_value.rb:
--------------------------------------------------------------------------------
1 | class RemoveDefaultValueInBooleanValue < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :event_applications, :interested_in_hardware_hacks, :boolean
4 | add_column :event_applications, :interested_in_hardware_hacks, :boolean
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20170709180501_create_events.rb:
--------------------------------------------------------------------------------
1 | class CreateEvents < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :events do |t|
4 | t.string :title
5 | t.string :description
6 | t.string :location
7 | t.string :time
8 | t.string :created_by
9 | t.string :thumbnail
10 |
11 | t.timestamps
12 | end
13 | end
14 | end
15 |
--------------------------------------------------------------------------------
/db/migrate/20170714015410_create_universities.rb:
--------------------------------------------------------------------------------
1 | class CreateUniversities < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :universities do |t|
4 | t.string :name
5 |
6 | t.timestamps
7 | end
8 | end
9 | end
10 |
--------------------------------------------------------------------------------
/db/migrate/20170714015601_create_majors.rb:
--------------------------------------------------------------------------------
1 | class CreateMajors < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :majors do |t|
4 | t.string :name
5 |
6 | t.timestamps
7 | end
8 | end
9 | end
10 |
--------------------------------------------------------------------------------
/db/migrate/20170719225344_hardware_skills.rb:
--------------------------------------------------------------------------------
1 | class HardwareSkills < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :event_applications, :hardware_skills_list, :string, array:true, default: '{}'
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170722060404_add_flag_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddFlagToEventApplications < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :event_applications, :flag, :boolean, :default => false
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170823144753_remove_thumbnail.rb:
--------------------------------------------------------------------------------
1 | class RemoveThumbnail < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :events, :thumbnail, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20170903192617_change_events_time.rb:
--------------------------------------------------------------------------------
1 | class ChangeEventsTime < ActiveRecord::Migration[5.0]
2 | def change
3 | remove_column :events, :time
4 | add_column :events, :time, :datetime
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20171014030325_add_rsvp_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddRsvpToEventApplications < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :event_applications, :rsvp, :boolean, :default => false
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20171029034814_add_check_in_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddCheckInToEventApplications < ActiveRecord::Migration[5.0]
2 | def change
3 | add_column :event_applications, :check_in, :boolean, default: false
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20171030002802_create_emails.rb:
--------------------------------------------------------------------------------
1 | class CreateEmails < ActiveRecord::Migration[5.0]
2 | def change
3 | create_table :emails do |t|
4 | t.string :subject
5 | t.string :message
6 | t.string :mailing_list
7 | t.string :status
8 | t.string :sent_by
9 |
10 | t.timestamps
11 | end
12 | end
13 | end
14 |
--------------------------------------------------------------------------------
/db/migrate/20180711001332_add_resume_file_size_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddResumeFileSizeToEventApplications < ActiveRecord::Migration[5.1]
2 | def change
3 | add_column :event_applications, :resume_file_size, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20180728205939_create_active_storage_tables.active_storage.rb:
--------------------------------------------------------------------------------
1 | # This migration comes from active_storage (originally 20170806125915)
2 | class CreateActiveStorageTables < ActiveRecord::Migration[5.2]
3 | def change
4 | create_table :active_storage_blobs do |t|
5 | t.string :key, null: false
6 | t.string :filename, null: false
7 | t.string :content_type
8 | t.text :metadata
9 | t.bigint :byte_size, null: false
10 | t.string :checksum, null: false
11 | t.datetime :created_at, null: false
12 |
13 | t.index [ :key ], unique: true
14 | end
15 |
16 | create_table :active_storage_attachments do |t|
17 | t.string :name, null: false
18 | t.references :record, null: false, polymorphic: true, index: false
19 | t.references :blob, null: false
20 |
21 | t.datetime :created_at, null: false
22 |
23 | t.index [ :record_type, :record_id, :name, :blob_id ], name: "index_active_storage_attachments_uniqueness", unique: true
24 | end
25 | end
26 | end
27 |
--------------------------------------------------------------------------------
/db/migrate/20180729035032_remove_old_variables_from_event_application.rb:
--------------------------------------------------------------------------------
1 | class RemoveOldVariablesFromEventApplication < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :event_applications, :rsvp, :boolean
4 | remove_column :event_applications, :check_in, :boolean
5 | remove_column :event_applications, :resume_file_size, :integer
6 | remove_column :event_applications, :email, :string
7 | remove_column :event_applications, :resume_file, :binary
8 | remove_column :event_applications, :resume_file_name, :string
9 | remove_column :event_applications, :interested_in_hardware_hacks, :boolean
10 | remove_column :event_applications, :interested_hardware_hacks_list, :string
11 |
12 | add_column :event_applications, :resume, :binary
13 | end
14 | end
15 |
--------------------------------------------------------------------------------
/db/migrate/20180804035430_clean_up_event_application_table.rb:
--------------------------------------------------------------------------------
1 | class CleanUpEventApplicationTable < ActiveRecord::Migration[5.2]
2 | def change
3 | drop_table :event_applications
4 |
5 | create_table :event_applications do |t|
6 | t.integer :user_id
7 | t.string :status, default: 'undecided'
8 | t.boolean :flag, default: false
9 | t.string :name
10 | t.string :phone
11 | t.string :age
12 | t.string :sex
13 | t.string :university
14 | t.string :major
15 | t.string :grad_year
16 | t.boolean :food_restrictions
17 | t.text :food_restrictions_info
18 | t.binary :resume
19 | t.string :t_shirt_size
20 | t.string :linkedin_url
21 | t.string :github_url
22 | t.boolean :prev_attendance
23 | t.string :programming_skills, array: true, default: '{}'
24 | t.string :hardware_skills, array: true, default: '{}'
25 | t.text :referral_info
26 | t.text :future_hardware_suggestion
27 | t.boolean :waiver_liability_agreement
28 | t.timestamps
29 | end
30 | end
31 | end
32 |
--------------------------------------------------------------------------------
/db/migrate/20180804185413_drop_active_storage.rb:
--------------------------------------------------------------------------------
1 | class DropActiveStorage < ActiveRecord::Migration[5.2]
2 | def change
3 | drop_table :active_storage_attachments
4 | drop_table :active_storage_blobs
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20180807223040_create_feature_flags.rb:
--------------------------------------------------------------------------------
1 | class CreateFeatureFlags < ActiveRecord::Migration[5.1]
2 | def change
3 | create_table :feature_flags do |t|
4 | t.string :name
5 | t.boolean :value
6 |
7 | t.timestamps
8 | end
9 | end
10 | end
11 |
--------------------------------------------------------------------------------
/db/migrate/20180808024842_create_projects.rb:
--------------------------------------------------------------------------------
1 | class CreateProjects < ActiveRecord::Migration[5.1]
2 | def change
3 | create_table :projects do |t|
4 | t.string :title
5 | t.string :description
6 | t.string :link
7 | t.string :team_members
8 |
9 | t.timestamps
10 | end
11 | end
12 | end
13 |
--------------------------------------------------------------------------------
/db/migrate/20180811040748_update_event_application_table.rb:
--------------------------------------------------------------------------------
1 | class UpdateEventApplicationTable < ActiveRecord::Migration[5.2]
2 | def change
3 | drop_table :event_applications
4 |
5 | create_table :event_applications do |t|
6 | t.timestamps
7 | t.integer :user_id
8 | t.string :status, default: 'undecided'
9 | t.boolean :flag, default: false
10 | t.string :name
11 | t.string :phone
12 | t.string :age
13 | t.string :sex
14 | t.string :university
15 | t.string :major
16 | t.string :grad_year
17 | t.boolean :food_restrictions
18 | t.text :food_restrictions_info
19 | t.string :resume_file_name
20 | t.string :resume_content_type
21 | t.integer :resume_file_size
22 | t.datetime :resume_updated_at
23 | t.string :t_shirt_size
24 | t.string :linkedin_url
25 | t.string :github_url
26 | t.boolean :prev_attendance
27 | t.string :programming_skills, array: true, default: '{}'
28 | t.string :hardware_skills, array: true, default: '{}'
29 | t.text :referral_info
30 | t.text :future_hardware_suggestion
31 | t.boolean :waiver_liability_agreement
32 | end
33 | end
34 | end
35 |
--------------------------------------------------------------------------------
/db/migrate/20180818171735_add_user_graduation_year_to_event_application.rb:
--------------------------------------------------------------------------------
1 | class AddUserGraduationYearToEventApplication < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_applications, :education_lvl, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20180905015844_add_user_to_project.rb:
--------------------------------------------------------------------------------
1 | class AddUserToProject < ActiveRecord::Migration[5.2]
2 | def change
3 | add_reference :projects, :user, foreign_key: true
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20180909180945_add_rsv_pand_check_in_to_user.rb:
--------------------------------------------------------------------------------
1 | class AddRsvPandCheckInToUser < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :users, :rsvp, :boolean, default: false
4 | add_column :users, :check_in, :boolean, default: false
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20180909190233_create_prizes.rb:
--------------------------------------------------------------------------------
1 | class CreatePrizes < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :prizes do |t|
4 | t.string :name
5 | t.string :description
6 | t.string :criteria
7 | t.string :sponsor
8 | t.integer :priority
9 |
10 | t.timestamps
11 | end
12 | end
13 | end
14 |
--------------------------------------------------------------------------------
/db/migrate/20180909211902_add_paperclip_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddPaperclipToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :projectimage_file_name, :string
4 | add_column :projects, :projectimage_content_type, :string
5 | add_column :projects, :projectimage_file_size, :integer
6 | add_column :projects, :projectimage_updated_at, :datetime
7 | end
8 | end
9 |
--------------------------------------------------------------------------------
/db/migrate/20180928153649_change_events_fields.rb:
--------------------------------------------------------------------------------
1 | class ChangeEventsFields < ActiveRecord::Migration[5.2]
2 | def change
3 | rename_column :events, :time, :start_time
4 | add_column :events, :end_time, :datetime
5 | add_column :events, :host, :string
6 | end
7 | end
8 |
--------------------------------------------------------------------------------
/db/migrate/20180929224811_add_tech_to_mentorship_requests.rb:
--------------------------------------------------------------------------------
1 | class AddTechToMentorshipRequests < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :mentorship_requests, :description, :string
4 | add_column :mentorship_requests, :tech, :string, array:true, default: '{}'
5 | remove_column :mentorship_requests, :help_type, :string
6 | end
7 | end
8 |
--------------------------------------------------------------------------------
/db/migrate/20180930015740_add_attachment_screenshot_to_mentorship_requests.rb:
--------------------------------------------------------------------------------
1 | class AddAttachmentScreenshotToMentorshipRequests < ActiveRecord::Migration[5.2]
2 | def self.up
3 | change_table :mentorship_requests do |t|
4 | t.attachment :screenshot
5 | end
6 | end
7 |
8 | def self.down
9 | remove_attachment :mentorship_requests, :screenshot
10 | end
11 | end
12 |
--------------------------------------------------------------------------------
/db/migrate/20181004212657_add_new_fields_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddNewFieldsToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :inspiration, :string
4 | add_column :projects, :does_what, :string
5 | add_column :projects, :built_how, :string
6 | add_column :projects, :challenges, :string
7 | add_column :projects, :accomplishments, :string
8 | add_column :projects, :learned, :string
9 | add_column :projects, :next, :string
10 | add_column :projects, :built_with, :string
11 | end
12 | end
13 |
--------------------------------------------------------------------------------
/db/migrate/20181005154209_add_prize_field_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddPrizeFieldToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :prize, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20181011053411_edit_project_fields.rb:
--------------------------------------------------------------------------------
1 | class EditProjectFields < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :prize, :string
4 | add_column :projects, :prizes, :string, array:true, default: '{}'
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20181011233048_add_power_tableid_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddPowerTableidToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :power, :boolean
4 | add_column :projects, :table_id, :integer
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20190721155954_add_display_name_to_feature_flags.rb:
--------------------------------------------------------------------------------
1 | class AddDisplayNameToFeatureFlags < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :feature_flags, :display_name, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190721160412_add_description_to_feature_flags.rb:
--------------------------------------------------------------------------------
1 | class AddDescriptionToFeatureFlags < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :feature_flags, :description, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190726233422_add_mlh_agreement_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddMlhAgreementToEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_applications, :mlh_agreement, :boolean
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190818212050_add_gender_pronoun_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddGenderPronounToEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_applications, :gender, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190818212123_add_pronoun_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddPronounToEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_applications, :pronoun, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190818212159_remove_sex_from_event_applications.rb:
--------------------------------------------------------------------------------
1 | class RemoveSexFromEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :event_applications, :sex, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190818213423_add_custom_fields_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddCustomFieldsToEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_applications, :custom_fields, :json
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190818222059_update_custom_fields_for_event_applications.rb:
--------------------------------------------------------------------------------
1 | class UpdateCustomFieldsForEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | change_column_default(
4 | :event_applications,
5 | :custom_fields,
6 | from: nil,
7 | to: "{}")
8 | end
9 | end
10 |
--------------------------------------------------------------------------------
/db/migrate/20190819205021_modify_default_value_for_custom_fields_in_event_applications.rb:
--------------------------------------------------------------------------------
1 | class ModifyDefaultValueForCustomFieldsInEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | change_column_default(
4 | :event_applications,
5 | :custom_fields,
6 | from: "{}",
7 | to: nil)
8 | end
9 | end
10 |
--------------------------------------------------------------------------------
/db/migrate/20190820044737_delete_unneeded_fields_in_event_applications.rb:
--------------------------------------------------------------------------------
1 | class DeleteUnneededFieldsInEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :event_applications, :linkedin_url, :string
4 | remove_column :event_applications, :github_url, :string
5 | remove_column :event_applications, :prev_attendance, :boolean
6 | remove_column :event_applications, :programming_skills, :string
7 | remove_column :event_applications, :hardware_skills, :string
8 | remove_column :event_applications, :referral_info, :text
9 | remove_column :event_applications, :future_hardware_suggestion, :text
10 | end
11 | end
12 |
--------------------------------------------------------------------------------
/db/migrate/20190908192614_add_project_id_to_users.rb:
--------------------------------------------------------------------------------
1 | class AddProjectIdToUsers < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :users, :project_id, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190909193239_remove_team_members_from_projects.rb:
--------------------------------------------------------------------------------
1 | class RemoveTeamMembersFromProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :team_members, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190909193614_remove_user_id_from_projects.rb:
--------------------------------------------------------------------------------
1 | class RemoveUserIdFromProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :user_id, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20190915231752_create_custom_rsvp.rb:
--------------------------------------------------------------------------------
1 | class CreateCustomRsvp < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :custom_rsvps do |t|
4 | t.json :answers
5 | end
6 | add_reference :custom_rsvps, :user, foreign_key: true
7 | end
8 | end
9 |
--------------------------------------------------------------------------------
/db/migrate/20191003044524_create_event_attendances.rb:
--------------------------------------------------------------------------------
1 | class CreateEventAttendances < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :event_attendances do |t|
4 |
5 | t.timestamps
6 | end
7 | end
8 | end
9 |
--------------------------------------------------------------------------------
/db/migrate/20191003045039_add_max_seats_to_event.rb:
--------------------------------------------------------------------------------
1 | class AddMaxSeatsToEvent < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :events, :max_seats, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191003045056_add_rsvpable_to_event.rb:
--------------------------------------------------------------------------------
1 | class AddRsvpableToEvent < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :events, :rsvpable, :boolean
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191003051058_add_event_id_to_event_attendance.rb:
--------------------------------------------------------------------------------
1 | class AddEventIdToEventAttendance < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_attendances, :event_id, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191003051120_add_user_id_to_event_attendance.rb:
--------------------------------------------------------------------------------
1 | class AddUserIdToEventAttendance < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_attendances, :user_id, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191003200336_add_slack_to_user.rb:
--------------------------------------------------------------------------------
1 | class AddSlackToUser < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :users, :slack, :boolean
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191003222330_remove_slack_from_user.rb:
--------------------------------------------------------------------------------
1 | class RemoveSlackFromUser < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :users, :slack
4 | add_column :users, :slack_id, :string, null: true
5 | add_column :users, :slack_username, :string, null: true
6 | end
7 | end
8 |
--------------------------------------------------------------------------------
/db/migrate/20191004004936_delete_slack_username_from_user.rb:
--------------------------------------------------------------------------------
1 | class DeleteSlackUsernameFromUser < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :users, :slack_username
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191010222403_add_checked_in_to_event_attendance.rb:
--------------------------------------------------------------------------------
1 | class AddCheckedInToEventAttendance < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_attendances, :checked_in, :boolean
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191013175841_add_youtube_link_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddYoutubeLinkToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :youtube_link, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191013190410_add_tech_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddTechToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :tech, :string, array:true, default: '{}'
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191013192723_update_tech_in_projects.rb:
--------------------------------------------------------------------------------
1 | class UpdateTechInProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :tech
4 | add_column :projects, :tech, :json, default: '{}'
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20191013193206_update_tech_default_in_projects.rb:
--------------------------------------------------------------------------------
1 | class UpdateTechDefaultInProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | change_column_default(
4 | :projects,
5 | :tech,
6 | from: "{}",
7 | to: [])
8 | end
9 | end
10 |
--------------------------------------------------------------------------------
/db/migrate/20191013200730_add_prizes_won_to_projects.rb:
--------------------------------------------------------------------------------
1 | class AddPrizesWonToProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :projects, :prizes_won, :json, default: []
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191013201513_add_project_selectable_to_prizes.rb:
--------------------------------------------------------------------------------
1 | class AddProjectSelectableToPrizes < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :prizes, :project_selectable, :boolean, default: true
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191013203003_update_prizes_in_projects.rb:
--------------------------------------------------------------------------------
1 | class UpdatePrizesInProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :prizes
4 | add_column :projects, :prizes, :json, array: true, default: []
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20191013204218_update_prizes_array_in_projects.rb:
--------------------------------------------------------------------------------
1 | class UpdatePrizesArrayInProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | #change_column :projects, :prizes, :json, array: true, default: []
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191013204303_update_prizes_won_array_in_projects.rb:
--------------------------------------------------------------------------------
1 | class UpdatePrizesWonArrayInProjects < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :prizes_won
4 | add_column :projects, :prizes_won, :json, array: true, default: []
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20191014004914_create_hardware_checkout_logs.rb:
--------------------------------------------------------------------------------
1 | class CreateHardwareCheckoutLogs < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :hardware_checkout_logs do |t|
4 | t.references :user, foreign_key: true
5 | t.references :hardware_item, foreign_key: true
6 | t.string :action
7 |
8 | t.timestamps
9 | end
10 | end
11 | end
12 |
--------------------------------------------------------------------------------
/db/migrate/20191014005345_add_message_to_hardware_checkout_logs.rb:
--------------------------------------------------------------------------------
1 | class AddMessageToHardwareCheckoutLogs < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :hardware_checkout_logs, :message, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20191017194803_fix_defaults.rb:
--------------------------------------------------------------------------------
1 | class FixDefaults < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_column :projects, :tech
4 | remove_column :projects, :prizes
5 | remove_column :projects, :prizes_won
6 | add_column :projects, :tech, :json, array: true, default: []
7 | add_column :projects, :prizes, :json, array: true, default: []
8 | add_column :projects, :prizes_won, :json, array: true, default: []
9 | end
10 | end
11 |
--------------------------------------------------------------------------------
/db/migrate/20191018035814_create_mentorship_notifications.rb:
--------------------------------------------------------------------------------
1 | class CreateMentorshipNotifications < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :mentorship_notifications do |t|
4 | t.references :user, foreign_key: true
5 | t.json :tech, array: true, default: []
6 | t.boolean :all
7 |
8 | t.timestamps
9 | end
10 | end
11 | end
12 |
--------------------------------------------------------------------------------
/db/migrate/20200109051747_add_location_to_hardware_items.rb:
--------------------------------------------------------------------------------
1 | class AddLocationToHardwareItems < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :hardware_items, :location, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200112194204_create_judgements.rb:
--------------------------------------------------------------------------------
1 | class CreateJudgements < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :judgements do |t|
4 |
5 | t.timestamps
6 | end
7 | end
8 | end
9 |
--------------------------------------------------------------------------------
/db/migrate/20200112194527_add_score_to_judgement.rb:
--------------------------------------------------------------------------------
1 | class AddScoreToJudgement < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :judgements, :score, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200112203807_add_user_id_to_judgements.rb:
--------------------------------------------------------------------------------
1 | class AddUserIdToJudgements < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :judgements, :user_id, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200112204046_add_project_id_to_judgements.rb:
--------------------------------------------------------------------------------
1 | class AddProjectIdToJudgements < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :judgements, :project_id, :integer
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200112210254_set_default_score.rb:
--------------------------------------------------------------------------------
1 | class SetDefaultScore < ActiveRecord::Migration[5.2]
2 | def change
3 | change_column :judgements, :score, :integer, default: -1
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200117234839_create_judging_assignments.rb:
--------------------------------------------------------------------------------
1 | class CreateJudgingAssignments < ActiveRecord::Migration[5.2]
2 | def change
3 | create_table :judging_assignments do |t|
4 | t.integer :user_id
5 | t.integer :project_id
6 | end
7 | end
8 | end
9 |
--------------------------------------------------------------------------------
/db/migrate/20200121200442_update_judge_assignment_primary_key.rb:
--------------------------------------------------------------------------------
1 | class UpdateJudgeAssignmentPrimaryKey < ActiveRecord::Migration[5.2]
2 | def change
3 | add_index :judging_assignments, ["user_id", "project_id"], :unique => true
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200126000717_add_custom_scores_to_judgements.rb:
--------------------------------------------------------------------------------
1 | class AddCustomScoresToJudgements < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :judgements, :custom_scores, :json
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200126192626_add_tag_to_judging_assignments.rb:
--------------------------------------------------------------------------------
1 | class AddTagToJudgingAssignments < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :judging_assignments, :tag, :string, :null => true
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200126193225_add_tag_to_judgements.rb:
--------------------------------------------------------------------------------
1 | class AddTagToJudgements < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :judgements, :tag, :string, :null => true
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20200126201720_update_assignment_index.rb:
--------------------------------------------------------------------------------
1 | class UpdateAssignmentIndex < ActiveRecord::Migration[5.2]
2 | def change
3 | remove_index :judging_assignments, name: "index_judging_assignments_on_user_id_and_project_id"
4 | add_index :judging_assignments, ["user_id", "project_id", "tag"], :unique => true
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20200128031347_update_custom_scores_to_judgements.rb:
--------------------------------------------------------------------------------
1 | class UpdateCustomScoresToJudgements < ActiveRecord::Migration[5.2]
2 | def change
3 | change_column_default(
4 | :judgements,
5 | :custom_scores,
6 | from: nil,
7 | to: "{}")
8 | end
9 | end
10 |
--------------------------------------------------------------------------------
/db/migrate/20200206212235_devise_token_auth_edit_users.rb:
--------------------------------------------------------------------------------
1 | class DeviseTokenAuthEditUsers < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :users, :provider, :string, :null => false, :default => "email"
4 | change_table(:users) do |t|
5 | t.string :uid, :null => false, :default => ""
6 |
7 | ## Tokens
8 | t.json :tokens
9 | end
10 | end
11 | end
--------------------------------------------------------------------------------
/db/migrate/20200618042555_add_confirmable_to_devise.rb:
--------------------------------------------------------------------------------
1 | class AddConfirmableToDevise < ActiveRecord::Migration[5.2]
2 | def up
3 | add_column :users, :confirmation_token, :string
4 | add_column :users, :confirmed_at, :datetime
5 | add_column :users, :confirmation_sent_at, :datetime
6 | add_index :users, :confirmation_token, unique: true
7 | User.update_all confirmed_at: DateTime.now
8 | end
9 |
10 | def down
11 | remove_columns :users, :confirmation_token, :confirmed_at, :confirmation_sent_at
12 | end
13 | end
14 |
--------------------------------------------------------------------------------
/db/migrate/20221013150340_add_mlh_communications_to_event_applications.rb:
--------------------------------------------------------------------------------
1 | class AddMlhCommunicationsToEventApplications < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :event_applications, :mlh_communications, :boolean
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20221102014907_change_upc_to_uid.rb:
--------------------------------------------------------------------------------
1 | class ChangeUpcToUid < ActiveRecord::Migration[5.2]
2 | def change
3 | rename_column :hardware_items, :upc, :uid
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20221109013144_change_uid_to_string_in_hardware_items.rb:
--------------------------------------------------------------------------------
1 | class ChangeUidToStringInHardwareItems < ActiveRecord::Migration[5.2]
2 | def change
3 | change_column :hardware_items, :uid, :string
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20231002032542_rename_prize_model_fields.rb:
--------------------------------------------------------------------------------
1 | class RenamePrizeModelFields < ActiveRecord::Migration[5.2]
2 | def change
3 | rename_column :prizes, :name, :award
4 | rename_column :prizes, :criteria, :title
5 | end
6 | end
7 |
--------------------------------------------------------------------------------
/db/migrate/20231008213425_add_consent_to_marketing_emails_to_users.rb:
--------------------------------------------------------------------------------
1 | class AddConsentToMarketingEmailsToUsers < ActiveRecord::Migration[5.2]
2 | def change
3 | add_column :users, :emailMarketingConsent, :boolean, default: false
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20231008224238_rename_email_marketing_consent_to_match_naming_convention.rb:
--------------------------------------------------------------------------------
1 | class RenameEmailMarketingConsentToMatchNamingConvention < ActiveRecord::Migration[5.2]
2 | def change
3 | rename_column :users, :emailMarketingConsent, :email_marketing_consent
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/db/migrate/20231009025205_rename_email_marketing_consent_to_non_transactional_email_consent.rb:
--------------------------------------------------------------------------------
1 | class RenameEmailMarketingConsentToNonTransactionalEmailConsent < ActiveRecord::Migration[5.2]
2 | def change
3 | rename_column :users, :email_marketing_consent, :non_transactional_email_consent
4 | end
5 | end
6 |
--------------------------------------------------------------------------------
/docker-compose.yml:
--------------------------------------------------------------------------------
1 | version: "2.4"
2 | services:
3 | postgres:
4 | image: postgres:12
5 | environment:
6 | - POSTGRES_USER=dashboard
7 | - POSTGRES_PASSWORD=dashboardpass
8 | volumes:
9 | - ./db/postgres:/var/lib/postgresql/data
10 | healthcheck:
11 | test: ["CMD-SHELL", "pg_isready -U dashboard"]
12 | interval: 5s
13 | timeout: 5s
14 | retries: 5
15 | rails:
16 | build:
17 | context: .
18 | dockerfile: docker/Dockerfile
19 | depends_on:
20 | postgres:
21 | condition: service_healthy
22 | links:
23 | - postgres
24 | volumes:
25 | - ./:/usr/src/app
26 | ports:
27 | - "3000:3000"
28 |
--------------------------------------------------------------------------------
/docker/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM ruby:2.5
2 |
3 | # Installs dependencies to run Rails on the ruby:2.5 image
4 | RUN apt-get update && apt-get install -y \
5 | build-essential \
6 | nodejs \
7 | postgresql-client
8 |
9 | # Configure the main working directory
10 | WORKDIR /usr/src/app
11 |
12 | # Copies the Gemfile and Gemfile.lock to the main working directory
13 | COPY Gemfile Gemfile.lock ./
14 |
15 | # Installs gems listed in the Gemfile.lock
16 | RUN bundle install
17 |
18 | # Copies the main application to run install dependencies and rake files
19 | COPY . .
20 |
21 | # Exposes the 3000 port to access it outside of the image
22 | EXPOSE 3000
23 |
24 | # Default command that runs when the container starts
25 | CMD ["bash", "docker/docker_set_up.sh"]
--------------------------------------------------------------------------------
/docker/docker_run.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 | docker-compose run -v `pwd`:/usr/src/app -p 3000:3000 rails "$@"
--------------------------------------------------------------------------------
/docker/docker_set_up.sh:
--------------------------------------------------------------------------------
1 | # Work around for the pesky "server is already running bug"
2 | rm tmp/pids/server.pid
3 |
4 | if [ \( ! -f "db/postgres/.built" \) ]; then
5 | echo Development db or test db does not exist. Running initial setup... &&
6 | bundle exec rake db:create &&
7 | bundle exec rake db:migrate &&
8 | bundle exec rake db:setup &&
9 | bundle exec rake feature_flags:load_flags
10 | touch db/postgres/.built
11 | fi
12 |
13 | bundle exec rails server -b 0.0.0.0
--------------------------------------------------------------------------------
/docker_shell.sh:
--------------------------------------------------------------------------------
1 | CURR_DIR="${PWD##*/}"
2 |
3 | RUNNING_ID="docker ps --format '{{.ID}}' -f 'ancestor=${CURR_DIR}-rails'"
4 | if [[ "$RUNNING_ID" == "" ]]; then
5 | echo Running new container instance
6 | ./docker/docker_run.sh ${@:-/bin/bash}
7 | else
8 | echo Connecting to running container instance
9 | docker-compose exec rails ${@:-/bin/bash}
10 | fi
11 |
--------------------------------------------------------------------------------
/lib/assets/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/lib/assets/.keep
--------------------------------------------------------------------------------
/lib/tasks/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/lib/tasks/.keep
--------------------------------------------------------------------------------
/lib/tasks/admissions.rake:
--------------------------------------------------------------------------------
1 | namespace :admissions do
2 | desc "Accept or flag student applications"
3 | task :update_apps, [:newFlag, :flag] => :environment do |t, args|
4 |
5 | list_of_apps = EventApplication.where(:status => args[:flag])
6 | flagged_count = 0
7 | accepted_count = 0
8 |
9 | list_of_apps.each do |app|
10 |
11 | app.status = args[:newFlag]
12 | app.save(:validate => false)
13 | accepted_count += 1
14 | UserMailer.accepted_email(app.user).deliver_now
15 |
16 | end #End of event application check
17 |
18 |
19 | puts "Flagged Applications: #{flagged_count}"
20 | puts "Accepted Applications: #{accepted_count}"
21 | puts "Total Applications Considered: #{flagged_count+accepted_count}"
22 | end
23 |
24 | desc "Accept or flag student applications using csv"
25 | task :update_apps_file, [:newFlag, :file] => :environment do |t, args|
26 |
27 | flagged_count = 0
28 | accepted_count = 0
29 |
30 | emailList = File.read(args[:file]).split(",").map(&:strip)
31 |
32 | emailList.each do |email|
33 | list_of_apps = EventApplication.joins(:user).where("users.email = '#{email}'")
34 | list_of_apps.each do |app|
35 | app.status = args[:newFlag]
36 | app.save(:validate => false)
37 | accepted_count += 1
38 | UserMailer.accepted_email(app.user).deliver_now
39 |
40 | end #End of event application check
41 | end
42 |
43 | puts "Flagged Applications: #{flagged_count}"
44 | puts "Accepted Applications: #{accepted_count}"
45 | puts "Total Applications Considered: #{flagged_count+accepted_count}"
46 | end
47 |
48 | end
49 |
--------------------------------------------------------------------------------
/lib/tasks/autocomplete.rake:
--------------------------------------------------------------------------------
1 | require 'csv'
2 |
3 | namespace :application do
4 | desc 'Import CSV Data from Majors & Universities to Import'
5 | task :autocomplete => :environment do
6 |
7 | # Import data for
8 | Major.delete_all
9 | csv_file_path = 'db/application_autocomplete/majors-list.csv'
10 | CSV.foreach(csv_file_path, encoding: 'iso-8859-1:utf-8') do |row|
11 | Major.create!({
12 | :name => row[1]
13 | })
14 | puts row[1] + " added!"
15 | end
16 |
17 | # Import data for university dropdown
18 | University.delete_all
19 | csv_file_path = 'db/application_autocomplete/colleges.csv'
20 | CSV.foreach(csv_file_path, encoding: 'iso-8859-1:utf-8') do |row|
21 | University.create!({
22 | :name => row[1]
23 | })
24 | puts row[1] + " added!"
25 | end
26 |
27 | end
28 | end
29 |
--------------------------------------------------------------------------------
/lib/tasks/csv.rake:
--------------------------------------------------------------------------------
1 | namespace :csv do
2 | desc ""
3 | task rsvp: :environment do
4 | require 'csv'
5 | CSV.open("rsvp.csv", "w") do |csv|
6 | @all_applications = EventApplication.select(:name, :email, :university).where({rsvp: true})
7 | csv << ['Applicant Name', 'Email', 'Univeristy']
8 | @all_applications.each do |applicant|
9 | csv << [applicant.name, applicant.email, applicant.university]
10 | end
11 | end
12 | end
13 |
14 | end
15 |
--------------------------------------------------------------------------------
/lib/tasks/db_clean.rake:
--------------------------------------------------------------------------------
1 | namespace :application do
2 | desc 'Clean Database'
3 | task :db_clean => :environment do
4 |
5 | # Delete all users
6 | puts "Deleting all users..."
7 | User.delete_all
8 |
9 | # Delete all event applications
10 | puts "Deleting all event applications..."
11 | EventApplication.delete_all
12 |
13 | # Delete all prizes
14 | puts "Deleting all prizes..."
15 | Prize.delete_all
16 |
17 | # Delete all projects
18 | puts "Deleting all projects..."
19 | Project.delete_all
20 |
21 | end
22 | end
--------------------------------------------------------------------------------
/lib/tasks/load_events.rake:
--------------------------------------------------------------------------------
1 | require 'csv'
2 | namespace :event do
3 | desc 'Import all the Events from CSV'
4 | task :create, [:var] => :environment do |task, args|
5 |
6 | # To pass the right argument for the rake command, refer to the sample command:
7 | # sudo ./docker_shell rake event:create[lib/tasks/sample_events_data.csv]
8 | # You may chose to edit the sample CSV or pass in a different location of your CSV file within the brackets
9 |
10 | events = []
11 | if args.var.nil?
12 | puts("No Arguments Received")
13 | else
14 | csvPath = args.var
15 | header = true
16 |
17 | CSV.foreach(csvPath) do |row|
18 | if header == true
19 | header = false
20 | else
21 | newEvent = Event.new(
22 | {
23 | title: row[0],
24 | description: row[1],
25 | location: row[2],
26 | host: row[3],
27 | start_time: row[4],
28 | end_time:row[5],
29 | rsvpable:row[6],
30 | max_seats:row[7]
31 | })
32 | events.push(newEvent)
33 |
34 | end
35 | end
36 |
37 | events.each do |item|
38 | item.save
39 | end
40 |
41 | end
42 |
43 | end
44 |
45 | end
--------------------------------------------------------------------------------
/lib/tasks/load_hardware.rake:
--------------------------------------------------------------------------------
1 | require 'csv'
2 | namespace :hardware do
3 | desc 'Create all the hardware items'
4 | task :create, [:var] => :environment do |task, args|
5 |
6 | # To pass the right argument for the rake command, refer to the sample command:
7 | # sudo ./docker_shell rake hardware:create[lib/tasks/sample_hardware_data.csv]
8 | # You may chose to edit the sample CSV or pass in a different location of your CSV file within the brackets
9 |
10 | hardware_items = []
11 | if args.var.nil?
12 | puts("No Arguments Received")
13 | else
14 | csvPath = args.var
15 | header = true
16 |
17 | CSV.foreach(csvPath) do |row|
18 | if header == true
19 | header = false
20 | else
21 | item = HardwareItem.new(
22 | {
23 | uid: row[0],
24 | name: row[1],
25 | count: row[2],
26 | category: row[3],
27 | location: row[4]
28 | })
29 | hardware_items.push(item)
30 |
31 | end
32 | end
33 |
34 | hardware_items.each do |item|
35 | item.save
36 | end
37 |
38 | end
39 |
40 | end
41 |
42 | end
--------------------------------------------------------------------------------
/lib/tasks/reminder.rake:
--------------------------------------------------------------------------------
1 | namespace :reminder do
2 | desc "reminder email to all applicants that they haven't finish their
3 | application and the deadline is coming up"
4 |
5 |
6 | task :send_email => :environment do
7 |
8 | @users = User.all
9 | count = 0
10 |
11 | @users.each do |user|
12 | if user.has_applied? == false
13 | UserMailer.reminder_email(user,'Applications are closing soon!', "It looks like you haven’t submitted your application yet! The deadline for #{HackumassWeb::Application::HACKATHON_NAME} #{HackumassWeb::Application::HACKATHON_VERSION} is September 24th, so if you’re still interested in being part of the largest hackathon in Western Mass, please submit your application soon. We hope to see you this fall~").deliver_now
14 | count += 1
15 | end
16 | end
17 |
18 | puts "#{count} emails sent succesfully!"
19 |
20 | end
21 |
22 | end
23 |
--------------------------------------------------------------------------------
/lib/tasks/sample_events_data.csv:
--------------------------------------------------------------------------------
1 | title ,description,location ,host,start_time,end_time,RSVP?,max_seats
2 | Mentoring,Mentoring people,ILC,RedPandaHacks,"Wed, 22 Jan 2020 19:21:30","Wed, 22 Jan 2020 19:22:30",TRUE,10
3 |
--------------------------------------------------------------------------------
/lib/tasks/sample_hardware_data.csv:
--------------------------------------------------------------------------------
1 | uid,name,count,category,location
2 | 895632742,Arduino Uno,15,Microcontrollers,Bin 12
3 | 397464010,Intel Edison,3,Microcontrollers,Bin 11
4 |
--------------------------------------------------------------------------------
/lib/tasks/template_email.rake:
--------------------------------------------------------------------------------
1 | namespace :template_email do
2 |
3 | task :send => :environment do
4 | email_count = 0
5 |
6 | # all_checkouts = HardwareCheckout.all
7 | # all_checkouts.each do |checkout|
8 | # if checkout.user.has_slack? == false
9 | # UserMailer.template_email(user, 'URGENT Slack Needed For Hardware').deliver_now
10 | # email_count++
11 | # end
12 | # end
13 | # puts "Emails sent: #{email_count}"
14 | end
15 |
16 | end
17 |
--------------------------------------------------------------------------------
/log/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/log/.keep
--------------------------------------------------------------------------------
/output.csv:
--------------------------------------------------------------------------------
1 | name, resume_file_name, education_lvl
--------------------------------------------------------------------------------
/public/404.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | The page you were looking for doesn't exist (404)
5 |
6 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
Hey there! It seems like the page you were looking for doesn't exist.
62 |
You may have mistyped the address or the page may have moved.
63 |
64 |
Go back to safety!
65 |
66 |
67 |
68 |
--------------------------------------------------------------------------------
/public/422.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | We're sorry, but something went wrong (422)
5 |
6 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
Opppsssss! We're sorry, but something went wrong.
62 |
63 |
We are so sorry this happened! Do you want to Go back to safety!
64 |
65 |
66 |
67 |
--------------------------------------------------------------------------------
/public/500.html.erb:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | We're sorry, but something went wrong (500)
5 |
6 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
Opppsssss! We're sorry, but something went wrong.
62 |
63 |
We are so sorry this happened! Do you want to Go back to safety!
64 |
65 |
66 |
67 |
--------------------------------------------------------------------------------
/public/apple-touch-icon-precomposed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/public/apple-touch-icon-precomposed.png
--------------------------------------------------------------------------------
/public/apple-touch-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/public/apple-touch-icon.png
--------------------------------------------------------------------------------
/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/public/favicon.ico
--------------------------------------------------------------------------------
/public/judging/judging.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/public/judging/judging.pdf
--------------------------------------------------------------------------------
/public/robots.txt:
--------------------------------------------------------------------------------
1 | # See http://www.robotstxt.org/robotstxt.html for documentation on how to use the robots.txt file
2 | #
3 | # To ban all spiders from the entire site uncomment the next two lines:
4 | User-agent: *
5 | Allow: /
6 |
--------------------------------------------------------------------------------
/resume_urls.csv:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/resume_urls.csv
--------------------------------------------------------------------------------
/test/controllers/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/controllers/.keep
--------------------------------------------------------------------------------
/test/controllers/custom_rsvp_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class CustomRsvpControllerTest < ActionDispatch::IntegrationTest
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/controllers/emails_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EmailsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @email = emails(:one)
6 | end
7 |
8 | test "should get index" do
9 | get emails_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_email_url
15 | assert_response :success
16 | end
17 |
18 | test "should create email" do
19 | assert_difference('Email.count') do
20 | post emails_url, params: { email: { mailing_list: @email.mailing_list, message: @email.message, sent_by: @email.sent_by, status: @email.status, subject: @email.subject } }
21 | end
22 |
23 | assert_redirected_to email_url(Email.last)
24 | end
25 |
26 | test "should show email" do
27 | get email_url(@email)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_email_url(@email)
33 | assert_response :success
34 | end
35 |
36 | test "should update email" do
37 | patch email_url(@email), params: { email: { mailing_list: @email.mailing_list, message: @email.message, sent_by: @email.sent_by, status: @email.status, subject: @email.subject } }
38 | assert_redirected_to email_url(@email)
39 | end
40 |
41 | test "should destroy email" do
42 | assert_difference('Email.count', -1) do
43 | delete email_url(@email)
44 | end
45 |
46 | assert_redirected_to emails_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/event_applications_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EventApplicationsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @event_application = event_applications(:one)
6 | end
7 |
8 | test "should get index" do
9 | get event_applications_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_event_application_url
15 | assert_response :success
16 | end
17 |
18 | test "should create event_application" do
19 | assert_difference('EventApplication.count') do
20 | post event_applications_url, params: { event_application: { food_restrictions: @event_application.food_restrictions, grad_year: @event_application.grad_year, major: @event_application.major, name: @event_application.name, university: @event_application.university, user_id: @event_application.user_id } }
21 | end
22 |
23 | assert_redirected_to event_application_url(EventApplication.last)
24 | end
25 |
26 | test "should show event_application" do
27 | get event_application_url(@event_application)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_event_application_url(@event_application)
33 | assert_response :success
34 | end
35 |
36 | test "should update event_application" do
37 | patch event_application_url(@event_application), params: { event_application: { food_restrictions: @event_application.food_restrictions, grad_year: @event_application.grad_year, major: @event_application.major, name: @event_application.name, university: @event_application.university, user_id: @event_application.user_id } }
38 | assert_redirected_to event_application_url(@event_application)
39 | end
40 |
41 | test "should destroy event_application" do
42 | assert_difference('EventApplication.count', -1) do
43 | delete event_application_url(@event_application)
44 | end
45 |
46 | assert_redirected_to event_applications_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/event_attendance_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EventAttendanceControllerTest < ActionDispatch::IntegrationTest
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/controllers/events_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EventsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @event = events(:one)
6 | end
7 |
8 | test "should get index" do
9 | get events_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_event_url
15 | assert_response :success
16 | end
17 |
18 | test "should create event" do
19 | assert_difference('Event.count') do
20 | post events_url, params: { event: { created_by: @event.created_by, description: @event.description, location: @event.location, thumbnail: @event.thumbnail, time: @event.time, title: @event.title } }
21 | end
22 |
23 | assert_redirected_to event_url(Event.last)
24 | end
25 |
26 | test "should show event" do
27 | get event_url(@event)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_event_url(@event)
33 | assert_response :success
34 | end
35 |
36 | test "should update event" do
37 | patch event_url(@event), params: { event: { created_by: @event.created_by, description: @event.description, location: @event.location, thumbnail: @event.thumbnail, time: @event.time, title: @event.title } }
38 | assert_redirected_to event_url(@event)
39 | end
40 |
41 | test "should destroy event" do
42 | assert_difference('Event.count', -1) do
43 | delete event_url(@event)
44 | end
45 |
46 | assert_redirected_to events_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/hardware_checkouts_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class HardwareCheckoutsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @hardware_checkout = hardware_checkouts(:one)
6 | end
7 |
8 | test "should get index" do
9 | get hardware_checkouts_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_hardware_checkout_url
15 | assert_response :success
16 | end
17 |
18 | test "should create hardware_checkout" do
19 | assert_difference('HardwareCheckout.count') do
20 | post hardware_checkouts_url, params: { hardware_checkout: { checked_out_by: @hardware_checkout.checked_out_by, item_id: @hardware_checkout.item_id, item_upc: @hardware_checkout.item_upc, user_email: @hardware_checkout.user_email, user_id: @hardware_checkout.user_id } }
21 | end
22 |
23 | assert_redirected_to hardware_checkout_url(HardwareCheckout.last)
24 | end
25 |
26 | test "should show hardware_checkout" do
27 | get hardware_checkout_url(@hardware_checkout)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_hardware_checkout_url(@hardware_checkout)
33 | assert_response :success
34 | end
35 |
36 | test "should update hardware_checkout" do
37 | patch hardware_checkout_url(@hardware_checkout), params: { hardware_checkout: { checked_out_by: @hardware_checkout.checked_out_by, item_id: @hardware_checkout.item_id, item_upc: @hardware_checkout.item_upc, user_email: @hardware_checkout.user_email, user_id: @hardware_checkout.user_id } }
38 | assert_redirected_to hardware_checkout_url(@hardware_checkout)
39 | end
40 |
41 | test "should destroy hardware_checkout" do
42 | assert_difference('HardwareCheckout.count', -1) do
43 | delete hardware_checkout_url(@hardware_checkout)
44 | end
45 |
46 | assert_redirected_to hardware_checkouts_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/hardware_items_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class HardwareItemsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @hardware_item = hardware_items(:one)
6 | end
7 |
8 | test "should get index" do
9 | get hardware_items_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_hardware_item_url
15 | assert_response :success
16 | end
17 |
18 | test "should create hardware_item" do
19 | assert_difference('HardwareItem.count') do
20 | post hardware_items_url, params: { hardware_item: { available: @hardware_item.available, category: @hardware_item.category, count: @hardware_item.count, link: @hardware_item.link, name: @hardware_item.name, uid: @hardware_item.uid } }
21 | end
22 |
23 | assert_redirected_to hardware_item_url(HardwareItem.last)
24 | end
25 |
26 | test "should show hardware_item" do
27 | get hardware_item_url(@hardware_item)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_hardware_item_url(@hardware_item)
33 | assert_response :success
34 | end
35 |
36 | test "should update hardware_item" do
37 | patch hardware_item_url(@hardware_item), params: { hardware_item: { available: @hardware_item.available, category: @hardware_item.category, count: @hardware_item.count, link: @hardware_item.link, name: @hardware_item.name, uid: @hardware_item.uid } }
38 | assert_redirected_to hardware_item_url(@hardware_item)
39 | end
40 |
41 | test "should destroy hardware_item" do
42 | assert_difference('HardwareItem.count', -1) do
43 | delete hardware_item_url(@hardware_item)
44 | end
45 |
46 | assert_redirected_to hardware_items_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/judging_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class JudgingControllerTest < ActionDispatch::IntegrationTest
4 | test "should get new" do
5 | get judging_new_url
6 | assert_response :success
7 | end
8 |
9 | test "should get create" do
10 | get judging_create_url
11 | assert_response :success
12 | end
13 |
14 | test "should get show" do
15 | get judging_show_url
16 | assert_response :success
17 | end
18 |
19 | test "should get edit" do
20 | get judging_edit_url
21 | assert_response :success
22 | end
23 |
24 | test "should get update" do
25 | get judging_update_url
26 | assert_response :success
27 | end
28 |
29 | test "should get destroy" do
30 | get judging_destroy_url
31 | assert_response :success
32 | end
33 |
34 | end
35 |
--------------------------------------------------------------------------------
/test/controllers/mentorship_notifications_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class MentorshipNotificationsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @mentorship_notification = mentorship_notifications(:one)
6 | end
7 |
8 | test "should get index" do
9 | get mentorship_notifications_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_mentorship_notification_url
15 | assert_response :success
16 | end
17 |
18 | test "should create mentorship_notification" do
19 | assert_difference('MentorshipNotification.count') do
20 | post mentorship_notifications_url, params: { mentorship_notification: { all: @mentorship_notification.all, tech: @mentorship_notification.tech, user_id: @mentorship_notification.user_id } }
21 | end
22 |
23 | assert_redirected_to mentorship_notification_url(MentorshipNotification.last)
24 | end
25 |
26 | test "should show mentorship_notification" do
27 | get mentorship_notification_url(@mentorship_notification)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_mentorship_notification_url(@mentorship_notification)
33 | assert_response :success
34 | end
35 |
36 | test "should update mentorship_notification" do
37 | patch mentorship_notification_url(@mentorship_notification), params: { mentorship_notification: { all: @mentorship_notification.all, tech: @mentorship_notification.tech, user_id: @mentorship_notification.user_id } }
38 | assert_redirected_to mentorship_notification_url(@mentorship_notification)
39 | end
40 |
41 | test "should destroy mentorship_notification" do
42 | assert_difference('MentorshipNotification.count', -1) do
43 | delete mentorship_notification_url(@mentorship_notification)
44 | end
45 |
46 | assert_redirected_to mentorship_notifications_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/mentorship_requests_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class MentorshipRequestsControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @mentorship_request = mentorship_requests(:one)
6 | end
7 |
8 | test "should get index" do
9 | get mentorship_requests_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_mentorship_request_url
15 | assert_response :success
16 | end
17 |
18 | test "should create mentorship_request" do
19 | assert_difference('MentorshipRequest.count') do
20 | post mentorship_requests_url, params: { mentorship_request: { mentor_id: @mentorship_request.mentor_id, status: @mentorship_request.status, title: @mentorship_request.title, type: @mentorship_request.type, user_id: @mentorship_request.user_id } }
21 | end
22 |
23 | assert_redirected_to mentorship_request_url(MentorshipRequest.last)
24 | end
25 |
26 | test "should show mentorship_request" do
27 | get mentorship_request_url(@mentorship_request)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_mentorship_request_url(@mentorship_request)
33 | assert_response :success
34 | end
35 |
36 | test "should update mentorship_request" do
37 | patch mentorship_request_url(@mentorship_request), params: { mentorship_request: { mentor_id: @mentorship_request.mentor_id, status: @mentorship_request.status, title: @mentorship_request.title, type: @mentorship_request.type, user_id: @mentorship_request.user_id } }
38 | assert_redirected_to mentorship_request_url(@mentorship_request)
39 | end
40 |
41 | test "should destroy mentorship_request" do
42 | assert_difference('MentorshipRequest.count', -1) do
43 | delete mentorship_request_url(@mentorship_request)
44 | end
45 |
46 | assert_redirected_to mentorship_requests_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/navigation_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class NavigationControllerTest < ActionDispatch::IntegrationTest
4 | test "should get index" do
5 | get navigation_index_url
6 | assert_response :success
7 | end
8 |
9 | test "should get about" do
10 | get navigation_about_url
11 | assert_response :success
12 | end
13 |
14 | end
15 |
--------------------------------------------------------------------------------
/test/controllers/paper_judging_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class PaperJudgingControllerTest < ActionDispatch::IntegrationTest
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/controllers/prizes_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class PrizesControllerTest < ActionDispatch::IntegrationTest
4 | setup do
5 | @prize = prizes(:one)
6 | end
7 |
8 | test "should get index" do
9 | get prizes_url
10 | assert_response :success
11 | end
12 |
13 | test "should get new" do
14 | get new_prize_url
15 | assert_response :success
16 | end
17 |
18 | test "should create prize" do
19 | assert_difference('Prize.count') do
20 | post prizes_url, params: { prize: { title: @prize.title, description: @prize.description, award: @prize.award, priority: @prize.priority, sponsor: @prize.sponsor } }
21 | end
22 |
23 | assert_redirected_to prize_url(Prize.last)
24 | end
25 |
26 | test "should show prize" do
27 | get prize_url(@prize)
28 | assert_response :success
29 | end
30 |
31 | test "should get edit" do
32 | get edit_prize_url(@prize)
33 | assert_response :success
34 | end
35 |
36 | test "should update prize" do
37 | patch prize_url(@prize), params: { prize: { title: @prize.title, description: @prize.description, award: @prize.award, priority: @prize.priority, sponsor: @prize.sponsor } }
38 | assert_redirected_to prize_url(@prize)
39 | end
40 |
41 | test "should destroy prize" do
42 | assert_difference('Prize.count', -1) do
43 | delete prize_url(@prize)
44 | end
45 |
46 | assert_redirected_to prizes_url
47 | end
48 | end
49 |
--------------------------------------------------------------------------------
/test/controllers/slackintegration_controller_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class SlackintegrationControllerTest < ActionDispatch::IntegrationTest
4 | test "should get index" do
5 | get slackintegration_index_url
6 | assert_response :success
7 | end
8 |
9 | end
10 |
--------------------------------------------------------------------------------
/test/fixtures/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/fixtures/.keep
--------------------------------------------------------------------------------
/test/fixtures/custom_rsvps.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | user: one
5 | answers: MyString
6 |
7 | two:
8 | user: two
9 | answers: MyString
10 |
--------------------------------------------------------------------------------
/test/fixtures/emails.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | subject: MyString
5 | message: MyString
6 | mailing_list: MyString
7 | status: MyString
8 | sent_by: MyString
9 |
10 | two:
11 | subject: MyString
12 | message: MyString
13 | mailing_list: MyString
14 | status: MyString
15 | sent_by: MyString
16 |
--------------------------------------------------------------------------------
/test/fixtures/event_applications.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | user_id:
5 | name:
6 | university:
7 | major:
8 | grad_year:
9 | food_restrictions:
10 |
11 | two:
12 | user_id:
13 | name:
14 | university:
15 | major:
16 | grad_year:
17 | food_restrictions:
18 |
--------------------------------------------------------------------------------
/test/fixtures/event_attendances.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | # This model initially had no columns defined. If you add columns to the
4 | # model remove the '{}' from the fixture names and add the columns immediately
5 | # below each fixture, per the syntax in the comments below
6 | #
7 | one: {}
8 | # column: value
9 | #
10 | two: {}
11 | # column: value
12 |
--------------------------------------------------------------------------------
/test/fixtures/events.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | title: MyString
5 | description: MyString
6 | location: MyString
7 | time: MyString
8 | created_by: MyString
9 | thumbnail: MyString
10 |
11 | two:
12 | title: MyString
13 | description: MyString
14 | location: MyString
15 | time: MyString
16 | created_by: MyString
17 | thumbnail: MyString
18 |
--------------------------------------------------------------------------------
/test/fixtures/files/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/fixtures/files/.keep
--------------------------------------------------------------------------------
/test/fixtures/hardware_checkout_logs.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | user: one
5 | hardware_item: one
6 | action: MyString
7 |
8 | two:
9 | user: two
10 | hardware_item: two
11 | action: MyString
12 |
--------------------------------------------------------------------------------
/test/fixtures/hardware_checkouts.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | user_id: 1
5 | user_email: MyString
6 | item_id: 1
7 | item_upc: 1
8 | checked_out_by: 1
9 |
10 | two:
11 | user_id: 1
12 | user_email: MyString
13 | item_id: 1
14 | item_upc: 1
15 | checked_out_by: 1
16 |
--------------------------------------------------------------------------------
/test/fixtures/hardware_items.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | name: MyString
5 | count: 1
6 | link: MyString
7 | category: MyString
8 | available: false
9 | uid: 1
10 |
11 | two:
12 | name: MyString
13 | count: 1
14 | link: MyString
15 | category: MyString
16 | available: false
17 | uid: 1
18 |
--------------------------------------------------------------------------------
/test/fixtures/judgements.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | # This model initially had no columns defined. If you add columns to the
4 | # model remove the '{}' from the fixture names and add the columns immediately
5 | # below each fixture, per the syntax in the comments below
6 | #
7 | one: {}
8 | # column: value
9 | #
10 | two: {}
11 | # column: value
12 |
--------------------------------------------------------------------------------
/test/fixtures/judging_assignments.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | judgement: one
5 |
6 | two:
7 | judgement: two
8 |
--------------------------------------------------------------------------------
/test/fixtures/majors.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | name: MyString
5 |
6 | two:
7 | name: MyString
8 |
--------------------------------------------------------------------------------
/test/fixtures/mentorship_notifications.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | user: one
5 | tech:
6 | all: false
7 |
8 | two:
9 | user: two
10 | tech:
11 | all: false
12 |
--------------------------------------------------------------------------------
/test/fixtures/mentorship_requests.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | user_id: 1
5 | mentor_id: 1
6 | title: MyString
7 | type:
8 | status: MyString
9 |
10 | two:
11 | user_id: 1
12 | mentor_id: 1
13 | title: MyString
14 | type:
15 | status: MyString
16 |
--------------------------------------------------------------------------------
/test/fixtures/prizes.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | award: MyString
5 | description: MyString
6 | title: MyString
7 | sponsor: MyString
8 | priority:
9 |
10 | two:
11 | award: MyString
12 | description: MyString
13 | title: MyString
14 | sponsor: MyString
15 | priority:
16 |
--------------------------------------------------------------------------------
/test/fixtures/universities.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | one:
4 | name: MyString
5 |
6 | two:
7 | name: MyString
8 |
--------------------------------------------------------------------------------
/test/fixtures/users.yml:
--------------------------------------------------------------------------------
1 | # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2 |
3 | # This model initially had no columns defined. If you add columns to the
4 | # model remove the '{}' from the fixture names and add the columns immediately
5 | # below each fixture, per the syntax in the comments below
6 | #
7 | one: {}
8 | # column: value
9 | #
10 | two: {}
11 | # column: value
12 |
--------------------------------------------------------------------------------
/test/helpers/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/helpers/.keep
--------------------------------------------------------------------------------
/test/integration/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/integration/.keep
--------------------------------------------------------------------------------
/test/mailers/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/mailers/.keep
--------------------------------------------------------------------------------
/test/mailers/previews/user_mailer_preview.rb:
--------------------------------------------------------------------------------
1 | # Preview all emails at http://localhost:3000/rails/mailers/user_mailer
2 | class UserMailerPreview < ActionMailer::Preview
3 |
4 | def welcome_email_preview
5 | @user = User.last
6 | UserMailer.welcome_email(@user)
7 | end
8 |
9 | def submit_email_preview
10 | @user = User.last
11 | UserMailer.submit_email(@user)
12 | end
13 |
14 | def accepted_email_preview
15 | @user = User.last
16 | UserMailer.accepted_email(@user)
17 | end
18 |
19 | def denied_email_preview
20 | @user = User.last
21 | UserMailer.denied_email(@user)
22 | end
23 |
24 | def waitlisted_email_preview
25 | @user = User.last
26 | UserMailer.waitlisted_email(@user)
27 | end
28 |
29 | def reminder_email_preivew
30 | @user = User.last
31 | UserMailer.reminder_email(@user)
32 | end
33 |
34 | def template_email_preview
35 | @user = User.last
36 | @subject = 'Test Subject 2'
37 | UserMailer.template_email(@user, @subject)
38 | end
39 |
40 | end
41 |
--------------------------------------------------------------------------------
/test/mailers/user_mailer_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class UserMailerTest < ActionMailer::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/test/models/.keep
--------------------------------------------------------------------------------
/test/models/custom_rsvp_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class CustomRsvpTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/email_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EmailTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/event_application_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EventApplicationTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/event_attendance_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EventAttendanceTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/event_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class EventTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/hardware_checkout_log_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class HardwareCheckoutLogTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/hardware_checkout_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class HardwareCheckoutTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/hardware_item_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class HardwareItemTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/judgement_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class JudgementTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/judging_assignment_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class JudgingAssignmentTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/major_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class MajorTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/mentorship_notification_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class MentorshipNotificationTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/mentorship_request_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class MentorshipRequestTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/prize_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class PrizeTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/university_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class UniversityTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/models/user_test.rb:
--------------------------------------------------------------------------------
1 | require 'test_helper'
2 |
3 | class UserTest < ActiveSupport::TestCase
4 | # test "the truth" do
5 | # assert true
6 | # end
7 | end
8 |
--------------------------------------------------------------------------------
/test/system/mentorship_notifications_test.rb:
--------------------------------------------------------------------------------
1 | require "application_system_test_case"
2 |
3 | class MentorshipNotificationsTest < ApplicationSystemTestCase
4 | setup do
5 | @mentorship_notification = mentorship_notifications(:one)
6 | end
7 |
8 | test "visiting the index" do
9 | visit mentorship_notifications_url
10 | assert_selector "h1", text: "Mentorship Notifications"
11 | end
12 |
13 | test "creating a Mentorship notification" do
14 | visit mentorship_notifications_url
15 | click_on "New Mentorship Notification"
16 |
17 | fill_in "All", with: @mentorship_notification.all
18 | fill_in "Tech", with: @mentorship_notification.tech
19 | fill_in "User", with: @mentorship_notification.user_id
20 | click_on "Create Mentorship notification"
21 |
22 | assert_text "Mentorship notification was successfully created"
23 | click_on "Back"
24 | end
25 |
26 | test "updating a Mentorship notification" do
27 | visit mentorship_notifications_url
28 | click_on "Edit", match: :first
29 |
30 | fill_in "All", with: @mentorship_notification.all
31 | fill_in "Tech", with: @mentorship_notification.tech
32 | fill_in "User", with: @mentorship_notification.user_id
33 | click_on "Update Mentorship notification"
34 |
35 | assert_text "Mentorship notification was successfully updated"
36 | click_on "Back"
37 | end
38 |
39 | test "destroying a Mentorship notification" do
40 | visit mentorship_notifications_url
41 | page.accept_confirm do
42 | click_on "Destroy", match: :first
43 | end
44 |
45 | assert_text "Mentorship notification was successfully destroyed"
46 | end
47 | end
48 |
--------------------------------------------------------------------------------
/test/system/prizes_test.rb:
--------------------------------------------------------------------------------
1 | require "application_system_test_case"
2 |
3 | class PrizesTest < ApplicationSystemTestCase
4 | setup do
5 | @prize = prizes(:one)
6 | end
7 |
8 | test "visiting the index" do
9 | visit prizes_url
10 | assert_selector "h1", text: "Prizes"
11 | end
12 |
13 | test "creating a Prize" do
14 | visit prizes_url
15 | click_on "New Prize"
16 |
17 | fill_in "Title", with: @prize.title
18 | fill_in "Description", with: @prize.description
19 | fill_in "Award", with: @prize.award
20 | fill_in "Priority", with: @prize.priority
21 | fill_in "Sponsor", with: @prize.sponsor
22 | click_on "Create Prize"
23 |
24 | assert_text "Prize was successfully created"
25 | click_on "Back"
26 | end
27 |
28 | test "updating a Prize" do
29 | visit prizes_url
30 | click_on "Edit", match: :first
31 |
32 | fill_in "Title", with: @prize.title
33 | fill_in "Description", with: @prize.description
34 | fill_in "Award", with: @prize.award
35 | fill_in "Priority", with: @prize.priority
36 | fill_in "Sponsor", with: @prize.sponsor
37 | click_on "Update Prize"
38 |
39 | assert_text "Prize was successfully updated"
40 | click_on "Back"
41 | end
42 |
43 | test "destroying a Prize" do
44 | visit prizes_url
45 | page.accept_confirm do
46 | click_on "Destroy", match: :first
47 | end
48 |
49 | assert_text "Prize was successfully destroyed"
50 | end
51 | end
52 |
--------------------------------------------------------------------------------
/test/test_helper.rb:
--------------------------------------------------------------------------------
1 | ENV['RAILS_ENV'] ||= 'test'
2 | require File.expand_path('../../config/environment', __FILE__)
3 | require 'rails/test_help'
4 |
5 | class ActiveSupport::TestCase
6 | # Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order.
7 | fixtures :all
8 |
9 | # Add more helper methods to be used by all tests here...
10 | end
11 |
--------------------------------------------------------------------------------
/tmp/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/tmp/.keep
--------------------------------------------------------------------------------
/vendor/assets/javascripts/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/vendor/assets/javascripts/.keep
--------------------------------------------------------------------------------
/vendor/assets/stylesheets/.keep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fuseumass/dashboard/90d3b08591e73daea208f2f1136a6d4895aad842/vendor/assets/stylesheets/.keep
--------------------------------------------------------------------------------