Class: UffizziCore::Api::Cli::V1::Projects::DeploymentsPolicy

Inherits:
UffizziCore::ApplicationPolicy
  • Object
show all
Defined in:
app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb

Instance Method Summary collapse

Instance Method Details

#create?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb', line 12

def create?
  context.user_access_module.admin_or_developer_access_to_project?(context.user, context.project)
end

#deploy_containers?Boolean

Returns:

  • (Boolean)


24
25
26
# File 'app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb', line 24

def deploy_containers?
  context.user_access_module.admin_or_developer_access_to_project?(context.user, context.project)
end

#destroy?Boolean

Returns:

  • (Boolean)


20
21
22
# File 'app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb', line 20

def destroy?
  context.user_access_module.admin_or_developer_access_to_project?(context.user, context.project)
end

#index?Boolean

Returns:

  • (Boolean)


4
5
6
# File 'app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb', line 4

def index?
  context.user_access_module.any_access_to_project?(context.user, context.project)
end

#show?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb', line 8

def show?
  context.user_access_module.any_access_to_project?(context.user, context.project)
end

#update?Boolean

Returns:

  • (Boolean)


16
17
18
# File 'app/policies/uffizzi_core/api/cli/v1/projects/deployments_policy.rb', line 16

def update?
  context.user_access_module.admin_or_developer_access_to_project?(context.user, context.project)
end