43 lines
1.4 KiB
Plaintext
43 lines
1.4 KiB
Plaintext
<script>
|
|
if(document.querySelectorAll("#orbit-bar").length==0) location.reload();
|
|
</script>
|
|
|
|
<table class="table main-list">
|
|
<thead>
|
|
<tr class="sort-header">
|
|
<% @table_fields.each do |f| %>
|
|
<%= thead(f) %>
|
|
<% end %>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<% @property_items.each do |property_item| %>
|
|
<tr>
|
|
<td>
|
|
<a href="/zh_tw/property" target="_blank"><%= property_item.title %></a>
|
|
<div class="quick-edit">
|
|
<ul class="nav nav-pills">
|
|
<% if can_edit_or_delete?(property_item) %>
|
|
<li><a href="/<%= I18n.locale.to_s %>/admin/property_items/<%= property_item.id.to_s %>/edit"><%= t(:edit) %></a></li>
|
|
<li><a href="<%=admin_property_item_path(property_item.id.to_s)%>" data-method="delete" data-confirm="Are you sure?"><%= t(:delete_) %></a></li>
|
|
<% end %>
|
|
</ul>
|
|
</div>
|
|
</td>
|
|
<td>
|
|
<%= property_item.category.title rescue "" %>
|
|
<% if (property_item.category.disable rescue false) %>
|
|
<span class='label'><%= t(:disabled) %></span>
|
|
<% end %>
|
|
</td>
|
|
<td><%= format_value property_item.item_date rescue nil %></td>
|
|
</tr>
|
|
<% end %>
|
|
</tbody>
|
|
</table>
|
|
|
|
<%=
|
|
content_tag :div, class: "bottomnav clearfix" do
|
|
content_tag :div, paginate(@property_items), class: "pagination pagination-centered"
|
|
end
|
|
%> |