diff --git a/frappe/public/js/frappe/form/sidebar/attachments.js b/frappe/public/js/frappe/form/sidebar/attachments.js index 9e1ea30c6e..ffd0b513a2 100644 --- a/frappe/public/js/frappe/form/sidebar/attachments.js +++ b/frappe/public/js/frappe/form/sidebar/attachments.js @@ -1,8 +1,6 @@ // Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors // MIT License. See license.txt - - frappe.ui.form.Attachments = Class.extend({ init: function(opts) { $.extend(this, opts); @@ -84,17 +82,9 @@ frappe.ui.form.Attachments = Class.extend({ }; } - let icon; - // REDESIGN-TODO: set icon using frappe.utils.icon - if (attachment.is_private) { - icon = `
`; - } else { - icon = ``; - } + const icon = ` + ${frappe.utils.icon(attachment.is_private ? 'lock' : 'unlock', 'sm ml-0')} + `; $(`