payment_settup/app/views/admin/sites/payment_log.html.erb

90 lines
2.9 KiB
Plaintext
Raw Normal View History

2020-05-28 14:04:48 +00:00
<%= stylesheet_link_tag "lib/main-list" %>
<%= stylesheet_link_tag "lib/list-check.css" %>
<%= stylesheet_link_tag "lib/togglebox.css" %>
<%= javascript_include_tag "lib/list-check" %>
<%= javascript_include_tag "lib/site_set" %>
<style type="text/css">
.main-list tr:hover:nth-child(n) > td {
background-color: #c8e1ed;
}
</style>
<div class="tab-pane fade in active list-check">
<p class="">
<%= link_to(content_tag(:i, nil, :class => "icons-trash"), '#', :class => "btn list-active-btn disabled", :rel => admin_site_delete_payment_log_path) %>
</p>
<form class="form-horizontal main-forms">
<fieldset>
<table class="table main-list table-striped">
<thead>
<tr>
<th class="listCheckHead">
<input type="checkbox" name="to_delete[]" value="b">
</th>
<th><%= t('payment_settup.trading_module') %></th>
<th><%= t('payment_settup.orderNumber') %></th>
<th><%= t('payment_settup.user') %></th>
<th><%= t('payment_settup.amount') %></th>
<th><%= t('payment_settup.pay_type') %></th>
<th><%= t('payment_settup.account') %></th>
<th><%= t('payment_settup.trading_time') %></th>
<th><%= t('payment_settup.trading_result') %></th>
</tr>
</thead>
<tbody id="payment_logs">
<%= @logs.collect do |log|
module_name = log.module_name.blank? ? 'payment' : log.module_name
result = 'payment_settup.' + log.result.inspect
member = log.get_member
member_name = member.name if !member.nil?
pay_type = t("payment_settup.#{log.pay_type}")
if is_manager?
td1 = check_box_tag 'to_delete[]', log.id, false,:id => '', :class => "list-check"
end
"<tr id='#{log.id}'>
<td>
#{td1}
</td>
<td>
#{t(module_name)}
</td>
<td>
#{log.orderNumber}
</td>
<td>
#{member_name}
</td>
<td>
#{log.amount}
</td>
<td>
#{pay_type}
</td>
<td>
#{log.account}
</td>
<td>
#{log.created_at.strftime('%Y/%m/%d %H:%M')}
</td>
<td>
#{t(result)}
</td>
</tr>"
end.join('').html_safe %>
</tbody>
</table>
</fieldset>
</form>
</div>
<div id="dialog" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="Delete item" aria-hidden="true">
<div class="modal-header">
<a class="close" data-dismiss="modal">×</a>
<h3><%= t(:sure?) %></h3>
</div>
<div class="modal-body">
<span class="text-warning text-center"><%= t(:this_action_can_not_be_restore) %></span>
</div>
<div class="modal-footer">
<button class="btn" data-dismiss="modal" aria-hidden="true"><%= t(:close) %></button>
<button class="delete-item btn btn-danger"><%= t(:delete_) %></button>
</div>
</div>