def post_note(self, request): # if the note has a timestamp use it. if request.when is not None: when = datetime.datetime.utcfromtimestamp(request.when) else: when = datetime.datetime.now() note = guestbook.Greeting(parent=guestbook.guestbook_key(guestbook.DEFAULT_GUESTBOOK_NAME), content=request.text, date=when) note.put() return message_types.VoidMessage()