Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

How to avoid this error when I click on « Print -> PaySlip Details »?

By
Pascal Tremblay
on 12/18/14, 10:29 AM 992 views

With these 3 rules, I can use Print/PaySlip Details :

But with this new rule, I can NOT use Print/PaySlip Details :

Here is the log error I get :

Odoo Server Error

Traceback (most recent call last): File "/home/odoo/addons/report/controllers/main.py", line 118, in report_download response = self.report_routes(reportname, docids=docids, converter='pdf') File "/home/odoo/openerp/http.py", line 388, in response_wrap response = f(*args, **kw) File "/home/odoo/addons/report_aeroo/report_controller.py", line 32, in report_routes reportname, docids=docids, converter=converter, **data) File "/home/odoo/openerp/http.py", line 388, in response_wrap response = f(*args, **kw) File "/home/odoo/addons/report/controllers/main.py", line 65, in report_routes pdf = report_obj.get_pdf(cr, uid, docids, reportname, data=options_data, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/addons/report/models/report.py", line 186, in get_pdf html = self.get_html(cr, uid, ids, report_name, data=data, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/addons/report/models/report.py", line 161, in get_html return particularreport_obj.render_html(cr, uid, ids, data=data, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/addons/report/models/abstract_report.py", line 64, in render_html return self.pool['report'].render(cr, uid, [], self._template, docargs, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/addons/report/models/report.py", line 147, in render return view_obj.render(cr, uid, template, values, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/addons/website/models/ir_ui_view.py", line 171, in render return super(view, self).render(cr, uid, id_or_xml_id, values=values, engine=engine, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/openerp/addons/base/ir/ir_ui_view.py", line 1007, in render return self.pool[engine].render(cr, uid, id_or_xml_id, qcontext, loader=loader, context=context) File "/home/odoo/openerp/api.py", line 237, in wrapper return old_api(self, *args, **kwargs) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 253, in render return self.render_node(self.get_template(id_or_xml_id, qwebcontext), qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 294, in render_node result = self.render_element(element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 292, in render_node result = self._render_tag[t_render](self, element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 426, in render_tag_call d[0] = self.render_element(element, template_attributes, generated_attributes, d) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 292, in render_node result = self._render_tag[t_render](self, element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 416, in render_tag_foreach ru.append(self.render_element(element, template_attributes, generated_attributes, copy_qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 292, in render_node result = self._render_tag[t_render](self, element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 426, in render_tag_call d[0] = self.render_element(element, template_attributes, generated_attributes, d) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 294, in render_node result = self.render_element(element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 294, in render_node result = self.render_element(element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 294, in render_node result = self.render_element(element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element g_inner.append(self.render_node(current_node, qwebcontext)) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 292, in render_node result = self._render_tag[t_render](self, element, template_attributes, generated_attributes, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 378, in render_tag_foreach enum = self.eval_object(expr, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 200, in eval_object return self.eval(expr, qwebcontext) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 197, in eval raise_qweb_exception(message="Could not evaluate expression %r" % expr, expression=expr, template=template) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 194, in eval return qwebcontext.safe_eval(expr) File "/home/odoo/openerp/addons/base/ir/ir_qweb.py", line 80, in safe_eval return eval(expr, None, locals_dict, nocopy=True, locals_builtins=True) File "/home/odoo/openerp/tools/safe_eval.py", line 313, in safe_eval return eval(c, globals_dict, locals_dict) File "", line 1, in <module> File "/home/odoo/addons/hr_payroll/report/report_payslip_details.py", line 65, in get_details_by_rule_category parents = get_recursive_parent(rule_categories) File "/home/odoo/addons/hr_payroll/report/report_payslip_details.py", line 44, in get_recursive_parent rule_categories.insert(0, rule_categories[0].parent_id) QWebException: "'hr.salary.rule.category' object has no attribute 'insert'" while evaluating 'get_details_by_rule_category(o.details_by_salary_rule_category)'

 

Thanks

Can you check the rules, are there any insert keyword in any of them?

Ivan
on 12/18/14, 12:10 PM

I'm sorry, but I don't understand what you mean by « insert keyword ». thanks

Pascal Tremblay
on 12/18/14, 12:25 PM

The rules are basically python codes/snippets. Are there any rules with the work insert in it?

Ivan
on 12/18/14, 7:40 PM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

2 follower(s)

Stats

Asked: 12/18/14, 10:29 AM
Seen: 992 times
Last updated: 3/16/15, 8:10 AM