MyFinances icon indicating copy to clipboard operation
MyFinances copied to clipboard

bug: filter icons appearing twice

Open TreyWW opened this issue 1 year ago • 6 comments

What version of MyFinances are you currently using?

latest

What device type are you currently facing the issue on?

No response

Describe the bug

Filter icons on invoice page are showing up twice per col

TreyWW avatar Oct 06 '24 10:10 TreyWW

I have tested it and can't reproduce this, either it has already been fixed by a page effect or it is due to something else, please give me some more information such as

  • which browser are you using and in which version?
  • does this bug only occur with a certain number of Invoices ?

please give us as much information as possible that can be reproduced or adjusted

EsstBananeImEi avatar Oct 09 '24 11:10 EsstBananeImEi

I reproduced the bug.

Step 1: Click overview on any item Image Step 2: Go to the overview page and return to the original page list

Image Step 3: You can see a filter button superimposed

Image

XinSkyrim avatar Mar 27 '25 07:03 XinSkyrim

I recognized if you refresh the page, or create a new invoice the filter icon set backs to one icon. The problem occurese always, even if you have no invoices.

io-95 avatar Apr 02 '25 18:04 io-95

I'm trying to fix the bug right now, but I saw @TreyWW that you add hx-boost="true" in frontend/templates/pages/invoices/dashboard/manage.html. In case of solving the problem it leads to a new bug. Deleting didn't break the code, but I would like to ask you first what your intention was with hx-boost="true".

io-95 avatar Apr 06 '25 18:04 io-95

Hey @io-95,

HX-Boost allows for the content to be swapped without having to fully refresh the page but still allows 'normal' navigation. I would guess that the filter icon state doesn't clear when you change page, so when going back it gets appended?

Ideally we won't have to remove the HX-Boost

TreyWW avatar Apr 06 '25 19:04 TreyWW

The new problem occures when the user comes back from the overview page to the dashboards over the "back to page" button. in this case the page is reloaded but for the js file it looks like the page is loaded from the cache, so it doesn't initialize the filter icons. And this happens due to the hx-boost, if I understand the code right.

I gues it could help if I explain my approach. My approach is to check if the page is initialized for the first time or loaded from the cache, to avoid that the icon are loaded more then once.

io-95 avatar Apr 06 '25 20:04 io-95