mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-03 11:50:49 +08:00
init project
This commit is contained in:
14
app/controllers/projects/project_applies_controller.rb
Normal file
14
app/controllers/projects/project_applies_controller.rb
Normal file
@@ -0,0 +1,14 @@
|
||||
class Projects::ProjectAppliesController < Projects::BaseController
|
||||
def create
|
||||
project = Projects::ApplyJoinService.call(current_user, create_params)
|
||||
render_ok(project_id: project.id)
|
||||
rescue Projects::ApplyJoinService::Error => ex
|
||||
render_error(ex.message)
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def create_params
|
||||
params.permit(:code, :role)
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user