fix: encode filters for URI

This commit is contained in:
barredterra 2022-02-09 17:53:33 +01:00
parent b35b637d01
commit 5811d9e318

View File

@ -40,7 +40,11 @@ frappe.query_reports["DATEV"] = {
}); });
query_report.page.add_menu_item(__("Download DATEV File"), () => { query_report.page.add_menu_item(__("Download DATEV File"), () => {
const filters = JSON.stringify(query_report.get_values()); const filters = encodeURIComponent(
JSON.stringify(
query_report.get_values()
)
);
window.open(`/api/method/erpnext.regional.report.datev.datev.download_datev_csv?filters=${filters}`); window.open(`/api/method/erpnext.regional.report.datev.datev.download_datev_csv?filters=${filters}`);
}); });