Can't figure out how to leverage a complex session object in a template?!?
HI,
I've got a session object which is a dict. I'm using it to track the
state of screen elements (an expanding tree).
request.session['mystate'] = {'1':'true', '2','false'}
In my template I'm looping through the branches:
So:
I want to test:
request.session['mystate'][object.id]=='true':
But how can get that multidimensional dynamic ref into a template with
only dot notation?
I don't see how I can even do it in the view without stuffing the
information into the model object.
Any ideas? Thanks much!
James
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home