Format numbers on admin donations page
And fix the wrong unit display in the user donations list.
This commit is contained in:
parent
5e2d5c3b28
commit
4a65573934
@ -5,7 +5,7 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<th>User</th>
|
||||
<th>Amount BTC (sats)</th>
|
||||
<th>Amount BTC</th>
|
||||
<th>in EUR</th>
|
||||
<th>in USD</th>
|
||||
<th>Public name</th>
|
||||
@ -18,9 +18,9 @@
|
||||
<% @donations.each do |donation| %>
|
||||
<tr>
|
||||
<td><%= donation.user.cn %></td>
|
||||
<td><%= donation.amount_sats %></td>
|
||||
<td><%= donation.amount_eur %></td>
|
||||
<td><%= donation.amount_usd %></td>
|
||||
<td><%= sats_to_btc donation.amount_sats %> BTC</td>
|
||||
<td><%= number_to_currency donation.amount_eur / 100, unit: "" %></td>
|
||||
<td><%= number_to_currency donation.amount_usd / 100, unit: "" %></td>
|
||||
<td><%= donation.public_name %></td>
|
||||
<td><%= donation.paid_at ? donation.paid_at.strftime("%Y-%m-%d") : "" %></td>
|
||||
<td><%= link_to 'Show', admin_donation_path(donation) %></td>
|
||||
|
@ -18,7 +18,7 @@
|
||||
<%= sats_to_btc donation.amount_sats %> BTC
|
||||
</p>
|
||||
<p class="amounts-fiat">
|
||||
(~ <%= number_to_currency donation.amount_eur / 100 %> EUR)
|
||||
(~ <%= number_to_currency donation.amount_eur / 100, unit: "" %> EUR)
|
||||
</p>
|
||||
<p class="public-name">
|
||||
<% if donation.public_name.present? %>
|
||||
|
Loading…
x
Reference in New Issue
Block a user