def getPost(self, blog=None, **post):
blog = request.registry.get('blog.post').browse(request.cr, SUPERUSER_ID, int(blog))
values = {
- "image": "data:image/png;base64,%s" % blog.content_image,
+ "image": blog.content_image,
"date": blog.create_date ,
"author": blog.create_uid.name,
"author_image": "data:image/png;base64,%s" % blog.create_uid.image,
}
ArticleAnimator.contentizeElement = function($el, d){
- $el.find('.big-image').css({ backgroundImage: "url(" + d.image + ")" });
+ $el.find('.big-image').css({ backgroundImage: (d.image)?"url(data:image/png;base64," + d.image + ")":""});
$el.find('h1.title').html(d.title);
$el.find('h2.description').html(d.title_secondary);
$el.find('.content .text').html(d.content);