Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to sum all the records and display as single in kanban view?

Tags:

openerp

I need to sum the companies total and display as single row like in the image.

enter image description here

Now I just used the kanban view to display default view.

<kanban class="o_kanban_mobile">
    <field name="name"/>
    <field name="company"/>
    <field name="actual_amount"/>
    <field name="planned_amount"/>
    <templates>
        <t t-name="kanban-box">
            <div t-attf-class="oe_kanban_card oe_kanban_global_click">
                <table border="1" width="100%">
                    <tr>
                        <td rowspan="2"><t t-esc="record.name.value"/>-<t t-esc="record.company.value"/></td>
                        <td>Planned</td>
                        <td>Actual</td>
                    </tr>
                    <tr>
                        <td><t t-esc="record.planned_amount.value"/></td>
                        <td><t t-esc="record.actual_amount.value"/></td>
                    </tr>
                </table>
            </div>
        </t>
    </templates>
</kanban>
like image 976
Mani Avatar asked Aug 25 '17 18:08

Mani


People also ask

What is Kanban list view in Salesforce?

Kanban views show records in a graphical way that helps you monitor your work and keep deals moving ahead. Kanban views are available for most objects, with exceptions such as tasks.

Does Airtable have Kanban board?

Airtable has plenty of free templates to get you started creating a kanban board of your very own, and ultimately, every Airtable base can be organized into kanban view.


1 Answers

I think this will work for you.

Add a char field to your model don't show it . just define a defaut value for it, default = 'sum' then groub by that field.

You should get the same result.

like image 154
Charif DZ Avatar answered Oct 06 '22 19:10

Charif DZ