Files
sure/app/views/entries/_entry_group.html.erb
Zach Gollwitzer e657c40d19 Account:: namespace simplifications and cleanup (#2110)
* Flatten Holding model

* Flatten balance model

* Entries domain renames

* Fix valuations reference

* Fix trades stream

* Fix brakeman warnings

* Fix tests

* Replace existing entryable type references in DB
2025-04-14 11:40:34 -04:00

28 lines
1.1 KiB
Plaintext

<%# locals: (date:, entries:, content:, totals: false) %>
<div id="entry-group-<%= date %>" class="bg-container-inset rounded-xl p-1 w-full" data-bulk-select-target="group">
<div class="py-2 px-4 flex items-center justify-between font-medium text-xs text-secondary">
<div class="flex pl-0.5 items-center gap-4">
<%= check_box_tag "#{date}_entries_selection",
class: ["checkbox checkbox--light", "hidden": entries.size == 0],
id: "selection_entry_#{date}",
data: { action: "bulk-select#toggleGroupSelection" } %>
<p class="uppercase space-x-1.5">
<%= tag.span I18n.l(date, format: :long) %>
<span>·</span>
<%= tag.span entries.size %>
</p>
</div>
<% if totals %>
<div id="entry-group-<%= date %>-totals">
<%= totals_by_currency(collection: entries, money_method: :amount_money, negate: true) %>
</div>
<% end %>
</div>
<div class="bg-container shadow-border-xs rounded-md divide-y divide-alpha-black-50">
<%= content %>
</div>
</div>