Odoo Help


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.


Hide Columns in treeview for certain users

on 8/26/15, 11:52 AM 442 views

How can I hide certain columns in tree view for certain users


Akhil P Sivan

--Akhil P Sivan--
| 5 3 6
Kochi, India
--Akhil P Sivan--

Interested in exploring Odoo both technically & functionality wise.

email-id : akhilpsivan01@gmail.com

Akhil P Sivan
On 8/26/15, 12:11 PM

You can create a "group". And then add users to that group, who wants to see it. The non-members cannot see that column.

To create a group,


    <record id="group_uom" model="res.groups">
<field name="name">Manage Multiple Units of Measure</field>
<field name="category_id" ref="base.module_category_hidden"/>

In the tree view, specify that group in the column you want:


<record id="stock_inventory_line_tree" model="ir.ui.view">
<field name="name">stock.inventory.line.tree</field>
<field name="model">stock.inventory.line</field>
<field name="arch" type="xml">
<tree string="Stock Inventory Lines">
<field name="product_id"/>
<field name="product_qty"/>
<field name="product_uom_id" groups="product.group_uom"/>
<field name="location_id" groups="stock.group_locations"/>

Please refer stock_view.xml in the stock module for referrence to find the above code. And group_uom you can find in product module under security>>product_security.xml. Try to understand how to create the group and use it, thats it :)

Thanks @Akhil.

Ankit H Gandhi(AHG)
on 8/27/15, 3:20 AM

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)


Asked: 8/26/15, 11:52 AM
Seen: 442 times
Last updated: 8/27/15, 3:19 AM