implement duplication

This commit is contained in:
Bilal
2020-07-13 21:45:00 +02:00
parent 0741f8a230
commit e41d7603d0
7 changed files with 55 additions and 8 deletions

View File

@@ -24,13 +24,17 @@ class ContractTemplatePolicy < ApplicationPolicy
end
def edit?
create?
record.editable? && create?
end
def update?
edit?
end
def duplicate?
create?
end
def import?
if user.account_manager?
record.project.account = user.account