revert: changes to energy point log

This commit is contained in:
barredterra 2024-10-08 18:56:13 +01:00 committed by Akhil Narang
parent daa6c617d4
commit ac089c177a
No known key found for this signature in database
GPG key ID: 9DCC61E211BF645F

View file

@ -115,11 +115,12 @@ def get_notification_message(doc):
title = get_title(doc.reference_doctype, doc.reference_name) title = get_title(doc.reference_doctype, doc.reference_name)
if doc.type == "Auto": if doc.type == "Auto":
owner_name = frappe.bold("You")
if points == 1: if points == 1:
message = _("You gained {1} point for {2} {3}") message = _("{0} gained {1} point for {2} {3}")
else: else:
message = _("You gained {1} points for {2} {3}") message = _("{0} gained {1} points for {2} {3}")
message = message.format(frappe.bold(points), doc.rule, get_title_html(title)) message = message.format(owner_name, frappe.bold(points), doc.rule, get_title_html(title))
elif doc.type == "Appreciation": elif doc.type == "Appreciation":
if points == 1: if points == 1:
message = _("{0} appreciated your work on {1} with {2} point") message = _("{0} appreciated your work on {1} with {2} point")