Odoo Help

Welcome!

This community 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.

0

How to change ListView template in Base?

By
babu
on 6/3/15, 3:19 AM 410 views

Hello Team,

I want to chnage Listview template in my module, please guide me,

1> First Template

<?xml version="1.0" encoding="UTF-8"?>

<templates id="template" xml:space="preserve">

<table t-name="MyListView" class="oe_list_content">

<t t-set="columns_count" t-value="visible_columns.length + (options.selectable ? 1 : 0) + (options.deletable ? 1 : 0)"/>

<thead>

<tr class="oe_list_header_columns">

<th>

My Name

</th>

<th class="oe_list_header_integer"><div>

My Class 

</div></th>

<th class="oe_list_header_float "><div>

Computer Name

</div></th>

<th class="oe_list_header_float "><div>

Join Date

</div></th>

  <th t-if="options.deletable" class="oe_list_record_delete" width="13px"></th>

</tr>

</thead>

</table>

</templates>

2>Second Template :


<?xml version="1.0" encoding="UTF-8"?>

<templates id="template" xml:space="preserve">

<table t-name="ListView" class="oe_list_content">

<t t-set="columns_count" t-value="visible_columns.length + (options.selectable ? 1 : 0) + (options.deletable ? 1 : 0)"/>

<thead>

<tr class="oe_list_header_columns">

<th>

My Name

</th>

<th class="oe_list_header_integer"><div>

My Class

</div></th>

<th class="oe_list_header_float "><div>

Computer Name

</div></th>

<th class="oe_list_header_float "><div>

Join Date

</div></th>

<th t-if="options.deletable" class="oe_list_record_delete" width="13px"></th>

</tr>

</thead>

</table>

</templates>


In the above, when first template is not reflecting in my module, but second template when I use in my module it will reflect in hole odoo list view, but i want to the output as first template.

please any one guide me what i did wrong

Thanks in advance

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 6/3/15, 3:19 AM
Seen: 410 times
Last updated: 6/3/15, 3:44 AM