@ -60,7 +60,6 @@ class FormController < ApplicationController
end
private
def restore_error_field_values
@ -143,7 +142,7 @@ private
def new_log_request_referrer?
request.referer.split("/").include?("new")
request.referer&.split("/").include?("new")
def is_referrer_check_answers?
@ -101,7 +101,7 @@ private
@log = LettingsLog.find_by(id: params[:id])
def post_create_redirect_url(log)
lettings_log_url(log)
def post_create_redirect_url
new_log_lettings_logs_path
@ -15,7 +15,7 @@ private
respond_to do |format|
format.html do
redirect_to(request.path.include?("sales") ? new_log_sales_logs_path : new_log_lettings_logs_path)
redirect_to(post_create_redirect_url)
format.json do
if log.save
@ -40,8 +40,8 @@ class SalesLogsController < LogsController
sales_log_url(log)
new_log_sales_logs_path
def permitted_log_params