推測もできない理由で、Rails アプリが機能しなくなりました。Railsコードは何も変更していないので、ブラウザに関するものかもしれません。
Simple_form によって生成された単純なフォーム:
<%= simple_form_for @order, :url => fillparameters_order_path(@order), :remote => true do |f| %>
<%= f.association :aspectRatio, collection: @order.project.aspect_ratios %>
<%= f.input :client_email, :as => :string %>
<%= f.input :soundtrack, :as => :file %>
<%= f.input :project_id, :as => :hidden %>
<%= f.button :submit %>
<% end %>
以下を生成します。
form id="edit_order_4" class="simple_form edit_order" novalidate="novalidate" method="post" enctype="multipart/form-data" data-remote="true" action="/orders/4/fillparameters" accept-charset="UTF-8"
<input id="order_soundtrack" class="file optional" type="file" name="order[soundtrack]">
<input class="btn" type="submit" value="Send!" name="commit">
もちろん、他の入力に加えて。
しかし、コミット ボタンを押した後、Firebug コンソールと Webrick ログは、送信されたものはすべてファイル フィールド以外のものであることを示しています。
Started PUT "/orders/4/fillparameters" for 127.0.0.1 at 2013-08-04 21:00:03 +0900
Processing by OrdersController#fillparameters as JS
Parameters: {
"utf8" => "✓",
"authenticity_token" => "VpddWLzi7Czzl0L+gbd5wVfjbJ1pQnfI53L86BwbH/E=",
"order" => {
"aspect_ratio_id" => "1",
"client_email" => "****@gmail.com",
"project_id" => "1"
},
"commit" => "Send!",
"id" => "4"
}
アイデアはありますか?