Added restriction to group policy. Create link hidden for non-pro.

This commit is contained in:
2458773093
2019-08-01 19:46:17 +03:00
parent 8c837a0c36
commit 3fa8eb1bac
3 changed files with 10 additions and 2 deletions

View File

@@ -5,6 +5,10 @@ class GroupPolicy < ApplicationPolicy
true
end
def create?
admin? or current_account.is_pro
end
def update?
if admin?
true