I'm starting to use odoo but I do not start very well, nothing but mistakes, generate a simple module to start
"%pyodoo%\python.exe" odoo-bin scaffold mi_module
uncomment all the commented lines and I get the following error
Error:
Odoo Server Error
Traceback (most recent call last):
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 741, in parse
self._tags[rec.tag](rec, de, mode=mode)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 651, in _tag_record
id = self.env(context=rec_context)['ir.model.data']._update(rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode)
_load_data(cr, module_name, idref, mode, kind='data')
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\modules\loading.py", line 94, in _load_data
tools.convert_file(cr, module_name, filename, idref, mode, noupdate, kind, report)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 788, in convert_file
convert_xml_import(cr, module, fp, idref, mode, noupdate, report)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 849, in convert_xml_import
obj.parse(doc.getroot(), mode=mode)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 738, in parse
self.parse(rec, mode)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 748, in parse
exc_info[2]
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\pycompat.py", line 86, in reraise
raise value.with_traceback(tb)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 741, in parse
self._tags[rec.tag](rec, de, mode=mode)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\tools\convert.py", line 651, in _tag_record
id = self.env(context=rec_context)['ir.model.data']._update(rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\addons\base\ir\ir_model.py", line 1469, in _update
record = record.create(values)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\addons\base\ir\ir_actions.py", line 217, in create
return super(IrActionsActWindow, self).create(vals)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\addons\base\ir\ir_actions.py", line 46, in create
res = super(IrActions, self).create(vals)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\models.py", line 3278, in create
record = self.browse(self._create(old_vals))
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\models.py", line 3431, in _create
self._validate_fields(vals)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\models.py", line 967, in _validate_fields
check(self)
File "C:\Program Files (x86)\Odoo 11.0\server\odoo\addons\base\ir\ir_actions.py", line 125, in _check_model
raise ValidationError(_('Invalid model name %r in action definition.') % action.res_model)
odoo.tools.convert.ParseError: "Nombre de modelo 'mi_module.mi_module' no valido en la definición de la acción.
None" while parsing file:/c:/program%20files%20(x86)/odoo%2011.0/server/odoo/addons/mi_module/views/views.xml:10, near
<record model="ir.actions.act_window" id="mi_module.action_window">
<field name="name">mi_module window</field>
<field name="res_model">mi_module.mi_module</field>
<field name="view_mode">tree,form</field>
</record>
simply generate the module to start and then enter odoo, install the module but I get this error. I am using windows and the final version of odoo. Should I use another version of odoo to start?
<field name="res_model">mi_module.mi_module</field>
> you need to write the model name there, instead of the module name. Take a look at the error string: "Invalid model name" – ChesuCR