Ir al contenido
Menú
Se marcó esta pregunta
3 Respuestas
4689 Vistas

Hi !

I am new to OpenERP. Just installed v7, and tried the Ontario Payroll module. I get this error :

"AttributeError: View definition error for inherited view 'l10n_ca_on_hr_payroll.hr_contract_form_inherit' on model 'hr.contract': Element '<xpath expr="/form/notebook/page/group/field[@name='working_hours']">' not found in parent view 'hr_contract.hr_contract_view_form'

when I try to create a Contract.

Moreover, now when I log in I am greeted with the message:

"except_orm: ('ValidateError', u'Error occurred while validating the field(s) arch: Invalid XML for View Architecture!')"

I am just finding my way around OpenERP, but have good knowledge of XML and programming. Any pointers of where to start fixing this would be appreciated.

Cheers, Raul

Avatar
Descartar

try contacting the people who developed the ontario payroll module,

Autor

This is why I posted the question, since there is no contact I could find for the developer

Autor Mejor respuesta

As per Yannick's advice, replacing

expr="/form/notebook/page/group/field[@name='working_hours']"

with

expr="//field[@name='working_hours']"

in "l10n_ca_on_hr_payroll_view.xml" was enough to make it work. Not sure yet if it caused other problems, or if this is the only problem porting to v7.

Avatar
Descartar
Autor Mejor respuesta

This is why I posted the question, since there is no contact I could find for the developer.

Avatar
Descartar
Mejor respuesta

It seems Ontario Payroll isn't ported yet to v7.0 so you have a view inheritance issue. Did you took the v6.1?

Avatar
Descartar
Autor

That is true, I picked the 6.1. Now, I need some pointers on how to resolve this. I started looking at the view definitions, hope it's just a question of modifying the xpath in question to match the new location of the element in V7 of 'hr_contract.hr_contract_view_form'. Will post if that worked.

Try to replace the xpath expr by a relative one

expr="/form/notebook/page/group/field[@name='working_hours']"

by

expr="//field[@name='working_hours']"
Autor

Thanks Yannick ! That did it. How can we make this available to other interested parties ?

To contribute, you should read this: how-can-i-contribute-to-openerp And for this specific canadian module, try to contact Maxime Chambreuil on launchpad.net, he is the creator of the lp:openerp-canada project.

Publicaciones relacionadas Respuestas Vistas Actividad
5
mar 21
8864
1
sept 17
6467
8
feb 24
13396
1
sept 25
474
1
ago 25
5036