Revert "fix: docfield of sales_order is not fetching route options for new doc (#21123)"

This reverts commit 5c54adec28.

(cherry picked from commit e5fe00cf58)
This commit is contained in:
Deepesh Garg 2020-06-09 17:41:27 +05:30 committed by mergify-bot
parent 023f35bed7
commit c1bc819f18

View File

@ -18,7 +18,7 @@ frappe.ui.form.on("Project", {
};
},
onload: function (frm) {
var so = frm.get_docfield("Project", "sales_order");
var so = frappe.meta.get_docfield("Project", "sales_order");
so.get_route_options_for_new_doc = function (field) {
if (frm.is_new()) return;
return {
@ -135,4 +135,4 @@ function open_form(frm, doctype, child_doctype, parentfield) {
frappe.ui.form.make_quick_entry(doctype, null, null, new_doc);
});
}
}