mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-18 09:47:14 +00:00
fix: completed DC will not appear in a delivery trip (#41655)
* fix: completed DC will not appear in a delivery trip * fix: completed DC will not appear in a delivery trip
This commit is contained in:
committed by
GitHub
parent
3c3313594d
commit
4f0214d00e
@@ -223,7 +223,7 @@ erpnext.stock.DeliveryNoteController = class DeliveryNoteController extends (
|
||||
);
|
||||
}
|
||||
|
||||
if (doc.docstatus == 1 && frappe.model.can_create("Delivery Trip")) {
|
||||
if (doc.docstatus == 1 && doc.status != "Completed" && frappe.model.can_create("Delivery Trip")) {
|
||||
this.frm.add_custom_button(
|
||||
__("Delivery Trip"),
|
||||
function () {
|
||||
|
||||
@@ -58,9 +58,11 @@ frappe.ui.form.on("Delivery Trip", {
|
||||
date_field: "posting_date",
|
||||
setters: {
|
||||
company: frm.doc.company,
|
||||
customer: null,
|
||||
},
|
||||
get_query_filters: {
|
||||
company: frm.doc.company,
|
||||
status: ["Not In", ["Completed", "Cancelled"]],
|
||||
},
|
||||
});
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user