systopia / de.systopia.donrec

CiviCRM Donation Receipts Extension
GNU Affero General Public License v3.0
15 stars 26 forks source link

Do not overwrite the issued_on field when copying a donation receipt #170

Closed MarcMichalsky closed 1 year ago

MarcMichalsky commented 1 year ago

As discussed here, the issued_on field should not be overwritten when copying a donation receipt. This ensures that a copy bears the correct and original date of its issuance.

Apart from preserving the original issued_on date this PR also adjusts the default template to use the $issued_on variable instead of $today. Otherwise the change wouldn't have any effect.

[!IMPORTANT] If you are using a custom donation receipt template, you will need to make the above adjustments yourself! You can edit your templates within the Donation Receipts Profiles (Administer -> Administration Console -> Donation Receipts Profiles -> edit). Find all $today variables and simply replace them with $issued_on.

fix #169

jensschuppe commented 1 year ago

@bjendres I'm not sure whether this should go into a 2.2 point release or a new 2.3 minor one. Would this silently introduce a change for people only using the default template (which might be very few, but still ...)?

MarcMichalsky commented 1 year ago

Here's my two cents: people should know that they need to read the release notes before upgrading.

bjendres commented 1 year ago

Here's my two cents: people should know that they need to read the release notes before upgrading.

Yes....but they don't :)

jensschuppe commented 1 year ago

Would this silently introduce a change for people only using the default template (which might be very few, but still ...)?

This is actually not a problem as Donation Receipts profiles don't use "real" message templates anymore, so an update to the default template will not affect existing profiles.