From 027db0b41e74685be3e6ecb5703757f81e973d6f Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Thu, 25 Feb 2021 17:48:33 +0530 Subject: [PATCH 1/2] fix(HR): hide "more" button from team updates --- erpnext/hr/page/team_updates/team_updates.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/erpnext/hr/page/team_updates/team_updates.js b/erpnext/hr/page/team_updates/team_updates.js index 13d0074660..991b316e1e 100644 --- a/erpnext/hr/page/team_updates/team_updates.js +++ b/erpnext/hr/page/team_updates/team_updates.js @@ -36,7 +36,7 @@ frappe.team_updates = { start: me.start }, callback: function(r) { - if(r.message) { + if (r.message && r.message.length > 0) { r.message.forEach(function(d) { me.add_row(d); }); @@ -77,4 +77,4 @@ frappe.team_updates = { $(frappe.render_template('team_update_row', data)).appendTo(me.body) } -} \ No newline at end of file +} From ecde26409b9264e3b4185861cb35f4a5318c83fe Mon Sep 17 00:00:00 2001 From: Deepesh Garg <42651287+deepeshgarg007@users.noreply.github.com> Date: Tue, 2 Mar 2021 18:54:50 +0530 Subject: [PATCH 2/2] Update team_updates.js --- erpnext/hr/page/team_updates/team_updates.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/hr/page/team_updates/team_updates.js b/erpnext/hr/page/team_updates/team_updates.js index 991b316e1e..358329748e 100644 --- a/erpnext/hr/page/team_updates/team_updates.js +++ b/erpnext/hr/page/team_updates/team_updates.js @@ -75,6 +75,6 @@ frappe.team_updates = { } me.last_feed_date = date; - $(frappe.render_template('team_update_row', data)).appendTo(me.body) + $(frappe.render_template('team_update_row', data)).appendTo(me.body); } }