Skip to content

Commit

Permalink
fix: broken image issue in BOM Tree
Browse files Browse the repository at this point in the history
  • Loading branch information
iamejaaz committed Jan 20, 2025
1 parent d13c036 commit 7c6e279
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion erpnext/manufacturing/doctype/bom/bom_item_preview.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div style="padding: 15px;">
<div class="row mb-5">
<div class="col-md-5" style="max-height: 500px">
{% if data.image %}
{% if data.image && (data.image).replace("''", "").length %}
<div class="border image-field " style="overflow: hidden;border-color:#e6e6e6">
<img class="responsive" style="width: 100%;" src={{ data.image }}>
</div>
Expand Down
2 changes: 1 addition & 1 deletion erpnext/manufacturing/doctype/bom/bom_tree.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ frappe.treeview_settings["BOM"] = {
if (node.is_root && node.data.value != "BOM") {
frappe.model.with_doc("BOM", node.data.value, function () {
var bom = frappe.model.get_doc("BOM", node.data.value);
node.data.image = escape(bom.image) || "";
node.data.image = bom.image || "";
node.data.description = bom.description || "";
node.data.item_code = bom.item || "";
});
Expand Down

0 comments on commit 7c6e279

Please sign in to comment.