课程资源库导入资源样式修改

This commit is contained in:
Tim 2016-05-13 14:23:51 +08:00
parent 979598f334
commit 1833f15e19
1 changed files with 18 additions and 18 deletions

View File

@ -1,19 +1,19 @@
<%= form_tag( url_for({:controller => 'users', :action => 'import_into_container',
:mul_id => @resource_id,
:mul_type => @resource_type}),
:method => 'post', :id => 'resource_import_container_form') do %>
<% @attachments.each do |attach| %>
<ul class="subjectRow">
<li class="subjectName fl hidden">
<label>
<input name="checkbox1[]" type="checkbox" data-has-history="<%= attach.attachment_histories.count == 0 ? 'N' : 'Y' %>" data-deleteble="<%= User.current.id ==attach.author_id ? 'Y' : 'N' %>" onclick="checkAllBox($(this));" value="<%= attach.id%>" class="mr5" style="vertical-align:middle;" />
<span><%= link_to truncate(attach.filename, :length => 30), download_named_attachment_path(attach.id, attach.filename), :title => attach.filename%></span>
</label>
</li>
<li class="subjectType fl"><%= get_resource_type(attach.container_type)%></li>
<li class="subjectCount fl hidden"><%= (number_to_human_size(attach.filesize)).gsub("ytes", "") %></li>
<li class="subjectPublisher fl"><%=User.find(attach.author_id).realname.blank? ? User.find(attach.author_id).nickname : User.find(attach.author_id).realname %></li>
<li class="fl subjectDate"><%= format_date(attach.created_on) %></li>
</ul>
<% end %>
<%= form_tag( url_for({:controller => 'users', :action => 'import_into_container',
:mul_id => @resource_id,
:mul_type => @resource_type}),
:method => 'post', :id => 'resource_import_container_form') do %>
<% @attachments.each do |attach| %>
<ul class="subjectRow">
<li class="subjectName fl hidden">
<label>
<input name="checkbox1[]" type="checkbox" data-has-history="<%= attach.attachment_histories.count == 0 ? 'N' : 'Y' %>" data-deleteble="<%= User.current.id ==attach.author_id ? 'Y' : 'N' %>" onclick="checkAllBox($(this));" value="<%= attach.id%>" class="mr5" style="vertical-align:middle;" />
<span><%= link_to truncate(attach.filename, :length => 30), download_named_attachment_path(attach.id, attach.filename), :title => attach.filename%></span>
</label>
</li>
<li class="subjectType fl"><%= get_resource_type(attach.container_type)%></li>
<li class="subjectCount fl hidden"><%= (number_to_human_size(attach.filesize)).gsub("ytes", "") %></li>
<li class="subjectPublisher fl hidden"><%=User.find(attach.author_id).realname.blank? ? User.find(attach.author_id).nickname : User.find(attach.author_id).realname %></li>
<li class="fl subjectDate"><%= format_date(attach.created_on) %></li>
</ul>
<% end %>
<% end %>