• Icon: Suggestion Suggestion
    • Resolution: Unresolved
    • None
    • Email notifications
    • None
    • 1
    • 5
    • We collect Jira feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

      NOTE: This suggestion is for JIRA Server. Using JIRA Cloud? See the corresponding suggestion.

      Mailed issue template for subtasks should show parent issue.

      The mailed issue information should have some information about the parent. Sometimes, the subtask summary doesn't really make much sense in isolation (eg JRA-5715)

          Form Name

            [JRASERVER-5722] Mailed issue template for sub tasks should show parent issue

            Hello,
            Is there a planning to do this on the near future? I'm looking to modify this also on batched notifications.
            I would like to have the parent key in the case the issue is a subtask.
            Instead of:
            [project name] / [key]
            I would like the mails to show something similar to:
            [project name] / [parent] / [key]
            I think I can modify it myself on the batchers plugin, but i can't find the way to modify the

            #* @vtlvariable name="issueKey" type="java.lang.String" *#
            

            variable of the IssueUpdateBatcher-header.vm file.
            Do you have any idea how can I do this?

            Alejandro Reyes added a comment - Hello, Is there a planning to do this on the near future? I'm looking to modify this also on batched notifications. I would like to have the parent key in the case the issue is a subtask. Instead of: [project name] / [key] I would like the mails to show something similar to: [project name] / [parent] / [key] I think I can modify it myself on the batchers plugin, but i can't find the way to modify the #* @vtlvariable name= "issueKey" type= "java.lang. String " *# variable of the IssueUpdateBatcher-header.vm file. Do you have any idea how can I do this?

            Is there a way to add this to text email format. I added following code to issuesummary.vm in
            /data/jira/atlassian-jira/WEB-INF/classes/templates/email/text/includes

            #if ($issue.isSubTask())
            $stringUtils.leftPad($i18n.getText("Parent Key"),$padSize):
            ${issue.getParentObject().getKey()}
            #end
            When I add a comment to a subtask, the parent task key appears in the email generated, howwever it does not show up when a subtask is created. Do I need to add code somewhere else, so I can see parent key in email generated on creation of subtask?

            Komal Mathur added a comment - Is there a way to add this to text email format. I added following code to issuesummary.vm in /data/jira/atlassian-jira/WEB-INF/classes/templates/email/text/includes #if ($issue.isSubTask()) $stringUtils.leftPad($i18n.getText("Parent Key"),$padSize): ${issue.getParentObject().getKey()} #end When I add a comment to a subtask, the parent task key appears in the email generated, howwever it does not show up when a subtask is created. Do I need to add code somewhere else, so I can see parent key in email generated on creation of subtask?

            Royce Wong added a comment -

            Thanks Adam. We are on 3.13.5 (WAR). Guess we will have to wait until upgrade.
            Also see: http://blogs.atlassian.com/jira/2010/05/jira-41-email-notifications.html

            Royce Wong added a comment - Thanks Adam. We are on 3.13.5 (WAR). Guess we will have to wait until upgrade. Also see: http://blogs.atlassian.com/jira/2010/05/jira-41-email-notifications.html

            AW added a comment - - edited

            In versions prior to JIRA 4.1, I'm not sure, but as of 4.1, there appears to be a new directory under:

            atlassian-jira\WEB-INF\classes\templates\email\subject

            Of course that directory all depends on your install type (Standalone, Source, WAR), so I would reference this page for more information based on your installation - http://confluence.atlassian.com/display/JIRA/Customising+Email+Content

            We haven't upgraded yet, so let me know how it goes.

            AW added a comment - - edited In versions prior to JIRA 4.1, I'm not sure, but as of 4.1, there appears to be a new directory under: atlassian-jira\WEB-INF\classes\templates\email\subject Of course that directory all depends on your install type (Standalone, Source, WAR), so I would reference this page for more information based on your installation - http://confluence.atlassian.com/display/JIRA/Customising+Email+Content We haven't upgraded yet, so let me know how it goes.

            Royce Wong added a comment - - edited

            Anyone know how\where to change the subject of email templates?

            The default are

            • [JIRA] Created: (KEY-####) Summary
            • [JIRA] Updated: (KEY-####) Summary

            I would like to add the parent key to the subject if the issue were a sub-task so they become:

            • [JIRA] Created: (KEY-#### < KEY-####) Summary
            • [JIRA] Updated: (KEY-#### < KEY-####) Summary

            where the second part "< KEY-####" is the parent's key.

            Thanks.

            Royce Wong added a comment - - edited Anyone know how\where to change the subject of email templates? The default are [JIRA] Created: (KEY-####) Summary [JIRA] Updated: (KEY-####) Summary I would like to add the parent key to the subject if the issue were a sub-task so they become: [JIRA] Created: (KEY-#### < KEY-####) Summary [JIRA] Updated: (KEY-#### < KEY-####) Summary where the second part "< KEY-####" is the parent's key. Thanks.

            AW added a comment -

            I was able to accomplish this by customizing the email templates, though I don't know how it will go when we upgrade JIRA. I simply modified the HTML template file which you can find more information on how to do that here:

            Documentation & HowTos
            http://confluence.atlassian.com/display/JIRA/Customising+Email+Content
            http://confluence.atlassian.com/display/JIRA/Modifying+JIRA+Templates+and+JSPs

            API Documentation:
            http://docs.atlassian.com/software/jira/docs/api/latest/com/atlassian/jira/issue/Issue.html
            http://confluence.atlassian.com/display/JIRA/Velocity+Context+for+Email+Templates

            For our purposes, I used the following two code snippets and placed them in the "summary-topleft.vm" file.

            #if ($issue.isSubTask())
            <tr>
            	#set ($issueParent = $issue.getParentObject())
            	<td style="width:1%;white-space:nowrap;"><b>Parent Key:</b></td>
                <td style="font-weight:bold;width:99%"><a href="${baseurl}/browse/${issueParent.getKey()}">$issueParent.getKey()</a></td>
            </tr>
            #end
            
            #if ($issue.isSubTask())
            	<span style="font-weight:bold;color:#003366;">
            		[Parent:&nbsp;<a href="${baseurl}/browse/${issueParent.getKey()}">$textutils.htmlEncode($issueParent.getSummary())</a>&nbsp;]
            		(<a href="${baseurl}/browse/${issueParent.getKey()}">$issueParent.getKey()</a>)
            	</span>&nbsp;
            	<br />
            #end
            

            AW added a comment - I was able to accomplish this by customizing the email templates, though I don't know how it will go when we upgrade JIRA. I simply modified the HTML template file which you can find more information on how to do that here: Documentation & HowTos http://confluence.atlassian.com/display/JIRA/Customising+Email+Content http://confluence.atlassian.com/display/JIRA/Modifying+JIRA+Templates+and+JSPs API Documentation: http://docs.atlassian.com/software/jira/docs/api/latest/com/atlassian/jira/issue/Issue.html http://confluence.atlassian.com/display/JIRA/Velocity+Context+for+Email+Templates For our purposes, I used the following two code snippets and placed them in the "summary-topleft.vm" file. # if ($issue.isSubTask()) <tr> #set ($issueParent = $issue.getParentObject()) <td style= "width:1%;white-space:nowrap;" ><b>Parent Key:</b></td> <td style= "font-weight:bold;width:99%" ><a href= "${baseurl}/browse/${issueParent.getKey()}" >$issueParent.getKey()</a></td> </tr> #end # if ($issue.isSubTask()) <span style= "font-weight:bold;color:#003366;" > [Parent:&nbsp;<a href= "${baseurl}/browse/${issueParent.getKey()}" >$textutils.htmlEncode($issueParent.getSummary())</a>&nbsp;] (<a href= "${baseurl}/browse/${issueParent.getKey()}" >$issueParent.getKey()</a>) </span>&nbsp; <br /> #end

            AW added a comment -

            Did any of you find a workaround for this? If you edited the email notification templates, what exactly is the counterpart to "$issue.getKey()" located in the velocity template files found here:

            atlassian-jira\WEB-INF\classes\templates\email

            We want to display the parent task by way of modifying the templates if necessary and including that variable. The way the JIRA web pages display it now would work just fine; also in the summary.vm section of the template too. Thanks for any response on this.

            AW added a comment - Did any of you find a workaround for this? If you edited the email notification templates, what exactly is the counterpart to "$issue.getKey()" located in the velocity template files found here: atlassian-jira\WEB-INF\classes\templates\email We want to display the parent task by way of modifying the templates if necessary and including that variable. The way the JIRA web pages display it now would work just fine; also in the summary.vm section of the template too. Thanks for any response on this.

            We're in the same boat. Email notifications are useless without parent task info.

            Kathy Tempesta added a comment - We're in the same boat. Email notifications are useless without parent task info.

            We are using SCRUM and divide Features into subtasks. Many subtasks reoccur on all features ("Write documentation", "Specify acceptance tests", etc.), and not having any parent issue information makes notification emails for such subtasks completely useless.

            Lars Kühne added a comment - We are using SCRUM and divide Features into subtasks. Many subtasks reoccur on all features ("Write documentation", "Specify acceptance tests", etc.), and not having any parent issue information makes notification emails for such subtasks completely useless.

            Mark, any updates so far ....?

            Deleted Account (Inactive) added a comment - Mark, any updates so far ....?

              Unassigned Unassigned
              mark@atlassian.com MarkC
              Votes:
              43 Vote for this issue
              Watchers:
              31 Start watching this issue

                Created:
                Updated: