ルートを壊さずにパラメーターを show アクションに渡す方法がわかりません。私はこれを試しています:
<%= link_to image_tag('excell.jpg'), affiliate_path(id: @affiliate.id, format: 'xls') %>
しかし、私はこのエラーが発生します:
No route matches {:action=>"show", :controller=>"affiliates", :id=>nil, :format=>"xls"}
IDが渡されないのはなぜですか?