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
  • Loading branch information
peterkos committed Sep 21, 2020
1 parent 5e03082 commit bee8ee7
Show file tree
Hide file tree
Showing 80 changed files with 1,066 additions and 283 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", "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
7 changes: 7 additions & 0 deletions app/controllers/manage/questionnaires_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,13 @@ def check_in
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
8 changes: 7 additions & 1 deletion app/controllers/questionnaires_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -94,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
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
class AdminDatatable < ApplicationDatatable
class StaffDatatable < ApplicationDatatable
def_delegators :@view, :link_to, :manage_user_path, :bold, :display_datetime

def view_columns
Expand Down Expand Up @@ -43,6 +43,6 @@ def data
end

def get_raw_records
User.where(role: [:admin, :admin_limited_access, :event_tracking])
User.where(role: [:director, :organizer, :volunteer])
end
end
Loading

0 comments on commit bee8ee7

Please sign in to comment.