Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Merged
merged 2 commits into from
Sep 4, 2023

Conversation

MarcMichalsky
Copy link
Contributor

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

The issued_by field is not overwritten when copying a donation receipt
@jensschuppe jensschuppe added enhancement status:needs review Code needs review and testing. labels Sep 1, 2023
@jensschuppe
Copy link
Collaborator

@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
Copy link
Contributor Author

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

Copy link
Member

@bjendres bjendres left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good (and simple enough) to me.

@jensschuppe, would have another look?

@bjendres
Copy link
Member

bjendres commented Sep 2, 2023

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

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

@jensschuppe
Copy link
Collaborator

jensschuppe commented Sep 4, 2023

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.

@jensschuppe jensschuppe added status:reviewed and tested Code has received thorough review and testing and is ready to be committed/merged. and removed status:needs review Code needs review and testing. labels Sep 4, 2023
@jensschuppe jensschuppe added this to the 2.2 milestone Sep 4, 2023
@jensschuppe jensschuppe merged commit 92e1051 into systopia:master Sep 4, 2023
@jensschuppe jensschuppe added status:fixed The issue has been resolved (usually by committing/merging code). and removed status:reviewed and tested Code has received thorough review and testing and is ready to be committed/merged. labels Sep 4, 2023
@MarcMichalsky MarcMichalsky deleted the issue/169 branch September 4, 2023 10:31
jensschuppe added a commit that referenced this pull request Nov 6, 2024
The issued_by field is not overwritten when copying a donation receipt

Use $issued_on instead of $today to print the original document date.
@jensschuppe
Copy link
Collaborator

Just noticed that this was only merged into master for 2.3. Cherry-picked it into the release/2.2.x branch just now, as was intended.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement status:fixed The issue has been resolved (usually by committing/merging code).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Copy donation receipts inconsistent?
3 participants