Do not allow signed in users to registor unless registration is open
This commit is contained in:
parent
7e4d91adaf
commit
7822a8d4e3
2 changed files with 11 additions and 5 deletions
|
|
@ -72,6 +72,10 @@ class Ability
|
|||
|
||||
can :manage, Registration, user_id: user.id
|
||||
|
||||
can [:new, :create], Registration do |registration|
|
||||
registration.conference.registration_open?
|
||||
end
|
||||
|
||||
can :index, Ticket
|
||||
can :manage, TicketPurchase, user_id: user.id
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue