mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-19 13:09:17 +00:00
Merge pull request #45344 from iamejaaz/broken-bom-tree
fix: broken image issue in BOM Tree
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
<div style="padding: 15px;">
|
<div style="padding: 15px;">
|
||||||
<div class="row mb-5">
|
<div class="row mb-5">
|
||||||
<div class="col-md-5" style="max-height: 500px">
|
<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">
|
<div class="border image-field " style="overflow: hidden;border-color:#e6e6e6">
|
||||||
<img class="responsive" style="width: 100%;" src={{ data.image }}>
|
<img class="responsive" style="width: 100%;" src={{ data.image }}>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ frappe.treeview_settings["BOM"] = {
|
|||||||
if (node.is_root && node.data.value != "BOM") {
|
if (node.is_root && node.data.value != "BOM") {
|
||||||
frappe.model.with_doc("BOM", node.data.value, function () {
|
frappe.model.with_doc("BOM", node.data.value, function () {
|
||||||
var bom = frappe.model.get_doc("BOM", node.data.value);
|
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.description = bom.description || "";
|
||||||
node.data.item_code = bom.item || "";
|
node.data.item_code = bom.item || "";
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user