mirror of
https://github.com/we-promise/sure.git
synced 2026-05-29 15:34:58 +00:00
fix(views): guard against nil entry.date in partials (#1878)
Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com>
This commit is contained in:
@@ -52,7 +52,7 @@
|
||||
<div class="flex-1 text-sm">
|
||||
<div class="font-medium text-primary"><%= entry.name %></div>
|
||||
<div class="text-xs text-secondary">
|
||||
<%= I18n.l(entry.date, format: :short) %> •
|
||||
<%= entry.date ? I18n.l(entry.date, format: :short) : "—" %> •
|
||||
<%= number_to_currency(entry.amount.abs, unit: Money::Currency.new(entry.currency).symbol) %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
</div>
|
||||
|
||||
<span class="text-sm text-secondary">
|
||||
<%= I18n.l(entry.date, format: :long) %>
|
||||
<%= entry.date ? I18n.l(entry.date, format: :long) : "—" %>
|
||||
</span>
|
||||
<% end %>
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
</h3>
|
||||
<div class="flex items-center gap-2">
|
||||
<span class="text-sm text-secondary">
|
||||
<%= I18n.l(entry.date, format: :long) %>
|
||||
<%= entry.date ? I18n.l(entry.date, format: :long) : "—" %>
|
||||
</span>
|
||||
<% if entry.transaction.pending? %>
|
||||
<span class="inline-flex items-center gap-1 text-xs font-medium rounded-full px-1.5 py-0.5 border border-secondary text-secondary" title="<%= t("transactions.transaction.pending_tooltip") %>">
|
||||
|
||||
@@ -19,6 +19,6 @@
|
||||
</div>
|
||||
|
||||
<span class="text-sm text-secondary">
|
||||
<%= I18n.l(entry.date, format: :long) %>
|
||||
<%= entry.date ? I18n.l(entry.date, format: :long) : "—" %>
|
||||
</span>
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user