chore: rename recalculating to updating

(cherry picked from commit f6e16c1180)
This commit is contained in:
Mihir Kandoi
2025-07-18 16:06:14 +05:30
committed by Mergify
parent 6adc8a09c0
commit 36a9f3b3e9
2 changed files with 6 additions and 6 deletions

View File

@@ -88,9 +88,9 @@ frappe.ui.form.on("Project", {
); );
frm.add_custom_button( frm.add_custom_button(
__("Recalculate Costing and Billing"), __("Update Costing and Billing"),
() => { () => {
frm.events.recalculate_costing_and_billing(frm); frm.events.update_costing_and_billing(frm);
}, },
__("Actions") __("Actions")
); );
@@ -129,12 +129,12 @@ frappe.ui.form.on("Project", {
} }
}, },
recalculate_costing_and_billing: function (frm) { update_costing_and_billing: function (frm) {
frappe.call({ frappe.call({
method: "erpnext.projects.doctype.project.project.recalculate_costing_and_billing", method: "erpnext.projects.doctype.project.project.update_costing_and_billing",
args: { project: frm.doc.name }, args: { project: frm.doc.name },
freeze: true, freeze: true,
freeze_message: __("Recalculating Costing and Billing fields against this Project..."), freeze_message: __("Updating Costing and Billing fields against this Project..."),
callback: function (r) { callback: function (r) {
if (r && !r.exc) { if (r && !r.exc) {
frappe.msgprint(__("Costing and Billing fields has been updated")); frappe.msgprint(__("Costing and Billing fields has been updated"));

View File

@@ -749,7 +749,7 @@ def calculate_total_purchase_cost(project: str | None = None):
@frappe.whitelist() @frappe.whitelist()
def recalculate_costing_and_billing(project: str | None = None): def update_costing_and_billing(project: str | None = None):
project = frappe.get_doc("Project", project) project = frappe.get_doc("Project", project)
project.update_costing() project.update_costing()
project.db_update() project.db_update()