mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-04-01 03:55:44 +00:00
Added logic to delegate tournament access
This commit is contained in:
@@ -1,7 +1,10 @@
|
||||
class StaticPagesController < ApplicationController
|
||||
|
||||
def my_tournaments
|
||||
@tournaments = current_user.tournaments.sort_by{|t| t.daysUntil}
|
||||
tournaments_created = current_user.tournaments
|
||||
tournaments_delegated = current_user.delegated_tournaments
|
||||
all_tournaments = tournaments_created + tournaments_delegated
|
||||
@tournaments = all_tournaments.sort_by{|t| t.daysUntil}
|
||||
end
|
||||
|
||||
def not_allowed
|
||||
|
||||
Reference in New Issue
Block a user