### Impacted versions:
odoo 13.0
### Steps to reproduce:
create a model 'ghost.inventory' with a boolean variable 'used'.
Then create xml file:
<odoo>
<record id="dashboard_graph_view" model="ir.ui.view">
<field name="name">ghost.dashboard.graph</field>
<field name="model">ghost.inventory</field>
<field name="arch" type="xml">
<graph type="bar">
<field name="used" type="row" title="title"/>
</graph>
</field>
</record>
<record id="action_dashboard" model="ir.actions.act_window">
<field name="name">Dashboard</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">ghost.inventaire</field>
<field name="view_mode">graph</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Dashboard
</p>
</field>
</record>
<menuitem id='ghost_root_menu'
name='Ghost'/>
<menuitem id='ghost_dashboard_menu'
name='Dashboard'
action="action_dashboard"
parent="ghost_root_menu"/>
</odoo>
### Current behavior:
this code behave well **WITHOUT** title="title" in :
<odoo>
<graph type="bar">
<field name="used" type="row" title="title"/>
</graph>
</odoo>
### Expected behavior:
Display the title named title on top of my graph
As explained here: https://www.odoo.com/documentation/13.0/reference/views.html#graph
### Video/Screenshot link (optional):
Erreur:
Odoo Server Error
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 712, in parse
self._tag_root(de)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 674, in _tag_root
f(rec)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 577, in _tag_record
record = model._load_records([data], self.mode == 'update')
File "/usr/lib/python3/dist-packages/odoo/models.py", line 4053, in _load_records
data['record']._load_records_write(data['values'])
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3991, in _load_records_write
self.write(values)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 491, in write
res = super(View, self).write(self._compute_defaults(vals))
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3569, in write
fields[0].determine_inverse(real_recs)
File "/usr/lib/python3/dist-packages/odoo/fields.py", line 1114, in determine_inverse
getattr(records, self.inverse)()
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 299, in _inverse_arch
view.write(data)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 491, in write
res = super(View, self).write(self._compute_defaults(vals))
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3564, in write
real_recs._validate_fields(set(vals) - set(inverse_fields))
File "/usr/lib/python3/dist-packages/odoo/models.py", line 1176, in _validate_fields
check(self)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 404, in _check_xml
raise ValidationError(_('Invalid view %s definition in %s') % (view_name, view.arch_fs))
odoo.exceptions.ValidationError: ('Définition de vue solumat.dashboard.graph (Solumat.dashboard_graph_view) non conforme dans Solumat/views/dashboard.xml', None)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/odoo/http.py", line 624, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/usr/lib/python3/dist-packages/odoo/http.py", line 310, in _handle_exception
raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 14, in reraise
raise value
File "/usr/lib/python3/dist-packages/odoo/http.py", line 669, in dispatch
result = self._call_function(**self.params)
File "/usr/lib/python3/dist-packages/odoo/http.py", line 350, in _call_function
return checked_call(self.db, *args, **kwargs)
File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 94, in wrapper
return f(dbname, *args, **kwargs)
File "/usr/lib/python3/dist-packages/odoo/http.py", line 339, in checked_call
result = self.endpoint(*a, **kw)
File "/usr/lib/python3/dist-packages/odoo/http.py", line 915, in __call__
return self.method(*args, **kw)
File "/usr/lib/python3/dist-packages/odoo/http.py", line 515, in response_wrap
response = f(*args, **kw)
File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 1326, in call_button
action = self._call_kw(model, method, args, kwargs)
File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 1314, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "/usr/lib/python3/dist-packages/odoo/api.py", line 387, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "/usr/lib/python3/dist-packages/odoo/api.py", line 374, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "<decorator-gen-66>", line 2, in button_immediate_upgrade
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_module.py", line 72, in check_and_log
return method(self, *args, **kwargs)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_module.py", line 634, in button_immediate_upgrade
return self._button_immediate_function(type(self).button_upgrade)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_module.py", line 573, in _button_immediate_function
modules.registry.Registry.new(self._cr.dbname, update_module=True)
File "/usr/lib/python3/dist-packages/odoo/modules/registry.py", line 86, in new
odoo.modules.load_modules(registry._db, force_demo, status, update_module)
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 419, in load_modules
force, status, report, loaded_modules, update_module, models_to_check)
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 315, in load_marked_modules
perform_checks=perform_checks, models_to_check=models_to_check
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 225, in load_module_graph
load_data(cr, idref, mode, kind='data', package=package, report=report)
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 68, in load_data
tools.convert_file(cr, package.name, filename, idref, mode, noupdate, kind, report)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 736, in convert_file
convert_xml_import(cr, module, fp, idref, mode, noupdate, report)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 803, in convert_xml_import
obj.parse(doc.getroot())
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 721, in parse
exc_info[2]
File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 13, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 712, in parse
self._tag_root(de)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 674, in _tag_root
f(rec)
File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 577, in _tag_record
record = model._load_records([data], self.mode == 'update')
File "/usr/lib/python3/dist-packages/odoo/models.py", line 4053, in _load_records
data['record']._load_records_write(data['values'])
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3991, in _load_records_write
self.write(values)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 491, in write
res = super(View, self).write(self._compute_defaults(vals))
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3569, in write
fields[0].determine_inverse(real_recs)
File "/usr/lib/python3/dist-packages/odoo/fields.py", line 1114, in determine_inverse
getattr(records, self.inverse)()
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 299, in _inverse_arch
view.write(data)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 491, in write
res = super(View, self).write(self._compute_defaults(vals))
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3564, in write
real_recs._validate_fields(set(vals) - set(inverse_fields))
File "/usr/lib/python3/dist-packages/odoo/models.py", line 1176, in _validate_fields
check(self)
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 404, in _check_xml
raise ValidationError(_('Invalid view %s definition in %s') % (view_name, view.arch_fs))
odoo.tools.convert.ParseError: "Définition de vue solumat.dashboard.graph (Solumat.dashboard_graph_view) non conforme dans Solumat/views/dashboard.xml
None" while parsing /mnt/extra-addons/Solumat/views/dashboard.xml:2, near
<odoo>
<record id="dashboard_graph_view" model="ir.ui.view">
<field name="name">solumat.dashboard.graph</field>
<field name="model">solumat.inventaire</field>
<field name="arch" type="xml">
<graph type="bar">
<field name="used" type="row" title="title"/>
</graph>
</field>
</record>
</odoo>
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
1
Reply
1822
Views
up
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign up