non c'entra niente con il file che ho io... sei sicuro che siano gli addons della versione 7?
un estratto:
from openerp.osv import fields, osv
from openerp import netsvc
from webkit_report import WebKitParser
from openerp.report.report_sxw import rml_parse
def register_report(name, model, tmpl_path, parser=rml_parse):
"""Register the report into the services"""
name = 'report.%s' % name
if netsvc.Service._services.get(name, False):
service = netsvc.Service._services[name]
if isinstance(service, WebKitParser):
#already instantiated properly, skip it
return
if hasattr(service, 'parser'):
parser = service.parser
del netsvc.Service._services[name]
WebKitParser(name, model, tmpl_path, parser=parser)
class ReportXML(osv.osv):
def __init__(self, pool, cr):
super(ReportXML, self).__init__(pool, cr)
def register_all(self,cursor):
value = super(ReportXML, self).register_all(cursor)
cursor.execute("SELECT * FROM ir_act_report_xml WHERE report_type = 'webkit'")
records = cursor.dictfetchall()
for record in records:
register_report(record['report_name'], record['model'], record['report_rml'])
return value