From 2dd89c310f104f7120d0e737fcac84627b042eff Mon Sep 17 00:00:00 2001 From: Alex Cabal Date: Mon, 15 May 2023 12:36:02 -0500 Subject: [PATCH] Add unprocessed pending payments watchdog --- scripts/pending-payments-watchdog | 22 +++++++++++++++++++ templates/EmailAdminUnprocessedDonations.php | 9 ++++++++ .../EmailAdminUnprocessedDonationsText.php | 1 + 3 files changed, 32 insertions(+) create mode 100644 scripts/pending-payments-watchdog create mode 100644 templates/EmailAdminUnprocessedDonations.php create mode 100644 templates/EmailAdminUnprocessedDonationsText.php diff --git a/scripts/pending-payments-watchdog b/scripts/pending-payments-watchdog new file mode 100644 index 00000000..600d46da --- /dev/null +++ b/scripts/pending-payments-watchdog @@ -0,0 +1,22 @@ +#!/usr/bin/php + 0){ + $em = new Email(); + $em->To = ADMIN_EMAIL_ADDRESS; + $em->From = ADMIN_EMAIL_ADDRESS; + $em->Subject = 'Unprocessed payment in database'; + $em->Body = Template::EmailAdminUnprocessedDonations(); + $em->TextBody = Template::EmailAdminUnprocessedDonationsText(); + $em->Send(); +} + +?> diff --git a/templates/EmailAdminUnprocessedDonations.php b/templates/EmailAdminUnprocessedDonations.php new file mode 100644 index 00000000..82607821 --- /dev/null +++ b/templates/EmailAdminUnprocessedDonations.php @@ -0,0 +1,9 @@ + + + + Unprocessed donations in database + + +

There are unprocessed donations in the database.

+ + diff --git a/templates/EmailAdminUnprocessedDonationsText.php b/templates/EmailAdminUnprocessedDonationsText.php new file mode 100644 index 00000000..0ae7399f --- /dev/null +++ b/templates/EmailAdminUnprocessedDonationsText.php @@ -0,0 +1 @@ +There are unprocessed donations in the database.