Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The user object is unavailable in non-top-level templates #11105

Open
chrabyrd opened this issue Jun 28, 2024 · 0 comments
Open

The user object is unavailable in non-top-level templates #11105

chrabyrd opened this issue Jun 28, 2024 · 0 comments

Comments

@chrabyrd
Copy link
Contributor

Non-top-level templates means any template not served at the end of a route. The template is bundled via webpack and treated as a static asset, so the {{ user }} is always anonymous.

This issue has been surfaced by EAMEANA, as they're attempting to conditionally display parts of the default report depending on user.

We cannot rightly depend on {{ user }} being available in these templates, and therefore need to find a decent workaround. Quite possibly either hanging the user on the arches object, or creating a get_logged_in_user api endpoint

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

1 participant