new-site/performancewest_erpnext/performancewest_erpnext
justin 5c1341e6a1 portal: fix dead set-password link (rename controller to underscore)
Root cause of the 'Link invalid' onboarding link: Frappe's TemplatePage
resolves a www page's Python controller by converting hyphens to underscores
(see frappe/website/page_renderers/template_page.py set_pymodule: it looks for
'set_password.py' next to 'set-password.html'). Our controller was named
'set-password.py' (hyphen), so os.path.exists() missed it, pymodule_name stayed
None, get_context never ran over HTTP, and the template rendered with no
context -> raw {{ email }}, title 'Link invalid', token never verified. (It
worked under bench/in-process only because we called get_context directly.)

Fix: rename www/set-password.py -> www/set_password.py (route stays
/set-password, driven by the .html filename) and update the whitelisted submit
endpoint path in set-password.html to ...www.set_password.submit.

NOTE: the sibling legacy CRTC/CDR admin pages (admin-filings.py,
admin-resellers.py, cdr-*.py) have the same latent hyphen bug; left as-is since
they're outside the compliance portal, but they are silently controller-less.
2026-06-02 23:10:36 -05:00
..
compliance Add Compliance Deadline + Compliance Calendar DocTypes for ERPNext 2026-05-04 11:26:45 -05:00
fixtures Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00
gateways Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00
payments Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00
www portal: fix dead set-password link (rename controller to underscore) 2026-06-02 23:10:36 -05:00
__init__.py Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00
api.py Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00
hooks.py Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00
modules.txt Initial commit — Performance West telecom compliance platform 2026-04-27 06:54:22 -05:00