attrs={'invisible'} on field tags doesn't work in fields_view_get method!
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo GTK Client (MOVED TO GITHUB) |
New
|
Undecided
|
Unassigned |
Bug Description
I am working on openerp v.7. I override fields_view_get function and create in it many2one field as following:
result['arch']= '''<field name= "hw_sub_category" attrs="
The field is added successfully but it always visible.
I guessed that because may be attrs invisible doesn't work on the field tag in fields_view_get function so I set the field under group and add the attrs to the group as following:
_arch_moves += '''<group attrs="
_arch_moves += '''<field name= "hw_sub_category"/> '''
_arch_moves += '''</group>'''
result['arch']= _arch_moves
but also the same thing the field is always visible.
I tried also to set the invisible in the fields.update itself as following:
result[
By searching I found the following way:
doc = etree.XML(
for node in doc.xpath(
node.
result['arch'] = etree.tostring(doc)
Also The field always visible.
So why the invisible attribute doesn't work in the fields_view_get method and how can I overcome this?
Thanks in advance.
summary: |
- invisible attribute doesn't work in fields_view_get method + attrs={'invisible'} on field tags doesn't work in fields_view_get + method! |