Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I am creating a structure snippet that lists all the blog news from the Blog Module. I am using t-tags (t-set and t-call) to list them up.
The problem is that as soon as I drag that snippet the t-tags transforms into regular HTML code, so I will not get the list updated if a new blog post is created.
My question is how can I use t-tags in snippets without getting it transformed into regular HTML code.
Here is my code:
<img class="oe_snippet_thumbnail_img" src="/website/static/src/img/blocks/block_panel.png"/>
<span class="oe_snippet_thumbnail_title">Blog News</span>
<div class="container col-md-4">
<div class="panel panel-primary">
<div class="panel-heading text-center" style="background:#016FAF;">
<h2 style="margin: 0; color:#fff;">
<t t-set="blog" t-value="request.env['blog.blog'].search([('name','=','Our News')])"/>
<t t-set="news" t-value="request.env['blog.post'].search([('website_published','=',True), ('blog_id','=',blog.id)], order='write_date desc')"/>
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 8/13/15, 3:23 AM|
|Seen: 824 times|
|Last updated: 8/14/15, 3:39 PM|