Hi everyone. Can't get variable in my mako report like that - ${fun('123')}. The code below seems correct, but I get in log: 'fun is undefined'.
Maybe, the path to my mako-html file isn't correct. I don't know. But I've tried a lot of path and no result...
class main_report_parser(report_sxw.rml_parse):
def __init__(self, cr, uid, name, context):
super(main_report_parser, self).__init__(cr, uid, name, context=context)
self.localcontext.update({'fun': self.getGTD})
def getGTD(self, word):
return word
report_sxw.report_sxw('report.account.report_invoice', 'account.invoice', 'new/l10n_ru_doc/report/invoice.htm', parser=main_report_parser)
Thank you a lot