diff --git a/.env.development b/.env.development index 4fdb0cc..ac3067a 100644 --- a/.env.development +++ b/.env.development @@ -34,6 +34,7 @@ MEDIPOST_PASSWORD=SRB48HZMV MEDIPOST_RECIPIENT=trvurgtst MEDIPOST_MESSAGE_SENDER=trvurgtst MEDIPOST_ENABLE_DISPATCH_ON_MONTONIO_CALLBACK=true +MEDIPOST_ENABLE_DELETE_RESPONSE_PRIVATE_MESSAGE_ON_READ=false #MEDIPOST_URL=https://medipost2.medisoft.ee:8443/Medipost/MedipostServlet #MEDIPOST_USER=medreport diff --git a/lib/services/medipost/medipostPrivateMessage.service.ts b/lib/services/medipost/medipostPrivateMessage.service.ts index 57380a4..9027079 100644 --- a/lib/services/medipost/medipostPrivateMessage.service.ts +++ b/lib/services/medipost/medipostPrivateMessage.service.ts @@ -43,7 +43,7 @@ const USER = process.env.MEDIPOST_USER!; const PASSWORD = process.env.MEDIPOST_PASSWORD!; const RECIPIENT = process.env.MEDIPOST_RECIPIENT!; -const IS_ENABLED_DELETE_PRIVATE_MESSAGE = false as boolean; +const IS_ENABLED_DELETE_PRIVATE_MESSAGE = process.env.MEDIPOST_ENABLE_DELETE_RESPONSE_PRIVATE_MESSAGE_ON_READ === 'true'; export async function getLatestPrivateMessageListItem({ excludedMessageIds,