Class: UffizziCore::Api::Cli::V1::Projects::ApplicationController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- UffizziCore::Api::Cli::V1::Projects::ApplicationController
show all
- Defined in:
- app/controllers/uffizzi_core/api/cli/v1/projects/application_controller.rb
Instance Method Summary
collapse
Instance Method Details
#policy_context ⇒ Object
12
13
14
|
# File 'app/controllers/uffizzi_core/api/cli/v1/projects/application_controller.rb', line 12
def policy_context
UffizziCore::ProjectContext.new(current_user, user_access_module, resource_project, resource_account, params)
end
|
#resource_account ⇒ Object
8
9
10
|
# File 'app/controllers/uffizzi_core/api/cli/v1/projects/application_controller.rb', line 8
def resource_account
@resource_account ||= resource_project.account
end
|
#resource_project ⇒ Object
4
5
6
|
# File 'app/controllers/uffizzi_core/api/cli/v1/projects/application_controller.rb', line 4
def resource_project
@resource_project ||= current_user.projects.find_by!(slug: params[:project_slug])
end
|