make_post_sell/make_post_sell
russell@unturf.com 095d91bc68
feat: sort dropdown on tag detail + filtered shop home (MPS-24)
Six sort options on category/tag pages, controlled by ?sort=:

  newest       Newest first        (default — created_timestamp desc)
  oldest       Oldest first        (created_timestamp asc)
  price_asc    Price low → high    (price_in_cents asc)
  price_desc   Price high → low    (price_in_cents desc)
  title        Alphabetical A→Z    (lowercased title)
  popular      Most popular (28d)  (PageSession views with visible_ms ≥ 7s)

Rendered as a <select> right-aligned above the grid. Capability-driven:
plain GET form works without JS (button appears via <noscript>), JS-on
auto-submits on change. Both shop_tag.j2 and home.j2 (filtered branch
only — lanes keep their editorial order) get the dropdown.

views/shop.py — new SORT_OPTIONS list + _sort_key_from_request +
_sort_products + _popular_view_counts helpers. Sort runs in Python on
the already-filtered list, so it's O(N log N) on the tagged subset
not the whole shop catalog. The 'popular' option fires one extra
PageSession aggregate query scoped to the filtered product_ids;
~tens of ms on indexed (shop_id, product_id, created_timestamp).

Doesn't address fox's bigger ask: Netflix-style truly-responsive
SERP layout with left nav + description-excerpt rows that works at
every resolution. That's a real redesign — proposing it next.
2026-05-15 14:14:17 -04:00
..
lib feat: MPS-24 Phase 2.3 — multi-bigram supersession, apostrophe labels, top_n 100 2026-05-15 11:41:46 -04:00
models feat: MPS-24 — operator-controlled tag order (no-JS + drag-and-drop ready) 2026-05-15 14:02:43 -04:00
scripts feat: MPS-24 — operator-controlled tag order (no-JS + drag-and-drop ready) 2026-05-15 14:02:43 -04:00
static feat: sort dropdown on tag detail + filtered shop home (MPS-24) 2026-05-15 14:14:17 -04:00
templates feat: sort dropdown on tag detail + filtered shop home (MPS-24) 2026-05-15 14:14:17 -04:00
tests feat: MPS-24 — operator-controlled tag order (no-JS + drag-and-drop ready) 2026-05-15 14:02:43 -04:00
views feat: sort dropdown on tag detail + filtered shop home (MPS-24) 2026-05-15 14:14:17 -04:00
__init__.py Add Monero (XMR) payment support 2025-09-22 01:45:54 +00:00
config_jinja2.py Time to open the sauce : ) 2021-12-31 21:39:40 -05:00
request_methods.py fix: scope /u/notifications + navbar badge to the current shop 2026-05-15 09:25:17 -04:00
routes.py feat: MPS-24 — shop home page categorization (tags + chips + sectioned lanes) 2026-05-15 08:48:25 -04:00