redcap-em-report-filters
A REDCap External module that adds in-table filters to columns specified in the Edit Report page.
Science Score: 31.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (10.6%) to scientific vocabulary
Keywords
Repository
A REDCap External module that adds in-table filters to columns specified in the Edit Report page.
Basic Info
Statistics
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
- Releases: 7
Topics
Metadata Files
README.md
Report Filters - Redcap External Module
More complete end-user facing documentation can be found here
What does it do?
Report Filter adds the ability to add in-table, dropdown filters for select specific report fields. When enabled in a project, a "Add Filter" column is added to the "Fields to include in report" table. The selection of checkboxes in this column specify the report fields that will have an in-table dropdown filter.

The filters are added in a second row in the table header, and perform exact matches within the column.



Any field type can be utilized for this feature, including free text. For instance, in this example, the free text field "First Name" is utilized. Note, with "Alex" being selected, the name "Alexandra" is not displayed as it is not an exact match.

Features
Sendable URLs
The module supports sendable URLs, allowing for the sharing of filtered reports. When a filter is applied, the URL is updated to include the filter. This allows for the sharing of the filtered report.

Downloadable CSV
The module supports the downloading of the filtered report as a CSV. When a filter is applied, the CSV download will include the filtered data. If the report includes both labels and raw data for the header or data rows, options will be given to download the CSV with either the labels, raw data, or both.
The download pop-up should also include any citation information that is displayed in canonical REDCap report downloads.

Live Filter Compatibility
The module is compatible with the Live Filter module. When a live filter is applied, the in-table filters will remain.
Multipage Compatibility
The module works when a report is split into multiple pages. The filters will remain when navigating between pages or selecting "All.
Report Tweaks Compatibility
This module works with the popular Report Tweaks module.
Installing
You can install the module from the REDCap EM repo or drop it directly in your modules folder (i.e. redcap/modules/report_filters_v1.0.0).
Owner
- Name: cchmc
- Login: cchmc
- Kind: organization
- Repositories: 1
- Profile: https://github.com/cchmc
Citation (citation.php)
<?php
namespace JFortriede\ReportFilters;
use ExternalModules\AbstractExternalModule;
use REDCap;
use RCView;
// Display the project header
// require_once APP_PATH_DOCROOT . 'ProjectGeneral/header.php';
global $Proj;
global $lang;
## NOTICES FOR CITATIONS (GRANT AND/OR SHARED LIBRARY) AND DATE-SHIFT NOTICE
$citationText = "";
$Proj = new \Project($project_id);
// Do not display grant statement unless $grant_cite has been set for this project.
if ($GLOBALS['grant_cite'] != "") {
$citationText .= RCView::li(['class'=>'mb-2'],
"{$lang['data_export_tool_297']} <b>{$GLOBALS['grant_cite']}</b>{$lang['period']}"
);
}
// REDCap 2009 publication citation
$citationText .= RCView::li(['class'=>'mb-2'],
$lang['data_export_tool_298'] . " <a href='https://redcap.vanderbilt.edu/consortium/cite.php' target='_blank' style='text-decoration:underline;'>{$lang['data_export_tool_301']}</a>"
);
// Shared Library citation: If instruments have been downloaded from the Shared Library
if ($Proj->formsFromLibrary()) {
$dlg1 = "<code style='font-size:15px;color:#333;'>
Jihad S. Obeid, Catherine A. McGraw, Brenda L. Minor, José G. Conde, Robert Pawluk, Michael Lin, Janey Wang, Sean R. Banks, Sheree A. Hemphill, Rob Taylor, Paul A. Harris,
"<b>Procurement of shared data instruments for Research Electronic Data Capture (REDCap)</b>",
Journal of Biomedical Informatics,
Volume 46, Issue 2,
2013,
Pages 259-265,
ISSN 1532-0464.
<a target='_blank' style='text-decoration:underline;font-size:15px;' href='https://doi.org/10.1016/j.jbi.2012.10.006'>https://doi.org/10.1016/j.jbi.2012.10.006</a></code>";
$citationText .= RCView::li(['class'=>'mb-2'],
"{$lang['data_export_tool_300']} <a href='javascript:;' style='text-decoration:underline;' onclick=\"simpleDialog('".js_escape($dlg1)."','".RCView::tt_js('data_export_tool_302')."',null,650);\">{$lang['data_export_tool_303']}</a>"
);
}
// CDIS citation
if ($GLOBALS['realtime_webservice_type'] == 'FHIR' || $GLOBALS['datamart_enabled'] == '1') {
$dlg1 = "<code style='font-size:15px;color:#333;'>
A.C. Cheng, S.N. Duda, R. Taylor, F. Delacqua, A.A. Lewis, T. Bosler, K.B. Johnson, P.A. Harris,
"<b>REDCap on FHIR: Clinical Data Interoperability Services</b>",
Journal of Biomedical Informatics,
Volume 121,
2021,
103871,
ISSN 1532-0464.
<a target='_blank' style='text-decoration:underline;font-size:15px;' href='https://doi.org/10.1016/j.jbi.2021.103871'>https://doi.org/10.1016/j.jbi.2021.103871</a></code>";
$citationText .= RCView::li(['class'=>'mb-2'],
"{$lang['data_export_tool_304']} <a href='javascript:;' style='text-decoration:underline;' onclick=\"simpleDialog('".js_escape($dlg1)."','".RCView::tt_js('data_export_tool_302')."',null,650);\">{$lang['data_export_tool_303']}</a>"
);
}
// Not tested...
// REDCap Mobile App citation
$sql = "select 1 from redcap_mobile_app_log where event = 'INIT_PROJECT' and project_id = $project_id limit 1";
if (db_num_rows(db_query($sql))) {
$dlg1 = "<code style='font-size:15px;color:#333;'>
Paul A Harris, Giovanni Delacqua, Robert Taylor, Scott Pearson, Michelle Fernandez, Stephany N Duda,
"<b>The REDCap Mobile Application: a data collection platform for research in regions or situations with internet scarcity</b>",
JAMIA Open, Volume 4, Issue 3, July 2021, ooab078.
<a target='_blank' style='text-decoration:underline;font-size:15px;' href='https://doi.org/10.1093/jamiaopen/ooab078'>https://doi.org/10.1093/jamiaopen/ooab078</a></code>";
$citationText .= RCView::li(['class'=>'mb-2'],
"{$lang['data_export_tool_305']} <a href='javascript:;' style='text-decoration:underline;' onclick=\"simpleDialog('".js_escape($dlg1)."','".RCView::tt_js('data_export_tool_302')."',null,650);\">{$lang['data_export_tool_303']}</a>"
);
}
// Not tested... OLD citation
// MyCap citation
$sql = "SELECT 1 FROM redcap_external_modules e, redcap_external_module_settings s
WHERE e.directory_prefix = 'mycap' AND e.external_module_id = s.external_module_id and s.`key` = 'enabled'
and s.`value` = 'true' and s.project_id = $project_id limit 1";
$mycapModuleEnabled = (db_num_rows(db_query($sql)));
if ($mycapModuleEnabled || (isset($GLOBALS['mycap_enabled']) && $GLOBALS['mycap_enabled'] == '1')) {
$dlg1 = "<code style='font-size:15px;color:#333;'>
Paul A Harris, Jonathan Swafford, Emily S Serdoz, Jessica Eidenmuller, Giovanni Delacqua, Vaishali Jagtap, Robert J Taylor, Alexander Gelbard, Alex C Cheng, Stephany N Duda,
"<b>MyCap: a flexible and configurable platform for mobilizing the participant voice</b>",
JAMIA Open, Volume 5, Issue 2, July 2022, ooac047.
<a target='_blank' style='text-decoration:underline;font-size:15px;' href='https://doi.org/10.1093/jamiaopen/ooac047'>https://doi.org/10.1093/jamiaopen/ooac047</a></code>";
$citationText .= RCView::li(['class'=>'mb-2'],
"{$lang['data_export_tool_306']} <a href='javascript:;' style='text-decoration:underline;' onclick=\"simpleDialog('".js_escape($dlg1)."','".RCView::tt_js('data_export_tool_302')."',null,650);\">{$lang['data_export_tool_303']}</a>"
);
}
// E-Consent citation
$sql = "select 1 from redcap_surveys s where s.pdf_auto_archive = 2 and s.project_id = $project_id limit 1";
$econsentEnabled = db_num_rows(db_query($sql));
if ($econsentEnabled) {
$dlg1 = "<code style='font-size:15px;color:#333;'>
Lawrence CE, Dunkel L, McEver M, Israel T, Taylor R, Chiriboga G, Goins KV, Rahn EJ, Mudano AS, Roberson ED, Chambless C, Wadley VG, Danila MI, Fischer MA, Joosten Y, Saag KG, Allison JJ, Lemon SC, Harris PA,
"<b>A REDCap-based model for electronic consent (eConsent): Moving toward a more personalized consent</b>",
J Clin Transl Sci. 2020 Apr 3;4(4):345-353.
<a target='_blank' style='text-decoration:underline;font-size:15px;' href='https://doi.org/10.1017/cts.2020.30'>https://doi.org/10.1017/cts.2020.30</a></code>";
$citationText .= RCView::li(['class'=>'mb-2'],
"{$lang['data_export_tool_307']} <a href='javascript:;' style='text-decoration:underline;' onclick=\"simpleDialog('".js_escape($dlg1)."','".RCView::tt_js('data_export_tool_302')."',null,650);\">{$lang['data_export_tool_303']}</a>"
);
}
// Wrap all citations in an ordered list
$citationText = RCView::fieldset(array('style'=>'margin-top:10px;padding-left:8px;background-color:#FFFFD3;border:1px solid #FFC869;color:#B00000;'),
RCView::legend(array('class'=>'font-weight-bold fs14'),
'<i class="fa-solid fa-book"></i> '.$lang['data_export_tool_295'] . ($GLOBALS['grant_cite'] != "" ? " ".$lang['data_export_tool_296'] : "")
) .
RCView::div(array('class'=>'p-1 mt-1'),
$lang['data_export_tool_299']
) .
RCView::ol(array('class'=>'ms-3 ps-1 pe-3 pt-2 pb-0'),
$citationText
)
);
echo $citationText;
?>
GitHub Events
Total
- Create event: 4
- Release event: 2
- Issues event: 4
- Delete event: 1
- Issue comment event: 2
- Push event: 7
- Pull request event: 8
Last Year
- Create event: 4
- Release event: 2
- Issues event: 4
- Delete event: 1
- Issue comment event: 2
- Push event: 7
- Pull request event: 8
Issues and Pull Requests
Last synced: 6 months ago
All Time
- Total issues: 2
- Total pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Total issue authors: 1
- Total pull request authors: 0
- Average comments per issue: 0.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 2
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 1
- Pull request authors: 0
- Average comments per issue: 0.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- JoshuaFortriede (3)
- ThomasVermes (1)
Pull Request Authors
- JoshuaFortriede (15)