フラッシュタイプの指定
# in application_controller.rb
class ApplicationController < ActionController::Base
add_flash_types :タイプ名
end
# controller
redirect_to xxx, タイプ名: "メッセージ"
# view
<%= タイプ名 %>
# in application_controller.rb
class ApplicationController < ActionController::Base
add_flash_types :warning
end
# controller
redirect_to user_path(@user), warning: "Incomplete profile"
# view
<%= warning %>