Hello!

I am trying to set some extra_context in my template using query.

For example, I have the next model:
class directions(db.Model):
    directions = db.StringProperty()
    directionsid = db.IntegerProperty()
    def __unicode__(self):
        return self.directions

Then I try to access data depending on user input and to set
extra_context. A bit of my code:

###
query = GqlQuery("SELECT * FROM directions WHERE directions
= :directions", directions = form.cleaned_data["direction"])
self.extra_context["direction"] = directions.directionsid
####

And finally, when I use {{direction}} in my template I just receive
something like that:
<google.appengine.ext.db.IntegerProperty object at 0x08583CF0>
But I want my results to be human readable.

What should I do?
Looking forward to your replies.

P.S.: Sorry for my English. If most  isn't quite clear i"ll try to
explain it in other way.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to