mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-15 03:01:22 +00:00
fix: javascript: execution blocked by undefined route options (#33405)
Some implementations of DocField.get_route_options_for_new_doc() returned no value instead of an empty object in some cases, which caused a JavaScript error.
This commit is contained in:
committed by
GitHub
parent
d054f37602
commit
3c393bfdc5
@@ -20,7 +20,7 @@ frappe.ui.form.on("Project", {
|
||||
onload: function (frm) {
|
||||
const so = frm.get_docfield("sales_order");
|
||||
so.get_route_options_for_new_doc = () => {
|
||||
if (frm.is_new()) return;
|
||||
if (frm.is_new()) return {};
|
||||
return {
|
||||
"customer": frm.doc.customer,
|
||||
"project_name": frm.doc.name
|
||||
|
||||
Reference in New Issue
Block a user