去除隐藏项目课程内的内容, 下载文件名缩略显示鼠标移上去浮动显示所有 完整文件名
This commit is contained in:
parent
54aef57287
commit
41fefd0b37
|
@ -11,11 +11,11 @@ class StoresController < ApplicationController
|
|||
def index
|
||||
# @projects_attach = project_classification(0).take(LIMIT)
|
||||
# @courses_attach = project_classification(1).take(LIMIT)
|
||||
@projects_attach = Attachment.includes(:project).where("projects.project_type=?", 0).
|
||||
@projects_attach = Attachment.includes(:project).where("projects.project_type=? AND projects.is_public = ?", 0, 1).
|
||||
reorder("#{Attachment.table_name}.downloads DESC").
|
||||
limit(LIMIT)
|
||||
|
||||
@courses_attach = Attachment.includes(:project).where("projects.project_type=?", 1).
|
||||
@courses_attach = Attachment.includes(:project).where("projects.project_type=? AND projects.is_public = ?", 1, 1).
|
||||
reorder("#{Attachment.table_name}.downloads DESC").
|
||||
limit(LIMIT)
|
||||
@homeworks_attach = Attachment.where("container_type = 'HomeworkAttach'").
|
||||
|
|
|
@ -87,7 +87,7 @@
|
|||
<tbody>
|
||||
<% k.each do |c1|%>
|
||||
<tr class="<%= cycle 'odd', 'even' %>">
|
||||
<td class="filename" style="width:62%;"><%= link_to c1.filename, (attachFromUrl c1) %> </td>
|
||||
<td class="filename" style="width:62%;"><%= link_to c1.filename, (attachFromUrl c1), {:title => c1.filename} %> </td>
|
||||
<td style="width:19%;"><%= c1.downloads %> </td>
|
||||
<td class="filename" style="width:19%;"><%= link_to_attachment c1, {:text => "下载"}%></td>
|
||||
</tr>
|
||||
|
|
Loading…
Reference in New Issue