Merge branches 'dev_aliyun' and 'develop' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_aliyun

dev_forum
杨树明 5 years ago
commit b5b68ac56d

@ -2,8 +2,8 @@ class AddDepartmentAppliesController < ApplicationController
before_action :require_login, :check_auth
def create
CreateAddDepartmentApplyService.call(current_user, create_params)
render_ok
department = CreateAddDepartmentApplyService.call(current_user, create_params)
render_ok(id: department.id)
rescue CreateAddDepartmentApplyService::Error => ex
render_error(ex.message)
end

@ -2,8 +2,8 @@ class AddSchoolAppliesController < ApplicationController
before_action :require_login, :check_auth
def create
CreateAddSchoolApplyService.call(current_user, create_params)
render_ok
school = CreateAddSchoolApplyService.call(current_user, create_params)
render_ok(id: school.id)
rescue CreateAddSchoolApplyService::Error => ex
render_error(ex.message)
end

@ -38,6 +38,6 @@ class CreateAddDepartmentApplyService < ApplicationService
message.save(validate: false)
end
school
department
end
end

Loading…
Cancel
Save