mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-05 05:25:24 +02:00
Fix transaction filters when transfers are present (#1986)
* Proper filtering of transfers in search * Fix transaction search
This commit is contained in:
parent
ed55ef624b
commit
dd75cadebc
4 changed files with 96 additions and 45 deletions
|
@ -1,4 +1,4 @@
|
|||
<div class="space-y-4 h-fit max-h-full flex flex-col" data-controller="focus-record" data-focus-record-id-value="<%= @focused_record ? dom_id(@focused_record) : nil %>">
|
||||
<div class="space-y-4 pb-20 flex flex-col" data-controller="focus-record" data-focus-record-id-value="<%= @focused_record ? dom_id(@focused_record) : nil %>">
|
||||
<%= render "header" %>
|
||||
|
||||
<%= render "summary", totals: @totals %>
|
||||
|
@ -7,7 +7,7 @@
|
|||
data-controller="bulk-select"
|
||||
data-bulk-select-singular-label-value="<%= t(".transaction") %>"
|
||||
data-bulk-select-plural-label-value="<%= t(".transactions") %>"
|
||||
class="overflow-y-auto flex flex-col bg-white rounded-xl shadow-border-xs p-4">
|
||||
class="flex flex-col bg-white rounded-xl shadow-border-xs p-4">
|
||||
<%= render "transactions/searches/search" %>
|
||||
|
||||
<div id="entry-selection-bar" data-bulk-select-target="selectionBar" class="flex justify-center hidden">
|
||||
|
@ -29,8 +29,7 @@
|
|||
</div>
|
||||
<div class="space-y-6">
|
||||
<%= entries_by_date(@transactions.map(&:entry), totals: true) do |entries| %>
|
||||
<%# Only render the outflow side of transfers to avoid duplicate entries %>
|
||||
<%= render partial: "account/entries/entry", collection: entries.reject { |e| e.entryable.transfer_as_inflow.present? } %>
|
||||
<%= render entries %>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue