Repository navigation
Conversation
…vate reload The type-filter tab was a transient JS var reset to '' on every load, and activate/deactivate does a full window.location.reload() — so a reload (especially the one after a toggle) always dropped you back on "All" and lost your sort/page/search. Now the chosen tab is persisted per-browser (localStorage, try/catch-guarded) and restored on load (a stale type falls back to All), and the DataTable gets stateSave so sort/page/length/search survive the reload too. The reload still runs (it reflects the server-rendered row state, filter counts, sidebar nav and theme-default marker that activation changes) — it's just no longer destructive to where you were. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ
Owner
Author
|
Superseded by the ajax DataTable refactor (#327): the grid now fetches already-filtered rows, so the tab FOUC is gone and tigerDataTable's stateSave covers sort/page/search natively. |
WebTigers
added a commit
that referenced
this pull request
Oct 10, 2026
…ilter FOUC (#327) * Module Manager: ajax DataTable (client/server paradigm) — fixes the filter FOUC The modules grid server-rendered every row and filtered client-side, so a remembered tab flashed All → the chosen type on load. Refactored to the Tiger datatable paradigm the Users table uses: an EMPTY table fed by System_Service_Modules::datatable over /api (server-side search / type-filter / sort / paginate), column renderers that build the cells + gate the activate/deactivate/delete controls off per-row flags (can_toggle / can_delete), and the chosen type remembered in a cookie the controller reads so the active pill renders server-side and the first ajax load is already filtered — no flash. catalog() is the shared authority (controller pills + the feed). Activate/delete now re-fetch the grid in place (table.ajax.reload) instead of window.location.reload, and the full-catalog counts ride each response so the pills stay accurate. Removes the inline <style> (the desc clamp is an inline style attr in the renderer). Supersedes #326 (tab persistence) — tigerDataTable's stateSave covers sort/page/search for free. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ * test: update modules-screen dispatch test for the ajax DataTable paradigm #327 moved the modules list off server-rendered $this->view->modules onto the System_Service_Modules::datatable /api endpoint, so the old assertion ("the screen builds the on-disk module list") now sees null. Assert the new contract: index dispatches 200 (the shell), and datatable() returns the on-disk rows with active/protected/source + system flagged protected. Also covers datatable(). Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ * test: import System_Service_Modules (global class) in the namespaced dispatch test Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ --------- Co-authored-by: Claude Opus 4.8 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Module Manager's type-filter tab is now remembered across a page refresh (per-browser,
localStorage), and the modules DataTable gets
stateSaveso sort / page / length / search alsosurvive a reload.
Why
Two linked issues Beau hit:
activeType) reset to''on every load — never persisted.window.location.reload(), which wiped that client-only filter state (andthe sort/page/search), always dumping you back on All.
The reload (the "why is it refreshing anyway?")
Kept, deliberately: activating a module changes several server-rendered regions — the row's badge +
its activate↔deactivate button, the type-filter counts, the admin sidebar nav / Settings tree a
newly-active module contributes, and the theme-default marker. The reload is the simple way to reflect
all of them. This change makes the reload non-destructive (you land exactly where you were) rather
than removing it. A full no-reload, in-place row+nav reconciliation is a larger follow-up (and the
TigerAgent app-shell is the real vehicle for that); flagged, not done here.
Notes
access is
try/catch-guarded, and a stored type whose pill no longer exists falls back to All.modules/system/views/scripts/modules/index.phtml.🤖 Generated with Claude Code
https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ