Webkit report with a slash in the string

Bug #912744 reported by Guewen Baconnier @ Camptocamp
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Confirmed
Undecided
Unassigned

Bug Description

Hello,

In version 6.0 (not tested in 6.1) if we create a report like :

        <report id="sale.report_sale_order"
                name="sale.order.webkit"
                auto="False"
                model="sale.order"
                file="specific_reports/report/sale_order.mako"
                string="Quotation / Order"
                report_type="webkit" />

We won't be able to print the report, we'll have an error "File not found".

That's because the name (so the string "Quotation / Order" in my example) of the report is used to generate the file name and it contains a /.

addons/report_webkit/webkit_report.py line 104-106 :
        tmp_dir = tempfile.gettempdir()
        out = report_xml.name+str(time.time())+'.pdf'
        out = os.path.join(tmp_dir, out.replace(' ',''))

Best Regards
Guewen

Amit Parik (amit-parik)
Changed in openobject-addons:
status: New → Confirmed
assignee: nobody → Nicolas Bessi - Camptocamp (nbessi-c2c)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.