fix: description overwrite on qty change (#44606)

This commit is contained in:
rohitwaghchaure
2024-12-09 12:37:36 +05:30
committed by GitHub
parent a08a66df92
commit 9ad79625e0

View File

@@ -267,18 +267,21 @@ frappe.ui.form.on("Material Request", {
},
callback: function (r) {
const d = item;
const allow_to_change_fields = [
let allow_to_change_fields = [
"actual_qty",
"projected_qty",
"min_order_qty",
"item_name",
"description",
"stock_uom",
"uom",
"conversion_factor",
"stock_qty",
];
if (overwrite_warehouse) {
allow_to_change_fields.push("description");
}
if (!r.exc) {
$.each(r.message, function (key, value) {
if (!d[key] || allow_to_change_fields.includes(key)) {