Adjusting Mantis Generated Emails

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
newmantisuser
Posts: 68
Joined: 06 Aug 2012, 18:13

Adjusting Mantis Generated Emails

Post by newmantisuser »

Hi guys,

Wondering if there is a way to 'trim the fat' from Mantis generated emails. I have had reports from users that there is 'to much' information in the emails generated by Mantis. Is there a way to pick and choose what gets included in an email Generated by Mantis, say for example when a user closes a bug, Mantis will generate and send out emails to everyone associated with the bug with all the gory details. See a sample email generated from Mantis below:

The following issue has been CLOSED
======================================================================
https://mantis/mantis/view.php?id=951 [^]
======================================================================
Reported By: xxxx
Assigned To: xxxx
======================================================================
Project: XXXX
Issue ID: 951
Category: Corrective Action
Reproducibility: have not tried
Severity: minor
Priority: normal
Status: closed
Basis for Change Request: To Fix
Client Name (If applicable):
Job Type (If applicable):
Job Date (If applicable):
Vessel (If applicable):
Location (If applicable):
Applies To: Software
Applies to Other: XXXXX
Corrective Action Taken: An official git repository has been created for both
field and office. Change Notice Closed https://mantis/mantis/view.php?id=1081 [^]
Corrective Action Verified: HSEQ Mgr verified with Sr. Software Engineer
Root Cause: No internet connection when the team are in the
field.
Resolution: fixed
Fixed in Version:
======================================================================
Date Submitted: 2012-11-27 12:18 NST
Last Modified: 2013-04-09 09:47 NDT
======================================================================
Summary: Office version of Processing files differ from field
versions
Description:
Several files in btguitools, libgsff and gitnarc differ from the field
versions. Specifically:

The field version of btguitools includes controls for Mosaic and favours btimage
over vprofile

The office version of libgsff contains alternate routines for memory allocation

The field version of gitnarc contains extra error checking code
======================================================================
Relationships BUG ID Summary
----------------------------------------------------------------------
parent of 0000954 Office version of Processing files diff...
======================================================================

----------------------------------------------------------------------
(0002507) xxxx (administrator) - 2013-02-11 22:47
https://mantis/mantis/view.php?id=951#c2507 [^]
----------------------------------------------------------------------
Note from Steve: This will be resolved when we confirm the official version.

Issue History
Date Modified Username Field Change
======================================================================
2012-11-27 12:18 xxxx New Issue
2012-11-27 12:18 xxxx Status new => assigned
2012-11-27 12:18 xxxx Assigned To => smotty
2012-11-27 14:46 xxxx Description Updated
2012-11-27 15:59 xxxx Description Updated
2012-11-27 16:09 xxx Relationship added parent of 0000954
2013-02-11 22:47 xxxx Note Added: 0002507
2013-04-09 09:47 xxxx Corrective Action Taken Field version has the
most trusted version of code: updating office version to match. => An official
git repository has been created for both field and office. Change Notice Closed
https://mantis/mantis/view.php?id=1081 [^]
2013-04-09 09:47 xxxx Corrective Action Verified => HSEQ Mgr verified
with Sr. Software Engineer
2013-04-09 09:47 xxxx Root Cause => No internet
connection when the team are in the field.
2013-04-09 09:47 xxxx Status assigned => closed
2013-04-09 09:47 xxxx Resolution open => fixed

I think I may have to edit core/email_api.php but have no Idea where to start. Can someone give me a few pointers? Ideally I would like something such as the following in the Mantis Generated Email:

Subject: [SBI 2 - Project 200 0000951]: Office version of Processing files differ from field versions The issue has been CLOSED:
for more details, visit https://mantis/mantis/view.php?id=951
angel
Posts: 4
Joined: 28 Feb 2013, 12:35

Re: Adjusting Mantis Generated Emails

Post by angel »

newmantisuser
Posts: 68
Joined: 06 Aug 2012, 18:13

Re: Adjusting Mantis Generated Emails

Post by newmantisuser »

Hello,

Thanks for the reply. I appreciate it. At the end of the work day yesterday I found the same code buried deep inside the email _api.php and just started to get into commenting things out before I left for the day.

Thank you so much for researching this issue. :)

You would think the Mantis folks would atleast provide instruction or a plug-in to modify Mantis generated email.

Cheers :)
atrol
Site Admin
Posts: 8571
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Adjusting Mantis Generated Emails

Post by atrol »

Please use Search before posting and read the Manual
Post Reply