4/debian-10/plugins/easy_gantt/app/controllers/easy_gantt_controller.rb
# You cannot use issue.reschedule_on because it will
# also set start_date which is not desirable !!!
You cannot use issue.reschedule_on because it will
also set start_date which is not desirable
You cannot use issue . reschedule_on because it will also set start_date which is not desirable
def reschedule_project
    begin
      project = Project.find(params[:id])
    rescue ActiveRecord::RecordNotFound
      render_404
      return
    end
    project.gantt_reschedule(params[:days].to_i)
    respond_to do |format|
      format.api { render_api_ok }
    end
  end
def reschedule_project begin project = Project . find ( params [ :id ] ) rescue ActiveRecord :: RecordNotFound render_404 return end project . gantt_reschedule ( params [ :days ] . to_i ) respond_to do | format | format . api { render_api_ok } end end
You cannot use issue.reschedule_on because it will
also set start_date which is not desirable !
You cannot use issue . reschedule_on because it will also set start_date which is not desirable !
# Do not used callback `find_project` because it will test access rights # to project context. Method wont work if project does not have gantt enabled.