66 lines
3.1 KiB
Plaintext
66 lines
3.1 KiB
Plaintext
|
<% # encoding: utf-8 %>
|
||
|
<script type="text/javascript">
|
||
|
if(document.querySelectorAll("#orbit-bar").length==0) location.reload();
|
||
|
</script>
|
||
|
<% content_for :right_nav do %>
|
||
|
<div class="nav nav-pills filter-nav pull-right">
|
||
|
<p><a class="btn btn-primary" href="<%= export_admin_nkuht_donates_path %>?format=xlsx" role="button"><%= t('nkuht_donate.export_csv') %></a></p>
|
||
|
</div>
|
||
|
<% end %>
|
||
|
<table class="table main-list">
|
||
|
<thead>
|
||
|
<tr class="sort-header">
|
||
|
<% @table_fields.each do |f| %>
|
||
|
<%= thead(f) %>
|
||
|
<% end %>
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
<% @nkuht_donates.each do |nkuht_donate| %>
|
||
|
<tr>
|
||
|
<td><%= nkuht_donate.donation_payment_number %></td>
|
||
|
<td><%= nkuht_donate.donation_serial_date %></td>
|
||
|
<td>
|
||
|
<%= nkuht_donate.name %>
|
||
|
<div class="quick-edit">
|
||
|
<ul class="nav nav-pills">
|
||
|
<% if can_edit_or_delete?(nkuht_donate) %>
|
||
|
<li><a href="/admin/nkuht_donates/<%=nkuht_donate.id.to_s%>/edit?page=<%=params['page']%>"><%= t(:edit) %></a></li>
|
||
|
<li><a href="#" class="delete text-error" rel="/admin/nkuht_donates/<%=nkuht_donate.id.to_s%>"><%= t(:delete_) %></a></li>
|
||
|
<li>
|
||
|
<%= link_to t('nkuht_donate.donation_write_off_status'), set_write_off_admin_nkuht_donate_path(nkuht_donate,:page=>params['page']), data: { confirm: t('sure?') }, :controller => "set_write_off", :action => "test_send_email" if nkuht_donate.donation_write_off_status.blank? %>
|
||
|
</li>
|
||
|
<li>
|
||
|
<%= link_to t('nkuht_donate.receipt_notice'), page_for_donate_receipt_notice(nkuht_donate), :target => "_blank" if nkuht_donate.donation_way == '4' || nkuht_donate.donation_way == '5' %>
|
||
|
</li>
|
||
|
<% end %>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</td>
|
||
|
<td><%= number_to_currency(nkuht_donate.donation_amount, unit: '', precision: 0) %></td>
|
||
|
<td><%= t("nkuht_donate_ways.ways#{nkuht_donate.donation_way}") if !nkuht_donate.donation_way.blank? %></td>
|
||
|
<td><%= nkuht_donate.donate_public.blank? ? t('nkuht_donate.donate_public_no_') : t('nkuht_donate.donate_public_yes_') %></td>
|
||
|
<td><%= nkuht_donate.nkuht_donate_unit.title if !nkuht_donate.nkuht_donate_unit.blank? %></td>
|
||
|
<td>
|
||
|
<%=
|
||
|
if !nkuht_donate.nkuht_donate_use.blank?
|
||
|
if nkuht_donate.nkuht_donate_use.title == '其他' || nkuht_donate.nkuht_donate_use.title == 'Other'
|
||
|
"#{nkuht_donate.nkuht_donate_use.title}(#{nkuht_donate.donation_use_other})"
|
||
|
else
|
||
|
nkuht_donate.nkuht_donate_use.title
|
||
|
end
|
||
|
end
|
||
|
%>
|
||
|
</td>
|
||
|
<td><%= nkuht_donate.donation_payment_status ? t('nkuht_donate.yes_') : t('nkuht_donate.no_') %></td>
|
||
|
<td><%= nkuht_donate.donation_write_off_status ? t('nkuht_donate.yes_') : t('nkuht_donate.no_') %></td>
|
||
|
</tr>
|
||
|
<% end %>
|
||
|
</tbody>
|
||
|
</table>
|
||
|
|
||
|
<%=
|
||
|
content_tag :div, class: "bottomnav clearfix" do
|
||
|
content_tag :div, paginate(@nkuht_donates), class: "pagination pagination-centered"
|
||
|
end
|
||
|
%>
|