Hello the Odoo Community,
I'm facing a problem, I want to create an report that show the list of actions grouped by date in a table
Each action has a date.
The result of the t-foreach is:
day 1 - action 1
day 1 - action 2
day 1 - action 3
day 2 - action 4
day 2 - action 5
day 3 - action 6
day 3 - action 7
I want to have as result:
Day1 Day 2 Day 3
Action 1 Action 4 Action 6
Action2 Action 5 Action 7
Action3
My problem is to change td /td on each changing day
Somebody can help me?
Thank you for your help
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Akuntansi
- Inventaris
- PoS
- Project
- MRP
Pertanyaan ini telah diberikan tanda
1
Balas
4098
Tampilan
Hello , try this:
<t t-set="days" t-value="[]"/>
<t t-foreach="o.days_line" t-as="l">
<t t-set="days" t-value="days+[l.action_id]"/>
</t>
<t t-foreach="set(days)" t-as="date">
<div><strong t-esc="date.name"/></div>
<t t-foreach="o.days_line" t-as="l">
<t t-if="date.id==l.action_id.id">
<div><span t-field="l.action_id"/></div>
</t>
</t>
</t>
Menikmati diskusi? Jangan hanya membaca, ikuti!
Buat akun sekarang untuk menikmati fitur eksklufi dan agar terlibat dengan komunitas kami!
DaftarPost Terkait | Replies | Tampilan | Aktivitas | |
---|---|---|---|---|
|
0
Mar 15
|
5627 | ||
|
0
Mar 15
|
3917 | ||
|
1
Sep 23
|
2976 | ||
|
0
Mar 15
|
5070 | ||
Add current Date and Time in Qweb report
Diselesaikan
|
|
1
Agu 25
|
20939 |