Problem sending xporter attachment in send custom email

Liesa Pugsley January 10, 2016

I have set up a post function that generates an xporter document and then attaches it to the issue at the transition.  Also in the post function, I have a Send Custom email (after the xporter function) that will send an email with all the attachments (including the one just added by xporter).  I find that all the other attachments are being sent with the email except the xporter document.  The document is attached to the issue but not included in the custom email. 

Using JIRA 6.4.10 and latest Xporter and Script Runner add ons.

Has anyone else experienced this type of problem?

1 answer

0 votes
Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 22, 2016

Hi Liesa,

Could you please post the code for the post function as well as the version of the Script Runner and Exporter plugin that you are using so that we can try to replicate your issue.

Many Thanks

Kristian

Liesa Pugsley January 22, 2016

I used the standard items. 

The generation of the document is first.  The sending of the custom email is last.

The items in order are:

  1. Set issue status to the linked status of the destination workflow step
  2. Add a comment to the issue if one is entered during transition
  3. Update change history for an issue and store the issue in the database
  4. File will be created from the template <template name> in the PDF format and it will be attached to the issue
  5. Reindex an issue to keep indexes in sync with the database
  6. Fire a generic event that can be processed by the listeners
  7. Script workflow function:  Send an email based on the provided template if conditions are met., with subject:  <subject line>

The email is sent but the xporter attachment is not with the email.  Only attachments added before this transition.  The condition on the email is that the issue status is equal to that of the transition.

I am running Script Runner 3.1.4 and Xporter 3.4.6 

Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 24, 2016

Hi Liesa,

In order to be able to replicate this. I will need the code and configuration for the script workflow function inside step 7 and the configuration for the template used to create the file in step 4.

Please can you screenshot how you have configured each post function.

Can you please provide this information if you require further assistance.

Thanks

Kristian

Liesa Pugsley January 27, 2016

Step 4: 

image2016-1-28 15:56:26.png

Liesa Pugsley January 27, 2016

Step 7:

image2016-1-28 16:4:28.png

image2016-1-28 16:5:41.png

Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 28, 2016

Hi Liesa,

I notice from the screenshots that you have slected the All attachments checkbox which will ignore the code below.

Also with the post functions for creating the pdf and sending the email these should be the first to in the list.

Could you please try re ordering the list of post functions so that it is as shown below and see if it makes a difference.

  1. File will be created from the template <template name> in the PDF format and it will be attached to the issue
  2. Script workflow function:  Send an email based on the provided template if conditions are met., with subject:  <subject line>
  3. Set issue status to the linked status of the destination workflow step
  4. Add a comment to the issue if one is entered during transition
  5. Update change history for an issue and store the issue in the database
  6. Reindex an issue to keep indexes in sync with the database
  7. Fire a generic event that can be processed by the listeners

Thanks

Kristian

jordan December 3, 2020

Hi Liesa and Kristian.

I'm running into the identical problem as what's posted here. This post is four years old and the screenshots aren't showing up. How was this solved?

 

Thanks,
Jordan

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events