|
|
|
@ -1,10 +1,10 @@
|
|
|
|
|
<span id="attachments_fields">
|
|
|
|
|
<% if defined?(container) && container && container.saved_attachments %>
|
|
|
|
|
<% container.saved_attachments.each_with_index do |attachment, i| %>
|
|
|
|
|
<span id="attachments_p<%= i %>">
|
|
|
|
|
<span style="width:100px;"><%= text_field_tag("attachments[p#{i}][filename]", attachment.filename, :class => 'filename', :maxlength => 10)%>
|
|
|
|
|
</span>
|
|
|
|
|
<%= text_field_tag("attachments[p#{i}][description]", attachment.description, :maxlength => 155, :placeholder => l(:label_optional_description), :class => 'description') +
|
|
|
|
|
<% container.attachments.each_with_index do |attachment, i| %>
|
|
|
|
|
<span id="attachments_p<%= i %>" class="attachment">
|
|
|
|
|
<%= text_field_tag("attachments[p#{i}][filename]", attachment.filename, :class => 'filename readonly', :readonly=>'readonly')%>
|
|
|
|
|
|
|
|
|
|
<%= text_field_tag("attachments[p#{i}][description]", attachment.description, :maxlength => 255, :placeholder => l(:label_optional_description), :class => 'description', :style=>"display: inline-block;") +
|
|
|
|
|
link_to(' '.html_safe, attachment_path(attachment, :attachment_id => "p#{i}", :format => 'js'), :method => 'delete', :remote => true, :class => 'remove-upload') %>
|
|
|
|
|
<%= hidden_field_tag "attachments[p#{i}][token]", "#{attachment.token}" %>
|
|
|
|
|
</span>
|
|
|
|
|