astubenbord / paperless-mobile

An (almost) fully fledged mobile paperless client.
GNU General Public License v3.0
677 stars 33 forks source link

[Bug]: Filter rule "has storage path in" (rule_type: 30) is not working #304

Open mrwafa opened 9 months ago

mrwafa commented 9 months ago

What happened?

Hi

I created some saved views to filter only by storage path in the web UI from Paperless-NGX (1.17.4). When I like to use those filters in the mobile app, always all documents got displayed. Then i created another saved view directly in the mobile app. This one worked fine in the app and in the web UI.

When i compared the rules of those 2 saved views in the database, i discovered that they have different "rule_types". The one created in the web UI by paperless itself uses rule 30 ("has storage path in") which only worked in the web UI. the one created in the mobile app uses rule 25 ("storage path is") which works fine in the app and the web ui.

I saw, rule 30 is missing in the mobile app source code.

Many thanks!

Steps to reproduce

Described above ;-)

Log output from the app

No response

Screenshots

No response

Paperless-ng*x Version

1.17.4

Paperless-Mobile Version

latest

Device

Huawai P30

Operating System Version

Android 11

Device Locale

german

Selected Locale

German

Additional Context

No response

astubenbord commented 9 months ago

Yeah, in newer versions of paperless-ngx, you can filter by several correspondents, document types and storage paths, whereas older versions only support equality instead of a containment relationship (see the 'in' vs 'is' filter rule). I will update this at some point, but I didn't get to implement it yet.