You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
353 B
16 lines
353 B
6 years ago
|
class ReachCriteriaController < Ecs::BaseController
|
||
|
before_action :check_major_manager_permission!, only: [:create]
|
||
|
|
||
|
def create
|
||
|
reach_criteria = params[:reach_criteria].to_f
|
||
|
|
||
|
if reach_criteria.zero?
|
||
|
render_error('必须大于0')
|
||
|
return
|
||
|
end
|
||
|
|
||
|
current_year.update!(calculation_value: reach_criteria)
|
||
|
|
||
|
render_ok
|
||
|
end
|
||
|
end
|