fix: Bulk Payment Entry from PO/SO (#34942)
fix: Bulk Payment Entry from PO/SO (#34942)
Co-authored-by: Nihantra Patel <n.patel.serpentcs@gmail.com>
(cherry picked from commit f1acc5fabb)
Co-authored-by: Solufy Solution <34390782+Solufyin@users.noreply.github.com>
This commit is contained in:
@@ -43,7 +43,7 @@ frappe.listview_settings['Purchase Order'] = {
|
|||||||
});
|
});
|
||||||
|
|
||||||
listview.page.add_action_item(__("Advance Payment"), ()=>{
|
listview.page.add_action_item(__("Advance Payment"), ()=>{
|
||||||
erpnext.bulk_transaction_processing.create(listview, "Purchase Order", "Advance Payment");
|
erpnext.bulk_transaction_processing.create(listview, "Purchase Order", "Payment Entry");
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ frappe.listview_settings['Sales Order'] = {
|
|||||||
});
|
});
|
||||||
|
|
||||||
listview.page.add_action_item(__("Advance Payment"), ()=>{
|
listview.page.add_action_item(__("Advance Payment"), ()=>{
|
||||||
erpnext.bulk_transaction_processing.create(listview, "Sales Order", "Advance Payment");
|
erpnext.bulk_transaction_processing.create(listview, "Sales Order", "Payment Entry");
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ def task(doc_name, from_doctype, to_doctype):
|
|||||||
"Sales Order": {
|
"Sales Order": {
|
||||||
"Sales Invoice": sales_order.make_sales_invoice,
|
"Sales Invoice": sales_order.make_sales_invoice,
|
||||||
"Delivery Note": sales_order.make_delivery_note,
|
"Delivery Note": sales_order.make_delivery_note,
|
||||||
"Advance Payment": payment_entry.get_payment_entry,
|
"Payment Entry": payment_entry.get_payment_entry,
|
||||||
},
|
},
|
||||||
"Sales Invoice": {
|
"Sales Invoice": {
|
||||||
"Delivery Note": sales_invoice.make_delivery_note,
|
"Delivery Note": sales_invoice.make_delivery_note,
|
||||||
@@ -86,11 +86,11 @@ def task(doc_name, from_doctype, to_doctype):
|
|||||||
"Supplier Quotation": {
|
"Supplier Quotation": {
|
||||||
"Purchase Order": supplier_quotation.make_purchase_order,
|
"Purchase Order": supplier_quotation.make_purchase_order,
|
||||||
"Purchase Invoice": supplier_quotation.make_purchase_invoice,
|
"Purchase Invoice": supplier_quotation.make_purchase_invoice,
|
||||||
"Advance Payment": payment_entry.get_payment_entry,
|
|
||||||
},
|
},
|
||||||
"Purchase Order": {
|
"Purchase Order": {
|
||||||
"Purchase Invoice": purchase_order.make_purchase_invoice,
|
"Purchase Invoice": purchase_order.make_purchase_invoice,
|
||||||
"Purchase Receipt": purchase_order.make_purchase_receipt,
|
"Purchase Receipt": purchase_order.make_purchase_receipt,
|
||||||
|
"Payment Entry": payment_entry.get_payment_entry,
|
||||||
},
|
},
|
||||||
"Purchase Invoice": {
|
"Purchase Invoice": {
|
||||||
"Purchase Receipt": purchase_invoice.make_purchase_receipt,
|
"Purchase Receipt": purchase_invoice.make_purchase_receipt,
|
||||||
@@ -98,7 +98,7 @@ def task(doc_name, from_doctype, to_doctype):
|
|||||||
},
|
},
|
||||||
"Purchase Receipt": {"Purchase Invoice": purchase_receipt.make_purchase_invoice},
|
"Purchase Receipt": {"Purchase Invoice": purchase_receipt.make_purchase_invoice},
|
||||||
}
|
}
|
||||||
if to_doctype in ["Advance Payment", "Payment Entry"]:
|
if to_doctype in ["Payment Entry"]:
|
||||||
obj = mapper[from_doctype][to_doctype](from_doctype, doc_name)
|
obj = mapper[from_doctype][to_doctype](from_doctype, doc_name)
|
||||||
else:
|
else:
|
||||||
obj = mapper[from_doctype][to_doctype](doc_name)
|
obj = mapper[from_doctype][to_doctype](doc_name)
|
||||||
|
|||||||
Reference in New Issue
Block a user