Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-19710

Preserve is_email_receipt parameter through to email sent

    Details

    • Type: Improvement
    • Status: Reopened
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 4.6, 4.7
    • Fix Version/s: 4.7.18
    • Component/s: None
    • Labels:
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Contributed Code
    • Verified?:
      No

      Description

      Following from CRM-19601, the is_email_receipt parameter still gets overridden later down the chain again.

      For example, this scenario:

      1. Contribution page sets "Email Receipt to Contributor? = FALSE", so "is_email_receipt => 0"
      2. Contribution made at status Pending
      3. API call to completetransaction sets "is_email_receipt => 1" (i.e. send the receipt on completion regardless of Contribution page setting)
      4. completetransaction calls completeOrder(), which calls sendconfirmation API call - is_email_receipt isn't passed along
      5. sendconfirmation calls sendMail, which calls composeMessageArray()
      6. composeMessageArray() gets settings by "$this->_gatherMessageValues($input, $values, $ids)", which has "is_email_receipt => 0" (the setting provided by the Contribution page)
      7. No email is sent, the override was ignored/lost

      For Events, is_email_receipt can be fed through completetransaction, but no confirmation email is sent even if "is_email_receipt => 1", because is_email_confirm isn't set at the same time.

      PRs built off CRM-19601 to fix these cases coming through.

      Agileware Ref #24374

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              agileware Agileware
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: