fix design upload

This commit is contained in:
Matthew Fu 2011-07-20 09:58:24 +08:00
parent c48a11d9f5
commit 612ed629bc
2 changed files with 1 additions and 2 deletions

View File

@ -12,7 +12,6 @@ $('input.multi_files').change(function(){
$(this).prev("ul").append("<li>"+$(this).val()+"</li>"); $(this).prev("ul").append("<li>"+$(this).val()+"</li>");
new_node =$(this).clone(); new_node =$(this).clone();
new_node.css("display","none"); new_node.css("display","none");
//new_node.val("asd");
$(this).parent().append(new_node); $(this).parent().append(new_node);
$(this).val(""); $(this).val("");
}); });

View File

@ -36,7 +36,7 @@
<a class="remove_mark" href="#">Del</a></li> <a class="remove_mark" href="#">Del</a></li>
<% end %> <% end %>
</ul> </ul>
<%= fields_for "design[stylesheet][]", @design, :index => nil do |f| %> <%= fields_for "design[stylesheets][]", @design, :index => nil do |f| %>
<%= f.file_field :file ,{:class=>"multi_files",:rtype=>"stylesheets"}%> <%= f.file_field :file ,{:class=>"multi_files",:rtype=>"stylesheets"}%>
<% end %> <% end %>
</p> </p>