There was an issue reported in Angola, and it turned out that it's valid also in the Core project. The notification of near expiry doesn't have correct content anymore. Instead, it contains untranslated strings as subject and body of the email. Please look at the screenshot.
Add to test server's env file a new entry LOT_NEAR_EXPIRY_CRON with a cron expression of checking something like every minute (0 * * * * ?).
Redeploy that test server.
Log in as administrator and change its email address to something for which you can check email.
Go to the API Console for the test server (/referencedata/docs/).
Get an access token for the administrator.
Update a certain lot (PUT /api/lots/af804501-ef41-4367-9733-83b73e7c0a4b) with the following request body:
"expirationDate": "(6 months from today)",
In about a minute, you should get an email about near expiry.
The notification is sent, but with an incorrect subject and email body.
*Notification shows Product Name, lot information, date of expiry;
*When the user receives a notification, they can click on a link to view the bin card for the close to expiry product;
*Clicking on the second link takes them to an emergency requisition form pre-selected with the facility and program that has no stock;
*Email body text appears as follows:
– START –
Subject: CLOSE TO EXPIRY Attention Required: <Facility name>, <Product name>
This email is informing you that the product <Product Name> with lot number <Lot number> in <program name> at <facility name> will expire in 6 months. Its expiration date is <expiration date>.
Login to view the bin card for this product.
View bin card for <orderable name>: <URL to View BIN CARD>
– END –