* added local feed sorting
Addresses https://github.com/FreshRSS/FreshRSS/issues/4761
- Added number of sorted feeds and associative array for feed sorting option in Context.
- Number of sorted feeds and local sorting option by its index saved into Minz Request Parameters.
- Number of sorted feeds and local sorting options deleted when choosing another Option Of Global Sorting.
- Added option of allowing sorting by feed in configuration.
- Added variable for allowing local sorting in userConf.
- Added function to get feeds by current get in context.
- Added menu button for all individual feed sorting.
- New database options for individual feed sorting in EntryDAO.
- Considered choosing new entries based on chosen load limit.
- Local sorting parameter saved into continuation value in Index Controller.
How to test the feature manually:
1. At the bottom of Reading Configuration menu turn on individual sorting option menu
2. Choose Sorting by feed option
3. Choose feed at next sorting menu and choose sorting option for that feed
* added feed sorting option
* added sort feeds display
* added template for sort feed name
* added title to feed sorting button
* added comments
* added local sorting option
* Added Docs
* css reset
* added getter and seter for local sort
* added getter and seter for local sort
* allowed sorting per feed
* allowed sorting per feed
* added sorting option for category
* deleted changes from NetryDAO
* add setting up sorting for category
* docs reset
* i18 reset
* updated i18 for category
* added i18 for categories
* added i18 for category
* added setting sorting for feeds and category
* removing userConf.allow-local-sort
* removing userConf.allow-local-sort
* removing white space
* added credits
* removed feeds_by_get
* removed whitespace
* changed escaping for values
* added escaping to user set values
* added in_array
* added secondary sort and order
* added secondary sort and order
* fixed readme
* removed whitespace change
* reseted i18n
* added translations
* added feed setting translations
* fixed i18n
* fixed i18n
* changes in sort order per feed
* changes in sort order per feed
* added secondary sort order
* primary sort
* changed to preferred sort order
* i18n
* Revert wrong whitespace changes
* Re-order new options
* added blank option
* fixed escaping
* fixed default sort in feed
* fixed default sort recovery
* siplyfied option
* added rand option
* Revert unrelated change
* Minor plaintext
* Whitespace and formatting fixes
* Avoid unneeded SQL requests and processing
* Improve syntax
* Improve logic
* Reuse existing translations as much as possible
* i18n
* Remove some options that make little sense
* Separators
* Fix old transation key
* Add help messages
* Progress on secondary sort
* raw name
* Pass parameters. Add TODO
* Progress
* Minor ordering
* Fix parenthesis
---------
Co-authored-by: root <root@LAPTOP-C8TCHHPN.localdomain>
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
Closes https://github.com/FreshRSS/FreshRSS/issues/7330
- Default behavior is same
- Added FreshRSS_Context::userConf()->html5_disable_notif so that, it determines weather user wants notification. (will not show any even it has permission) (i want default false so disable, so old configs get proper default values)
- Added button such that checking it makes it request permission too
<img width="707" height="119" alt="image" src="https://github.com/user-attachments/assets/a0fdbc4d-9f15-4644-8753-f0e6c979677f" />
- test notification actually happening (how can i trigger it, do i have to wait it), this code fixes permissions.
* Add closed msg field
i18n
fix
* Display based on registration type
* Save as FreshRSS_Context::systemConf()->closed_registration_message instead
* Improve messages
* Revert unrelated changes
* make fix-all
* Minor whitespace
* Simplify logic
* Fix invalid use of empty() and sympler syntax
---------
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
* Allows easier modifications of the search expression.
* Add proper `__toString()` instead of just returning the raw input string. Allows in particular showing the result of the actual parsing of the raw input string in the UI.
Needed for https://github.com/FreshRSS/FreshRSS/pull/8294
Fix https://github.com/FreshRSS/FreshRSS/issues/8268
To better support user management on FreshRSS instance with many users.
SQL speed improved. On a reduced test with 5 users, including some large accounts (PostgreSQL on a very tiny and slow server), improving from ~2.3s to ~1.8s, which gives ~20% speed improvement.
Then tested with 1000 users, with only the default feed (on my old desktop computer):
```sh
for i in {1..1000}; do ./cli/create-user.php --user=freshrss$i --password=freshrss; done
app/actualize_script.php
cli/access-permissions.sh
```
SQLite:
```console
$ time cli/user-info.php | wc -l
1001
real 0m1.366s
user 0m0.908s
sys 0m0.475s
```
PostgreSQL:
```console
$ time cli/user-info.php | wc -l
1001
real 0m28.498s
user 0m12.137s
sys 0m2.217s
```
MariaDB:
```console
# time ./cli/user-info.php | wc -l
1001
real 0m49.485s
user 0m1.276s
sys 0m2.258s
```
Yes, SQLite is much faster - not a surprise for such use-cases, where the TCP connection is not re-used.
I have added some CLI options to disable some statistics:
```sh
cli/user-info.php --no-db-size --no-db-counts
```
For the Web UI, I have disabled detailed user statistics if it takes too long, and retrieve missing user statistics asynchronously via JavaScript. Lazy loading of the user details based on IntersectionObserver, with maximum 10 requests in parallel.
Web UI tested on 1000 users as well. Checked with SeaMonkey.
* Improve anonymous authentication logic
* forgot to git add
* Fix incorrect token check
Because an empty parameter could be just passed if token for the user wasn't set: `&token=`
* Housekeeping lib_rss.php
`lib_rss.php` had become much too large, especially after https://github.com/FreshRSS/FreshRSS/pull/7924
Moved most functions to other places.
Mostly no change of code otherwise (see comments).
* Extension: composer run-script phpstan-third-party
* Add option to apply filter actions to existing articles
* make fix-all
* Fixes
* Another approach with preview
New approach: 20479475c9
<img width="666" height="202" alt="image" src="https://github.com/user-attachments/assets/bb68ede4-60c8-4e0c-9317-c5ed7a6ad7df" />
Additional improvements:
* Also implemented at category level, and at global level
* Also implemented for favourites at global level
Shortcomings:
* Does not always work reliably with advanced regex, since the DB's flavour is not necessarily the same than PHP's
Related: https://github.com/FreshRSS/FreshRSS/pull/8141
* make fix-all
---------
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
The compatibility does support only a minimum version of FreshRSS. If we need
something a bit more clever in the future, it is possible to handle a rule
with a bit more complexity.
See https://github.com/FreshRSS/FreshRSS/issues/5903
* Update app/Controllers/extensionController.php
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
* Update app/i18n/pl/admin.php
Co-authored-by: Inverle <inverle@proton.me>
* Minor move phpstan-type
---------
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
Co-authored-by: Inverle <inverle@proton.me>
* Add UI for advanced search
To help users with the seach operators.
Obviously not as powerful as a manually-written search query.
Lack in particular negation and logical *and* for now, but I might try to do something about it.
<img width="939" height="1438" alt="image" src="https://github.com/user-attachments/assets/0bcad39b-eff3-4f44-876b-a2552af2af00" />
* Consistency: allow multiple user queries like S:1,2
* Fix user query and add tests
* feat: Add user modified functionality
Closes https://github.com/FreshRSS/FreshRSS/issues/7862
Changes proposed in this pull request:
This is an implementation of the proposed feature. It allows entries to have a new field that will be updated whenever an item is marked as read/unread or bookmark/removed from bookmarks. And a new sort criteria to sort by it.
How to test the feature manually:
1. Mark items from a feed as read/unread
2. Mark items from a feed as bookmark / remove bookmark
3. Sort by the new criteria
* feat: Add sort functionality
* feat: Add sort nav button
* fix: Use correct migrations
* fix: Add internationalization
* fix: Linter errors
* chore: PR comments
* Update app/i18n/fr/index.php
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
* Update app/i18n/pl/index.php
Co-authored-by: Inverle <inverle@proton.me>
* Update app/i18n/nl/index.php
Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>
* make fix-all
* Fixes
* More fixes sort
* Fix wrong index
* Fix unneeded column
* Fix auto-create indexes
* Some copilot suggestions
* One more fix
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
---------
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
Co-authored-by: Inverle <inverle@proton.me>
Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>
## Screenshots
<details>
<summary>Before</summary>
<img width="773" height="652" alt="image" src="https://github.com/user-attachments/assets/89a0e58c-8c4a-41ff-b5d6-3e916079d563" />
</details>
<details>
<summary>After</summary>
<img width="1006" height="646" alt="image" src="https://github.com/user-attachments/assets/f4575103-7365-4870-a170-2742bf10eb27" />
</details>
This is an example on Firefox, where the `Master authentication token` field was incorrectly being autofilled.
Red borders are indicating that the fields are required.
## List of changes
* `required="required"` is now being added to the password fields if the section is open
* The `challenge` field is being added if section is open instead of when at least one of the password fields isn't empty due to autocomplete
* Added `autocomplete="new-password"` on fields that shouldn't be autocompleted
* Unfortunately Chrome requires a workaround with CSS
* Not tested on Safari yet
* User will be redirected to profile page after successfully changing their password instead of index page
## How to test
Autocomplete related changes should be tested on a HTTPS page with saved credentials for FreshRSS