Skip to content

Commit

Permalink
Squashed commit of the following:
Browse files Browse the repository at this point in the history
commit 09167ae
Author: JeremyRudman <38338616+JeremyRudman@users.noreply.github.com>
Date:   Sun Sep 20 04:23:15 2020 -0400

    fix(questionnaire): added phone number requirements (#283)

    * fix(questionnaire): added phone number requirement

    using a regex to require users to input a valid phone number and
    stripped non numbers from the stored value with the exception of the
    country code

    * fix(questionnaire): edited callback to pass test

    edit call back that removes non-numbers from phone number to pass
    testing

    * fix(questionnaire): edited test to fail with phone formatting

    edited test to fail if the phone # formating is still there when saved
    into the database. Also stopped exception for "+" as it was not
    necessary.

    * fix(questionnaire): fixed comment about phone number stripping

    * fix: houndci formatting comments

    * fix: earlier fix was incorrect. correct houndci fix

    * fix(phone): implmented changed phone number regex for validation

    implement suggested regex although made internation extention 3 instead
    of 2 digits long for max length

    * fix(questionnaire): added support for more international numbers

    made the numbers regex more flexable to support more international
    numbers such as in Nigeria with two digit area codes.

    * Phone validation hit, remove duplicate check

    Co-authored-by: Chris Baudouin, Jr <cjb5326@rit.edu>
    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit c9d6658
Author: JeremyRudman <38338616+JeremyRudman@users.noreply.github.com>
Date:   Sun Sep 20 04:09:39 2020 -0400

    fix: School text-box dropdown in manage/questionnaires/edit missing background  (#296)

    * fix(questionnaire): fixed background in school autocomplete

    fixed the questionnaire edit page so that it was blank in the management
    edit page

    * fix(questionnaire): sperated autocomplete sass into its own file

    seperated the sass for the autocomplete into its own file so that manage
    could use it without the other sass in forms.sass

    * Use grays for manage backgrouind

    Co-authored-by: Chris Baudouin, Jr <cjb5326@rit.edu>
    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 113cd61
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sun Sep 20 03:55:37 2020 -0400

    fix: Fixes failing test cases from #242 (#364)

commit 58b5849
Author: Peter Kos <pkos91@icloud.com>
Date:   Sun Sep 20 03:01:47 2020 -0400

    refactor: Renames user roles, improves security

    commit 1daa943
    Author: Peter Kos <pkos91@icloud.com>
    Date:   Sun Sep 20 02:57:01 2020 -0400

        Organizers have same overview page access as direc

    commit cdf57b6
    Author: Peter Kos <pkos91@icloud.com>
    Date:   Sun Sep 20 02:56:41 2020 -0400

        Volunteers are redirected to checkin route

    commit 3f2a30c
    Merge: b5ad3b8 d87269d
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Sep 20 00:30:03 2020 -0400

        Merge branch '2.0' into hm-242

    commit b5ad3b8
    Author: Jeremy Rudman <jeremyrudman@gmail.com>
    Date:   Sat Sep 19 21:03:08 2020 -0400

        fix(sidebar): fixed UI problems for diffrent roles

        removed the duplicate checkin button for orginizers and had checkin page defaut to be highlighted for volenteers

    commit 057e3aa
    Merge: 971dd0a 69e8d6e
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Mon Sep 14 16:43:59 2020 -0400

        Merge branch '2.0' into hm-242

    commit 971dd0a
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Mon Sep 14 16:37:18 2020 -0400

        refactor: Increases funciton clarity

    commit 711aeea
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Mon Sep 14 16:35:56 2020 -0400

        refactor: Increases funciton clarity

    commit 19f1926
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sat Sep 12 00:46:52 2020 -0400

        fix: Hound issues v1

    commit c3d44f0
    Merge: 2ab8865 a767446
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sat Sep 12 00:32:30 2020 -0400

        Merge branch '2.0' into hm-242

    commit 2ab8865
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sat Sep 12 00:29:43 2020 -0400

        refactor: Cleans tests, improves coverage

    commit 59d54ed
    Merge: 274787f cb16869
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Mon Sep 7 00:11:19 2020 -0400

        Merge branch '2.0' into hm-242

    commit 274787f
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Sep 6 23:59:27 2020 -0400

        refactor: Renames event_tracking to Volunteer

    commit 873e43c
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Sep 6 23:48:29 2020 -0400

        refactor: Renames admin_limited_access to Organizer

    commit f592750
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Sep 6 19:38:54 2020 -0400

        refactor: Changes admin to director

commit 0237965
Author: Peter Kos <pkos91@icloud.com>
Date:   Sun Sep 20 02:27:55 2020 -0400

    fix: Text centering on application page  (#361)

    * Fix bug

    * Long containers are left aligned,not centernewline

commit 28913f7
Author: JeremyRudman <38338616+JeremyRudman@users.noreply.github.com>
Date:   Sun Sep 20 02:16:29 2020 -0400

    fix(bus_captain): Alerts admins if a bus captain is removed (#270)

    * fix(bus_captain): alerts admins if a bus captain is removed

    if a bus captain changes bus or declinces a rsvp he is removed as a bus
    captain. All admins are alerted to the removal of a bus captain by email

    * fix: corrected houndci formating errors

    * Refactor var names; remove auto captain interest

    * On questnnre destroy, email admins if bus captain

    * Don’t send email remove_captain on first bus assignment

    * Tests!

    * bark bark

    Co-authored-by: Chris Baudouin, Jr <cjb5326@rit.edu>
    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit d87269d
Author: David Quach <dq6180@rit.edu>
Date:   Sun Sep 20 00:13:52 2020 -0400

    feat: Automatically remind people to RSVP (#175)

    * feat: add rsvp reminder email to trigger and automation process based on loose rules

    * feat: add the rsvp reminder email to queue_reminder_email class

    * fix: fix issue with hound

    * fix: resolve issues with linting and fix conditionals

    * fix: more linting issues

    * fix: more more linting issues

    * seperate the two functions

    * update on per Stuart instruction, make this more automated

    * forgot to commit this

    * remove this unnecessary piece of code

    * fix linting issues

    * remove since we are not using this

    * Update app/models/user.rb

    Co-Authored-By: Stuart Olivera <stuart@stuartolivera.com>

    * forgot to add end

    * resolve for hound

    * fix(dashboard): Fixes security vulnerability that allowed event_tracking role to access Dashboard (#215)

    * chore(release): 1.22.3 [skip ci]

    ## [1.22.3](v1.22.2...v1.22.3) (2020-05-16)

    ### Bug Fixes

    * **dashboard:** Fixes security vulnerability that allowed event_tracking role to access Dashboard ([#215](#215)) ([](74a40ad))

    ### Styles

    * **check-in:** Changes table header to be more descriptive ([#207](#207)) ([](889fbd0))
    * **config:** Removes unused event_is_over flag ([#208](#208)) ([](0c73e66))

    * build(deps): Upgrade yarn (#212)

    * build(deps): Upgrade yarn

    * build(deps): Upgrade gems

    * build(deps): Remove obsolete gems

    * v0.0.0

    * build(deps): Update semantic-release

    * fix(questionnaire): visual bug in school autocomplete school dropdown

    the css was set for an "a" tag when the list was made up of divs so I
    switched the css to work for the "div" tag in the autocomplete

    * fix(questionnaire): visual bug in school autocomplete school dropdown

    the css was set for an "a" tag when the list was made up of divs so I
    switched the css to work for the "div" tag in the autocomplete. I also
    hide a element that was not present earlier

    * build(deps): Upgrades Rails to 5.2.4.3

    * build(deps): Upgrades gems

    Co-authored-by: Jeremy Rudman <jeremyrudman@gmail.com>

    * fix: Fixes date issue with RSVP reminder job

    * fix: Fixes bug where message would not send

    * refactor: Change subject of RSVP reminder

    * refactor: Verbage changes, updated reminder message

    * 2.0: Removes SparkPost mentions for 2.0

    * fix: Fixes timezone issues

    * fix: More timezone issues

    Co-authored-by: Stuart Olivera <stuart@stuartolivera.com>
    Co-authored-by: Chris Baudouin, Jr <cjb5326@rit.edu>
    Co-authored-by: semantic-release-bot <semantic-release-bot@martynus.net>
    Co-authored-by: Jeremy Rudman <jeremyrudman@gmail.com>
    Co-authored-by: Chris Baudouin, Jr <chrisbaudouinjr@icloud.com>

commit 2e9379f
Author: Peter Kos <pkos91@icloud.com>
Date:   Sat Sep 19 22:31:18 2020 -0400

    fix: Hackathon names now consistently on newline, wrapping is centered (#358)

    * Hackthon name title page has newline

    * Make houndbot happy

commit 5e03082
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Fri Sep 18 21:01:21 2020 -0400

    feat(questionnaires): Allows directors to block new questionnaires (#279)

    * feat(questionnaires): Allows directors to block new questionnaires

    * Fixes Hound issues

    * Updates app/views/questionnaires/new.html.haml

    Co-authored-by: Peter Kos <pkos91@icloud.com>

    * fix: Compatibility fix with hm-222

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 54d2cea
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Fri Sep 18 19:16:02 2020 -0400

    refactor: Adds GSDP info, cleans Dokku docs (#356)

    * refactor: Adds GSDP info, cleans Dokku docs

    * Update docs/deployment-dokku.md

    Co-authored-by: Peter Kos <pkos91@icloud.com>

    * Update docs/deployment-dokku.md

    Co-authored-by: Peter Kos <pkos91@icloud.com>

    * refactor: Adds additional GSDP content

    * fix: Fixes sentence

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 31b418d
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Thu Sep 17 13:13:19 2020 -0400

    refactor: Cleans Questionnaire for MyMLH V3 (#338)

    * refactor: Removes "Convert to Admin" on Questionnaire

    * refactor: Updates MyMLH branding + V3

    * fix: Removes tests for convert_to_admin

    * refactor: Removes remaining "convert_to_admin" calls

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 1599fe1
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Wed Sep 16 18:45:42 2020 -0400

    refactor(docs): Updates Environment Variable docs (#300)

    * refactor(docs): Updates Environment Variable docs

    * Update docs/deployment-environment-variables.md

    Co-authored-by: Peter Kos <pkos91@icloud.com>

    * refactor: Redesigns EV page

    * Update docs/deployment-environment-variables.md

    Co-authored-by: Peter Kos <pkos91@icloud.com>

    * refactor: Adds optional notice

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 69e8d6e
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Mon Sep 14 12:34:28 2020 -0400

    refactor: Redesigns password reset pages (#308)

    * refactor: Redesigns password reset pages

    * fix: Hound newline issue

commit 03e632c
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Mon Sep 14 12:18:45 2020 -0400

    fix(dashboard): Map data refactored for faster load times (#269)

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 9e6fe39
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Mon Sep 14 10:57:47 2020 -0400

    refactor: Updates 24hr reminder to remove MyMLH reference (#302)

    * refactor: Updates 24hr reminder to remove MyMLH reference

    * refactor: Improves verbiage of 24hr message

    * Update db/seed_messages/user--24hr_incomplete_application.md

    Co-authored-by: Peter Kos <pkos91@icloud.com>

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 12cc746
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sun Sep 13 22:33:00 2020 -0400

    refactor: Renames "Guides" to "Docs" (#353)

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 8617981
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sun Sep 13 22:12:51 2020 -0400

    fix(docs): Refactors page titles and makes API pages visible again (#320)

    * refactor: Changes "Development" to "Developer"

    * fix(docs): Refactors page titles and makes API pages visible again

    * FIx “too” -> “to” typo

    * refactor: Refactors API section

    * fix: Fixes broken link to API testing page

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 7c3cc0a
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sat Sep 12 01:31:56 2020 -0400

    build(deps): Updates Rails to 5.2.4.4 (#349)

commit e72166d
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sat Sep 12 01:18:49 2020 -0400

    build(deps): Updates ChartKick to 3.4 (#347)

commit a767446
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Wed Sep 9 11:31:00 2020 -0400

    refactor(docs): Updates Messages and customization instructions (#321)

    * refactor(docs): Updates Messages and customization instructions

    * Enable default questionnaire deined message

    Syncs documentation

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 9c61d1f
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Wed Sep 9 11:20:24 2020 -0400

    feat(docs): Adds new Resources page (#318)

commit fe66870
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Tue Sep 8 12:56:24 2020 -0400

    refactor: Cleans update method in rsvps_controller (#305)

    * refactor: Cleans update method in rsvps_controller

    * refactor: Fixes whitespace issue for Hound

commit cb16869
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Mon Sep 7 00:07:59 2020 -0400

    fix: Shows manage button for admin_limited_access (#331)

commit 767715a
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Wed Sep 2 13:51:35 2020 -0400

    build(deps): Upgrades yarn dependencies (#316)

    * build(deps): Upgrades yarn dependencies

    * build(deps): Upgrades yarn dependencies

commit e0e537c
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Wed Sep 2 11:37:14 2020 -0400

    fix(deps): Updates the locked Ruby version (#340)

commit ac720d9
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Tue Sep 1 01:26:46 2020 -0400

    refactor(questionnaire): No longer deletes user with questionnaire (#287)

    * refactor(questionnaire): No longer deletes user with questionnaire

    * Hound whitespace

commit 5e96a9c
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sun Aug 30 01:04:37 2020 -0400

    feat(messages): Transitions from SparkPost to SendGrid (#285)

    * feat(messages): Transitions from SparkPost to SendGrid

    * Fixes Hound issues (v1)

    * fix: Hound whitespace issue

    * refactor: Removes stubbed-out code for HM2.1

    * Update README.md

    * Update README.md

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit abcf634
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sun Aug 30 00:36:26 2020 -0400

    feat(Dashboard): Redesigns sidebar with category labels (#290)

    * feat(dashboard): Adds category labels to sidebar

    * refactor: Changes config to settings, adds localization

    * refactor: Adds localization to sidebar

    * refactor: Adds localization to page titles

    * refactor: Adds "Overview" category for event-wide pages

    * refactor: Adds missing localizers

commit c6d33a9
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sun Aug 30 00:08:09 2020 -0400

    build(deps): Updates gem cache (#334)

commit 68b8590
Author: Chris Baudouin, Jr <cjb5326@rit.edu>
Date:   Sat Aug 29 23:52:39 2020 -0400

    build: Upgrades Rails to 2.6.6 (#312)

    Co-authored-by: Peter Kos <pkos91@icloud.com>

commit 6266f5a
Author: Peter Kos <pkos91@icloud.com>
Date:   Sat Aug 29 23:38:17 2020 -0400

    refactor: `first_name` and `last_name` move from `questionnaire` to `user` (#241)

    * Initial move: first/last name; user->quesitonnaire

    - Models adjusted
    - Migration made (needs to be updated to a MOVE, not a delete)
    - Updated SOME tests and factories
    - Create account works

    * refactor: Attempt to fix backend params

    Includes fixing any discrepancies on routes like `/manage`

    * refactor: Make HoundBot a little happier

    * feat: Admin list shows first/last names

    * inprog on stats page

    - Actually retreive first/last names on questionnaires page

    * Refactored stats datatable and controller

    - Checkin datatable also tweaked to work.
    - Removed resumes; #244

    * Migration is now backwards compatible with pre-2.0

    Needs to be added to 2.0 migration guide!

    * 4space->2space 😡 #downwith2spaces

    * Fix various first_name/last_name bugs

    Most annoying one is in the questionnaire edit screen...

    * Fixed remainder of tests for name refactor

    * Fix datatable style and count ranges

    * Fix some more style bugs

    * Viewing bus list w/ passengers now works

    * Adds Users & Staff support for #222

    * Adds #222 support to stats, fixes stats layout

    * Fixes Hound issues

    * Removes Hound whitespace issues

    * History audit bugfix

    No longer nil as we don’t check the type of the previous history and just show both, risking a nil visible on the questionnaire page if value is set for the first time

    * Add nil check back, whoops. This works better.

    * Squashed commit of the following:

    commit 4d1b4e2
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Wed Jul 1 01:08:19 2020 -0400

        Back merge master (#273)

        * fix(dashboard): Fixes security vulnerability that allowed event_tracking role to access Dashboard (#215)

        * chore(release): 1.22.3 [skip ci]

        ## [1.22.3](v1.22.2...v1.22.3) (2020-05-16)

        ### Bug Fixes

        * **dashboard:** Fixes security vulnerability that allowed event_tracking role to access Dashboard ([#215](#215)) ([](74a40ad))

        ### Styles

        * **check-in:** Changes table header to be more descriptive ([#207](#207)) ([](889fbd0))
        * **config:** Removes unused event_is_over flag ([#208](#208)) ([](0c73e66))

        * build(deps): Upgrade yarn (#212)

        * build(deps): Upgrade yarn

        * build(deps): Upgrade gems

        * build(deps): Remove obsolete gems

        * v0.0.0

        * build(deps): Update semantic-release

        * fix(questionnaire): visual bug in school autocomplete school dropdown

        the css was set for an "a" tag when the list was made up of divs so I
        switched the css to work for the "div" tag in the autocomplete

        * fix(questionnaire): visual bug in school autocomplete school dropdown

        the css was set for an "a" tag when the list was made up of divs so I
        switched the css to work for the "div" tag in the autocomplete. I also
        hide a element that was not present earlier

        * build(deps): Upgrades Rails to 5.2.4.3

        * build(deps): Upgrades gems

        Co-authored-by: Jeremy Rudman <jeremyrudman@gmail.com>

        * build(deps): Bump puma from 4.3.4 to 4.3.5 (#219)

        Bumps [puma](https://github.com/puma/puma) from 4.3.4 to 4.3.5.
        - [Release notes](https://github.com/puma/puma/releases)
        - [Changelog](https://github.com/puma/puma/blob/master/History.md)
        - [Commits](https://github.com/puma/puma/commits)

        Signed-off-by: dependabot[bot] <support@github.com>

        Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

        * build(deps): Upgrades Puma cache (#221)

        * fix(questionnaire): Fixes error when trying to view a questionnaire modified by a deleted admin (#236)

        * chore(release): 1.22.4 [skip ci]

        ## [1.22.4](v1.22.3...v1.22.4) (2020-05-26)

        ### Bug Fixes

        * **questionnaire:** Fixes error when trying to view a questionnaire modified by a deleted admin ([#236](#236)) ([](2ffe116))

        * build(deps): Bump websocket-extensions from 0.1.4 to 0.1.5 (#250)

        * build(deps): Bump websocket-extensions from 0.1.4 to 0.1.5

        Bumps [websocket-extensions](https://github.com/faye/websocket-extensions-ruby) from 0.1.4 to 0.1.5.
        - [Release notes](https://github.com/faye/websocket-extensions-ruby/releases)
        - [Changelog](https://github.com/faye/websocket-extensions-ruby/blob/master/CHANGELOG.md)
        - [Commits](faye/websocket-extensions-ruby@0.1.4...0.1.5)

        Signed-off-by: dependabot[bot] <support@github.com>

        * build(deps): Updates websocket-extensions gem cache

        Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
        Co-authored-by: Chris Baudouin, Jr <chrisbaudouinjr@icloud.com>

        * build(deps): Bump rack from 2.2.2 to 2.2.3 (#268)

        * build(deps): Bump rack from 2.2.2 to 2.2.3

        Bumps [rack](https://github.com/rack/rack) from 2.2.2 to 2.2.3.
        - [Release notes](https://github.com/rack/rack/releases)
        - [Changelog](https://github.com/rack/rack/blob/master/CHANGELOG.md)
        - [Commits](rack/rack@v2.2.2...2.2.3)

        Signed-off-by: dependabot[bot] <support@github.com>

        * Adds rack gem cache

        Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
        Co-authored-by: Chris Baudouin, Jr <chrisbaudouinjr@icloud.com>

        Co-authored-by: semantic-release-bot <semantic-release-bot@martynus.net>
        Co-authored-by: Jeremy Rudman <jeremyrudman@gmail.com>
        Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
        Co-authored-by: Peter Kos <pkos91@icloud.com>

    commit 513e1c2
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Tue Jun 30 18:45:42 2020 -0400

        fix(login): Removes always visible login error (#263)

        * fix(login): Removes always visible login error

        * Fixes Hound spacing requirement

    commit 58601a1
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Jun 28 19:16:08 2020 -0400

        build(deps): Updates gems (#275)

    commit d1a01f8
    Author: Peter Kos <pkos91@icloud.com>
    Date:   Sat Jun 20 19:26:53 2020 -0400

        docs: Add guide for local API setup, update api-usage slightly (#235)

        * docs: Add API/OAuth 2 setup guide

        Also rename api to api-usage

        * docs: Cleanup api-usage page, add notes about 2.0

        * docs: Apply suggestions from code review

        Co-authored-by: Stuart Olivera <stuart@stuartolivera.com>

        * docs: Reword API introduction to be more friendly

        - Clarifies what Postman and Paw are, with links to their product pages
        - Notes that this process works for remote instances as well, not just localhost
        - Removed trailing whitespace and extra newlines
        - Fixed a single typo

        * Verbiage and HM typo fixes

        * Added .DS_Store to .gitignore

        Co-authored-by: Stuart Olivera <stuart@stuartolivera.com>

    commit 82a7ff4
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Thu Jun 18 08:58:35 2020 -0400

        fix(config): Removes disable_account_registration from database (#247)

        * fix(config): Removes disable_account_registration from database

        * fix(config): Saves new config item, adds extra precautionary check

    commit f07ec28
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Thu Jun 11 17:35:16 2020 -0400

        fix(questionnaire): Fixes error when trying to view a questionnaire modified by a deleted admin (#238)

        * fix(dashboard): Fixes security vulnerability that allowed event_tracking role to access Dashboard (#215)

        * chore(release): 1.22.3 [skip ci]

        ## [1.22.3](v1.22.2...v1.22.3) (2020-05-16)

        ### Bug Fixes

        * **dashboard:** Fixes security vulnerability that allowed event_tracking role to access Dashboard ([#215](#215)) ([](74a40ad))

        ### Styles

        * **check-in:** Changes table header to be more descriptive ([#207](#207)) ([](889fbd0))
        * **config:** Removes unused event_is_over flag ([#208](#208)) ([](0c73e66))

        * build(deps): Upgrade yarn (#212)

        * build(deps): Upgrade yarn

        * build(deps): Upgrade gems

        * build(deps): Remove obsolete gems

        * v0.0.0

        * build(deps): Update semantic-release

        * fix(questionnaire): visual bug in school autocomplete school dropdown

        the css was set for an "a" tag when the list was made up of divs so I
        switched the css to work for the "div" tag in the autocomplete

        * fix(questionnaire): visual bug in school autocomplete school dropdown

        the css was set for an "a" tag when the list was made up of divs so I
        switched the css to work for the "div" tag in the autocomplete. I also
        hide a element that was not present earlier

        * build(deps): Upgrades Rails to 5.2.4.3

        * build(deps): Upgrades gems

        Co-authored-by: Jeremy Rudman <jeremyrudman@gmail.com>

        * build(deps): Bump puma from 4.3.4 to 4.3.5 (#219)

        Bumps [puma](https://github.com/puma/puma) from 4.3.4 to 4.3.5.
        - [Release notes](https://github.com/puma/puma/releases)
        - [Changelog](https://github.com/puma/puma/blob/master/History.md)
        - [Commits](https://github.com/puma/puma/commits)

        Signed-off-by: dependabot[bot] <support@github.com>

        Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

        * build(deps): Upgrades Puma cache (#221)

        * fix(questionnaire): Fixes error when trying to view a questionnaire modified by a deleted admin

        * refactor(tests): Cleans verbage of tests to match

        Co-authored-by: semantic-release-bot <semantic-release-bot@martynus.net>
        Co-authored-by: Jeremy Rudman <jeremyrudman@gmail.com>
        Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

    * Fix undefined err on bus list info

    * Fix bus captain bug, update schema

    * Squashed commit of the following:

    commit ede300f
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sat Aug 29 21:05:53 2020 -0400

        feat: Updates MyMLH to V3 (#329)

        * feat: Updates MyMLH to V3

        * fix(User): Adds missing provider field

        * refactor: Updates MyMLH branding

        * Autofill MyMLH provider if info is missing

        * houndbot

        Co-authored-by: Peter Kos <pkos91@icloud.com>

    commit 675b3f6
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Aug 23 22:43:48 2020 -0400

        refactor: Changes "Applications" to "Questionnaires" in map (#326)

    commit 388c9bd
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Sun Aug 23 22:08:26 2020 -0400

        fix(Dashboard): Fixes missing location data in map (#324)

    commit a062140
    Author: Chris Baudouin, Jr <cjb5326@rit.edu>
    Date:   Wed Aug 19 11:02:07 2020 -0400

        feat(docs): Initial documentation for 2.0 (#291)

        * feat(docs): Initial documentation for 2.0

        * refactor: Updates maintenance.md for verbage changes

        * refactor: Refactors structure of navigation

    commit 79831f6
    Author: JeremyRudman <38338616+JeremyRudman@users.noreply.github.com>
    Date:   Sat Jul 25 12:47:35 2020 -0400

        feat(messages): Adds a confirmation modal to send messages (#272)

        * feat(message): added a confirmation modal to send messages

        added a modal for when you send a message that displays the number of
        people you are sending it to in large red text.

        * fix: houndci formatting errors

        * fix(messages): fixed error and made changes to text

        made "send message" singular and made only the the number red. I also
        fixed the variable not loading properly

        * fix: houndci styling changes

        * feat: made email modal text black instead of red

        the email confirmation modal displays the number in black instead of red

        * refactor: Adds number delimiter to recipients, changes cancel outline

        Co-authored-by: Chris Baudouin, Jr <cjb5326@rit.edu>

    commit e4169a7
    Author: JeremyRudman <38338616+JeremyRudman@users.noreply.github.com>
    Date:   Thu Jul 9 00:39:23 2020 -0400

        fix(questionnaire): School autocomplete matches form field width (#278)

        * fix(questionnaire): school autocomplete matchs fourm field width

        * fix(questionnaires): added ellipsis to autocomplete

        when the forum field is smaller the school name the autocomplete goes
        beyond the width the field and this causes the text to ellipsis in thet
        case

    * Actually assign current_user

    * mymlh working

    * Refactor questionnnaire new to be nicer to read

    * Patch condition error for info refactor

    Was attempting to use potentially nil value before checking if the value was nil

    ALso cleaned up part of the test in questionnaires controler to create the entire user object as we need both first/last name, as well as email. #goodcodestyle #pleasehiremegoogle

    Co-authored-by: Chris Baudouin, Jr <chrisbaudouinjr@icloud.com>
    Co-authored-by: Chris Baudouin, Jr <cjb5326@rit.edu>
  • Loading branch information
peterkos committed Sep 21, 2020
1 parent ca0d8a0 commit a5644e6
Show file tree
Hide file tree
Showing 85 changed files with 1,116 additions and 338 deletions.
2 changes: 1 addition & 1 deletion app/assets/javascripts/manage/lib/setupDataTables.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ var setupDataTables = function () {
],
});

$('.datatable.admins').DataTable({
$('.datatable.staff').DataTable({
order: [2, 'asc'],
columns: [
{ orderable: true, data: 'id', visible: false },
Expand Down
9 changes: 9 additions & 0 deletions app/assets/javascripts/validate.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@ document.addEventListener('turbolinks:load', function() {
}
}
break;
case 'phone':
if (value) {
var phoneReg = /^[\+]?[0-9]{0,3}[-\s\.]?[(]?[0-9]{1,3}[)]?[-\s\.]?[0-9]{1,3}[-\s\.]?[0-9]{4,6}$/;
if (!phoneReg.test(value)) {
notify(this, 'Please enter a valid phone number');
success = false;
}
}
break;
case 'file-max-size':
if (
this.files &&
Expand Down
1 change: 1 addition & 0 deletions app/assets/stylesheets/application.sass
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
@import general/table
@import forms/forms
@import forms/confirmation
@import forms/autocomplete

@import general/theming-editor

Expand Down
24 changes: 24 additions & 0 deletions app/assets/stylesheets/forms/_autocomplete.sass
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@

// jquery ui override
.ui-autocomplete
@include css4
background: var(--input--background--focus)
border: 1px solid var(--input--border-color--focus)
color: var(--input--text--focus)
list-style: none
padding: 0
.ui-menu-item div
padding: 2px 5px
display: block
cursor: pointer
overflow: hidden
text-overflow: ellipsis
white-space: nowrap
&:hover
@include css4
background: var(--primary)
@include css4
color: var(--white)
// needed for ellipsis in text to work and acts as a min-width
.ui-menu
width: 50px
29 changes: 5 additions & 24 deletions app/assets/stylesheets/forms/_forms.sass
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ hr
.btn
margin-bottom: 30px

.text-overflow-center
text-align: center
display: flex
justify-content: center

.simple_form
@include css4
color: var(--grey)
Expand Down Expand Up @@ -253,30 +258,6 @@ input[type=submit]
margin-bottom: 3px


// jquery ui override
.ui-autocomplete
@include css4
background: var(--input--background--focus)
border: 1px solid var(--input--border-color--focus)
color: var(--input--text--focus)
list-style: none
padding: 0
.ui-menu-item div
padding: 2px 5px
display: block
cursor: pointer
overflow: hidden
text-overflow: ellipsis
white-space: nowrap
&:hover
@include css4
background: var(--primary)
@include css4
color: var(--white)
// needed for ellipsis in text to work and acts as a min-width
.ui-menu
width: 50px

// form wizard
.wizard-stage
display: none
Expand Down
4 changes: 4 additions & 0 deletions app/assets/stylesheets/manage.sass
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
@import manage/selectize-fix
@import vendor/simplemde.min
@import vendor/codemirror
@import general/variables
@import general/css4
@import manage/autocomplete

$grey-dark: #555
$grey-med: #999
Expand Down Expand Up @@ -172,6 +175,7 @@ $grey-med: #999
.sidebar-mobile .sidebar-sticky
height: auto


/*
* Datatable changes
*/
Expand Down
12 changes: 12 additions & 0 deletions app/assets/stylesheets/manage/_autocomplete.sass
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@

@import ../forms/autocomplete

// jquery ui override
.ui-autocomplete
background: white
border: 1px solid #333
color: #222
.ui-menu-item div
&:hover
background: #999
color: white
23 changes: 13 additions & 10 deletions app/controllers/manage/application_controller.rb
Original file line number Diff line number Diff line change
@@ -1,27 +1,30 @@
class Manage::ApplicationController < ApplicationController
before_action :logged_in
before_action :require_admin_or_limited_admin
before_action :limit_write_access_to_admins, only: ["edit", "update", "new", "create", "destroy", "convert_to_admin", "deliver", "merge", "perform_merge", "toggle_bus_captain", "duplicate", "update_acc_status", "send_update_email", "live_preview"]
before_action :require_director_or_organizer_or_volunteer
before_action :limit_write_access_to_directors, only: ["edit", "update", "new", "create", "destroy", "deliver", "merge", "perform_merge", "toggle_bus_captain", "duplicate", "update_acc_status", "send_update_email", "live_preview"]
skip_before_action :verify_authenticity_token, if: :json_request?

def logged_in
authenticate_user!
end

def require_full_admin
return redirect_to root_path unless current_user.try(:admin?)
def require_director
return redirect_to manage_checkins_path if current_user.volunteer?
return redirect_to manage_root_path if current_user.organizer?
return redirect_to root_path unless current_user.try(:director?)
end

def require_admin_or_limited_admin
return redirect_to root_path unless current_user.try(:admin?) || current_user.try(:admin_limited_access?)
def require_director_or_organizer
return redirect_to manage_checkins_path if current_user.volunteer?
return redirect_to root_path unless current_user.organizing_staff?
end

def require_admin_or_limited_admin_or_event_tracking
redirect_to root_path unless current_user.try(:admin?) || current_user.try(:admin_limited_access?) || current_user.try(:event_tracking?)
def require_director_or_organizer_or_volunteer
redirect_to root_path unless current_user.staff?
end

def limit_write_access_to_admins
redirect_to url_for(controller: controller_name, action: :index) unless current_user.try(:admin?)
def limit_write_access_to_directors
redirect_to url_for(controller: controller_name, action: :index) unless current_user.try(:director?)
end

def json_request?
Expand Down
5 changes: 1 addition & 4 deletions app/controllers/manage/configs_controller.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
class Manage::ConfigsController < Manage::ApplicationController
before_action :limit_access_admin
before_action :require_director
before_action :get_config, only: [:edit, :update, :update_only_css_variables]

respond_to :html, :json
Expand Down Expand Up @@ -69,7 +69,4 @@ def get_config
end
end

def limit_access_admin
redirect_to root_path unless current_user.admin?
end
end
3 changes: 1 addition & 2 deletions app/controllers/manage/dashboard_controller.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
class Manage::DashboardController < Manage::ApplicationController
skip_before_action :require_admin_or_limited_admin
before_action :require_admin_or_limited_admin
before_action :require_director_or_organizer

def index
end
Expand Down
3 changes: 1 addition & 2 deletions app/controllers/manage/data_exports_controller.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
class Manage::DataExportsController < Manage::ApplicationController
skip_before_action :require_admin_or_limited_admin
before_action :require_full_admin
before_action :require_director

before_action :set_data_export, only: [:destroy]

Expand Down
7 changes: 4 additions & 3 deletions app/controllers/manage/messages_controller.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
class Manage::MessagesController < Manage::ApplicationController
before_action :require_director_or_organizer
before_action :set_message, only: [:show, :edit, :update, :destroy, :deliver, :preview, :duplicate]
before_action :check_message_access, only: [:edit, :update, :destroy]
before_action :limit_template_access_to_admins, only: [:template, :template_preview, :template_update, :template_replace_with_default]
before_action :limit_template_access_to_directors, only: [:template, :template_preview, :template_update, :template_replace_with_default]

respond_to :html, :json

Expand Down Expand Up @@ -106,9 +107,9 @@ def template_replace_with_default

private

def limit_template_access_to_admins
def limit_template_access_to_directors
# From Manage::ApplicationController
limit_write_access_to_admins
limit_write_access_to_directors
end

def message_params
Expand Down
16 changes: 8 additions & 8 deletions app/controllers/manage/questionnaires_controller.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class Manage::QuestionnairesController < Manage::ApplicationController
include QuestionnairesControllable

before_action :set_questionnaire, only: [:show, :edit, :update, :destroy, :check_in, :convert_to_admin, :update_acc_status]
before_action :set_questionnaire, only: [:show, :edit, :update, :destroy, :check_in, :update_acc_status]

respond_to :html, :json

Expand Down Expand Up @@ -95,14 +95,14 @@ def check_in
redirect_to index_redirect_path
end

def convert_to_admin
user = @questionnaire.user
@questionnaire.destroy
user.update_attributes(role: :admin)
redirect_to edit_manage_user_path(user)
end

def destroy
if @questionnaire.is_bus_captain
directors = User.where(role: :director)
directors.each do |user|
StaffMailer.bus_captain_left(@questionnaire.bus_list_id, @questionnaire.user_id, user.id).deliver_later
end
end

@questionnaire.destroy
respond_with(:manage, @questionnaire)
end
Expand Down
1 change: 1 addition & 0 deletions app/controllers/manage/stats_controller.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
class Manage::StatsController < Manage::ApplicationController
before_action :require_director_or_organizer

respond_to :html, :json

Expand Down
15 changes: 6 additions & 9 deletions app/controllers/manage/trackable_events_controller.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
class Manage::TrackableEventsController < Manage::ApplicationController
skip_before_action :require_admin_or_limited_admin
before_action :require_admin_or_limited_admin_or_event_tracking

before_action :set_trackable_event, only: [:show, :edit, :update, :destroy]
before_action :scope_limited_admin_access, only: [:edit, :update, :destroy]
before_action :scope_organizer_access, only: [:edit, :update, :destroy]

respond_to :html, :json

Expand Down Expand Up @@ -81,13 +78,13 @@ def trackable_event_params
params.require(:trackable_event).permit(:band_id, :trackable_tag_id)
end

# Permit limited-access admins (overrides Manage::ApplicationController#limit_write_access_to_admins)
def limit_write_access_to_admins
# Permit limited-access directors (overrides Manage::ApplicationController#limit_write_access_to_directors)
def limit_write_access_to_directors
end

# If the user isn't a full admin, scope changes only to those they created
def scope_limited_admin_access
return if current_user.admin? || @trackable_event.blank? || @trackable_event.user.blank?
# If the user isn't a director, scope changes only to those they created
def scope_organizer_access
return if current_user.director? || @trackable_event.blank? || @trackable_event.user.blank?
redirect_to manage_trackable_events_path, notice: 'You may not view events you did not create.' if @trackable_event.user != current_user
end
end
3 changes: 0 additions & 3 deletions app/controllers/manage/trackable_tags_controller.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
class Manage::TrackableTagsController < Manage::ApplicationController
skip_before_action :require_admin_or_limited_admin
before_action :require_admin_or_limited_admin_or_event_tracking

before_action :set_trackable_tag, only: [:show, :edit, :update, :destroy]

respond_to :html, :json
Expand Down
8 changes: 4 additions & 4 deletions app/controllers/manage/users_controller.rb
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
class Manage::UsersController < Manage::ApplicationController
before_action :require_full_admin
before_action :require_director
before_action :find_user, only: [:show, :edit, :update, :destroy]

respond_to :html, :json

def index
respond_with(:manage, User.where(role: [:admin, :admin_limited_access, :event_tracking]))
respond_with(:manage, User.where(role: [:director, :organizer, :volunteer]))
end

def user_datatable
render json: UserDatatable.new(params, view_context: view_context)
end

def admin_datatable
render json: AdminDatatable.new(params, view_context: view_context)
def staff_datatable
render json: StaffDatatable.new(params, view_context: view_context)
end

def show
Expand Down
9 changes: 8 additions & 1 deletion app/controllers/questionnaires_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ def create
if current_user.reload.questionnaire.present?
return redirect_to questionnaires_path, notice: 'Application already exists.'
end
return unless HackathonConfig['accepting_questionnaires']
@questionnaire = Questionnaire.new(convert_school_name_to_id(questionnaire_params))
@questionnaire.user_id = current_user.id

Expand Down Expand Up @@ -93,8 +94,14 @@ def update
# DELETE /apply
# DELETE /apply.json
def destroy
@questionnaire.destroy
if @questionnaire.is_bus_captain
directors = User.where(role: :director)
directors.each do |user|
StaffMailer.bus_captain_left(@questionnaire.bus_list_id, @questionnaire.user_id, user.id).deliver_later
end
end

@questionnaire.destroy
respond_to do |format|
format.html { redirect_to questionnaires_url }
format.json { head :no_content }
Expand Down
15 changes: 15 additions & 0 deletions app/controllers/rsvps_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ def deny
# rubocop:disable CyclomaticComplexity
# rubocop:disable PerceivedComplexity
def update
# save to check if bus status changes after rsvp
bus = @questionnaire.bus_list_id
acc_status = @questionnaire.acc_status

unless @questionnaire.update_attributes(params.require(:questionnaire).permit(:agreement_accepted, :phone))
flash[:alert] = @questionnaire.errors.full_messages.join(", ")
redirect_to rsvp_path
Expand All @@ -58,6 +62,17 @@ def update
update_acc_status
update_bus_list

bus_after_rsvp = @questionnaire.bus_list_id
acc_status_after_rsvp = @questionnaire.acc_status

if bus != nil && (acc_status != acc_status_after_rsvp || bus != bus_after_rsvp) && @questionnaire.is_bus_captain == true
@questionnaire.is_bus_captain = false
directors = User.where(role: :director)
directors.each do |user|
StaffMailer.bus_captain_left(@questionnaire.bus_list_id, @questionnaire.user_id, user.id).deliver_later
end
end

unless @questionnaire.save
flash[:alert] = @questionnaire.errors.full_message.join(", ")
redirect_to rsvp_path
Expand Down
4 changes: 2 additions & 2 deletions app/datatables/questionnaire_datatable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def note(record)

def bus_captain(record)
return "No" unless record.bus_list_id?
return record.is_bus_captain? ? '<span class="badge badge-success">Yes</span>' : "No" unless current_user.admin?
return record.is_bus_captain? ? '<span class="badge badge-success">Yes</span>' : "No" unless current_user.director?

if record.is_bus_captain?
link_to("Remove", toggle_bus_captain_manage_bus_list_path(record.bus_list_id, questionnaire_id: record.id, bus_captain: "0"), method: "post", class: "text-danger")
Expand All @@ -47,7 +47,7 @@ def bus_captain(record)
def data
records.map do |record|
{
bulk: current_user.admin? ? "<input type=\"checkbox\" data-bulk-row-edit=\"#{record.id}\">".html_safe : "",
bulk: current_user.director? ? "<input type=\"checkbox\" data-bulk-row-edit=\"#{record.id}\">".html_safe : "",
link: link_to('<i class="fa fa-search"></i>'.html_safe, manage_questionnaire_path(record)),
note: note(record),
id: record.id,
Expand Down
Loading

0 comments on commit a5644e6

Please sign in to comment.