Template fixes

See the changes on heroku http://kopentavern.herokuapp.com/
request.user is SimpleLazyObject and may not be sufficient sometimes for queries. So using *id* instead.