<% org_attachs.each do |attach| %>
    <div class="row-ziyuan fl">
      <%= link_to image_tag(url_to_avatar(attach.author),:width => "40", :height => "40"), user_path(attach.author), :class => "fl user-img" %>
      <!--<a href="#" class="fl user-img" ><img src="images/detailimg4.jpg" /></a>-->
      <div class="ziyuan-box fl">
        <%= link_to truncate(attach.filename,length: 35, omission: '...'),
                    download_named_attachment_path(attach.id, attach.filename),
                    :title => attach.filename+"\n"+attach.description.to_s, :style => "overflow: hidden; white-space: nowrap;text-overflow: ellipsis;", :class => "fl ziyuan-title"  %>
        <p class="fl"><span >上传时间：<%= format_date attach.created_on %></span><span>类型：<%= attach.tag_list[0] %></span><span> 下载次数：<%= attach.downloads%></span> <span>引用：<%= attach.quotes.nil? ? 0:attach.quotes  %></span></p>
      </div>
      <%= link_to "下载", download_named_attachment_path(attach.id, attach.filename), :class => "download-btn fl"  %>
      <div class="cl"></div>
    </div><!--row-ziyuan end-->
<% end %>