forked from bofh/fetsite
attachment new version
This commit is contained in:
30
app/views/attachments/_attachment_list.html.erb
Normal file
30
app/views/attachments/_attachment_list.html.erb
Normal file
@@ -0,0 +1,30 @@
|
||||
<table class="table-striped" id="<%= Attachment.parent_attachment_list_id(parent) %>">
|
||||
<% attachment_list.each do |a| %>
|
||||
<tr>
|
||||
<td>
|
||||
<%= fa_icon("tag") if a.flag_titlepic %>
|
||||
<%= link_to a.datei.url do %>
|
||||
<%= render partial:"attachments/attachment_new", object: a %>
|
||||
<% end %>
|
||||
</td>
|
||||
<% if editor %>
|
||||
<td>
|
||||
<div class="dropdown">
|
||||
<a class="dropdown-toggle" data-toggle="dropdown" href="#"><%= fa_icon("chevron-down") %> Actions</a>
|
||||
<ul class="dropdown-menu">
|
||||
<li>
|
||||
<%= link_to fa_icon("tag")+" Titlepic", set_titlepic_attachment_path(a,:params=>{:titlepic=>true}), remote: true %>
|
||||
</li>
|
||||
<li>
|
||||
<%= link_to ff_icon("icon-pencil")+" Edit", edit_attachment_path(a) %>
|
||||
</li>
|
||||
<li>
|
||||
<%= link_to fa_icon("trash")+" Delete", attachment_path(a), method: "DELETE", confirm: "Sure?" , class: "btn-danger " %>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</td>
|
||||
<% end %>
|
||||
</tr>
|
||||
<% end %>
|
||||
</table>
|
||||
Reference in New Issue
Block a user