fix: bom stock report color issue
This commit is contained in:
parent
34d07b6306
commit
610d9ca649
@ -25,11 +25,11 @@ frappe.query_reports["BOM Stock Report"] = {
|
|||||||
],
|
],
|
||||||
"formatter": function(value, row, column, data, default_formatter) {
|
"formatter": function(value, row, column, data, default_formatter) {
|
||||||
value = default_formatter(value, row, column, data);
|
value = default_formatter(value, row, column, data);
|
||||||
if (column.id == "Item"){
|
if (column.id == "item"){
|
||||||
if (data["Enough Parts to Build"] > 0){
|
if (data["Enough Parts to Build"] > 0){
|
||||||
value = `<a style='color:green' href="#Form/Item/${data['Item']}" data-doctype="Item">${data['Item']}</a>`
|
value = `<a style='color:green' href="#Form/Item/${data['item']}" data-doctype="Item">${data['item']}</a>`;
|
||||||
} else {
|
} else {
|
||||||
value = `<a style='color:red' href="#Form/Item/${data['Item']}" data-doctype="Item">${data['Item']}</a>`
|
value = `<a style='color:red' href="#Form/Item/${data['item']}" data-doctype="Item">${data['item']}</a>`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return value
|
return value
|
||||||
|
Loading…
Reference in New Issue
Block a user