maxramirez84 / redcap-email-notifications-module

REDCap External Module that allows project administrators to schedule email notifications (every minute, hourly, daily, weekly or monthly) to one or more recipients summarizing record creation through REDCap API, i.e. REDCap Mobile App.
https://www.project-redcap.org/
MIT License
0 stars 0 forks source link

Email Notification plugin does not send emails for some of my projects #4

Closed maxramirez84 closed 3 years ago

maxramirez84 commented 4 years ago

Describe the bug The Email Notification plugin sends emails only for the projects that are registering the events in the table redcap_log_event. However, when redcap splits this table in redcap_log_event2, redcap_log_event3, etc, and your project is registering its events in some of the redcap_log_eventN tables, the plugin doesn't notify.

To Reproduce Steps to reproduce the behavior:

  1. When your REDCap setup stores enough projects and events and it creates some redcap_log_eventN table, enable the EM in one of the projects who is registering in a table different than redcap_log_event, e.g. redcap_log_event2.
  2. Send one or more records form REDCap Mobile App
  3. Email notifications never arrive.

Expected behavior REDCap should send the notification independently on the table in which the project is registering the events.

Screenshots NA

Desktop (please complete the following information):

Smartphone (please complete the following information): NA

Additional context NA

maxramirez84 commented 3 years ago

This fixes the issue. Now, rather than selecting always from redcap_log_event tablet, we check in the redcap_projects table in which table this project is logging and select from the corresponding table.