This commit is contained in:
2021-10-19 16:21:34 +08:00
parent 3ce8723de2
commit c52f40adbd
7 changed files with 10 additions and 10 deletions

View File

@@ -22,10 +22,10 @@ class MessageTemplate::ProjectIssue < MessageTemplate
managers = managers.where.not(id: receiver.id) unless receiver.user_template_message_setting.notification_body["ManageProject::Issue"]
end
end
return '', '', '' if receivers.blank?
project = issue&.project
owner = project&.owner
receivers = managers + followers
return '', '', '' if receivers.blank?
content = sys_notice.gsub('{nickname1}', operator&.real_name).gsub('{nickname2}', owner&.real_name).gsub('{repository}', project&.name).gsub('{title}', issue&.subject)
url = notification_url.gsub('{owner}', owner&.login).gsub('{identifier}', project&.identifier).gsub('{id}', issue&.id.to_s)