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 hide fields in a tree view

By
Jihen BEN ALI
on 7/15/15, 3:27 AM 546 views

I've added a supplier number and a customer number, and now I need to add this number in the tree view. The problem is that this 2 number are shown in the customer tree and the supplier tree.

How could I hide a column depending on if it is a Suppliers tree view or a Customers tree view ?

Help me please.

I found this one but it doesn't help

https://www.odoo.com/es_ES/forum/help-1/question/how-to-add-a-field-conditional-to-tree-view-of-customer-14707

1

Solanki Shamji

--Solanki Shamji--
1293
| 5 2 6
Baroda, India
--Solanki Shamji--

Hello!

Solanki Shamji
On 7/15/15, 3:46 AM

Hello,

May be this will helpful you.

<tree>
    <field name="customer_number" invisible="context.get('default_customer', False)" />
  <field name="supplier_number" invisible="context.get('default_supplier', False)" />  
</tree>
0
Jihen BEN ALI
On 7/15/15, 4:09 AM

Thank you very much

It worked

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: 7/15/15, 3:27 AM
Seen: 546 times
Last updated: 7/16/15, 2:47 AM