#569 closed enhancement (fixed)
Sample list export for missing consent data
Reported by: | olle | Owned by: | olle |
---|---|---|---|
Priority: | major | Milestone: | Reggie v2.15 |
Component: | net.sf.basedb.reggie | Keywords: | |
Cc: |
Description
It should be possible to export a sample list for missing consent data. A new entry "Export missing consent data sample list" should be added under Reggie section "Export/import information to/from external registers". Like other export pages, it should contain a "Preview" and a "Download" button. Clicking the "Export" button should create a sample list, that can be downloaded or opened by a viewer program. Initially no extra parameters are defined.
The export list should have the following properties:
- The list should consist of tab-separated columns.
- The export list should include all samples of sample types
Case
andBlood
, that misses a consent, or where the consent date is missing. - The export list should include the following columns:
a. Sample name
b. Subtype
c. Personal number
d. All first names
e. Family name
f. Consent date
g. Consent ('Yes', 'No', 'Not asked', ornull
if missing)
- The preview should report the total number of samples with missing consent data, the number with missing consent date (total + number of 'Yes', 'No', and 'Not asked'), and the number of samples with missing consents.
Change History (10)
comment:1 by , 11 years ago
Status: | new → assigned |
---|
comment:2 by , 11 years ago
Traceability note:
- The consent count report was introduced in Ticket #426 (Consent count report generator).
- The monthly operation list export was introduced in Ticket #385 (Export information needed by the tumor registry).
- INCA export was introduced in Ticket #487 (Export information intended for INCA).
- Sample list export for missing sample data was introduced in Ticket #565 (Missing sample data report should support sample list export).
comment:3 by , 11 years ago
(In [2212]) Refs #569. First version of sample list export for missing consent data added:
- JSP script
index.jsp
inreggie/resources/
updated with new entry "Export missing consent data sample list" under Reggie section "Export/import information to/from external registers", with link to new JSP scriptexport_missing_consent_data_sample_list.jsp
inreggie/resources/personal/
. - New JSP script
export_missing_consent_data_sample_list.jsp
inreggie/resources/personal/
added. It is based on JSP scriptexport_inca.jsp
, but has initially no options. It calls java servletExportServlet.java
with commandExportMissingConsentDataSampleList
and the selected menu option. - Java servlet
ExportServlet.java
inreggie/src/net/sf/basedb/reggie/servlet/
updated:
a. Protected methodvoid doGet(HttpServletRequest req, HttpServletResponse resp)
updated for command "ExportMissingConsentDataSampleList
" to call new private methodSet<MissingConsentDataExportData> createMissingConsentDataExport(DbControl dc)
to create a missing consent data sample list for export.
b. New private methodSet<MissingConsentDataExportData> createMissingConsentDataExport(DbControl dc)
calls new private methodList<Sample> createSampleListForMissingConsentDataReport(DbControl dc)
to obtain a list of samples. This list is processed to obtain a list, that only contains samples with missing consent data. The missing consent data sample list is used to create a list ofMissingConsentDataExportData
objects, that will be returned.
c. New private methodList<Sample> createSampleListForMissingConsentDataReport(DbControl dc)
performs a database query for samples of typeCASE
andBLOOD
, and creates a sample list for the missing consent data report. The list will both include samples with and without missing consent data, and has to be processed afterwards to obtain a list, that only contains samples with missing consent data.
d. New inner classMissingConsentDataExportData
added. Its public methodString toString()
will a return a tab-separated line with data for the missing consent data export list.
comment:4 by , 11 years ago
comment:5 by , 11 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Ticket closed since the requested functionality has been added.
comment:6 by , 11 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Ticket reopened to fix bug when obtaining personal data for Case
items.
comment:7 by , 11 years ago
Problem description:
- Because of a bug in private method
List<Sample> createSampleListForMissingConsentDataReport(DbControl dc)
in java servletExportServlet.java
inreggie/src/net/sf/basedb/reggie/servlet/
, patient items were never found forCase
items, and therefore no personal information was reported for the latter, even when it existed. The bug resulted from reuse of code from other methods, where samples of typeBlood
,Specimen
, andNo Specimen
were used, while for the missing consent data report only samples of typeBlood
andCase
are used, where the patient is the parent item.
comment:8 by , 11 years ago
(In [2219]) Refs #569. Bug fixed in sample list export for missing consent data, that prevented personal information to be reported for Case
items, even when the former existed:
- Java servlet
ExportServlet.java
inreggie/src/net/sf/basedb/reggie/servlet/
updated in private methodList<Sample> createSampleListForMissingConsentDataReport(DbControl dc)
by fix of bug preventing patient items to be found forCase
items, and therefore no personal information was reported for the latter, even when it existed. The bug resulted from reuse of code from other methods, where samples of typeBlood
,Specimen
, andNo Specimen
were used, while for the missing consent data report only samples of typeBlood
andCase
are used, where the patient is the parent item.
comment:9 by , 11 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
Ticket closed again since bug preventing personal data to be reported for Case
items has been fixed.
comment:10 by , 11 years ago
(In [2223]) Refs #574. Refs #565. Refs #569. Consent and missing sample data report wizards updated to support missing data sample list export for users with PatientCurator
role:
Java servlet SampleReportServlet
in reggie/src/net/sf/basedb/reggie/servlet/
update:
- Private method
JSONObject createConsentCountReport(DbControl dc, JSONObject json, Date startDate, Date endDate)
updated to check if the user does not have permission to read patient names, and transfer the result in the returned JSON object in variable with key "permissionDeniedForPatientName
". The same flag is already returned by private methodJSONObject createMissingSampleDataReport(DbControl dc, JSONObject json, Date startDate, Date endDate, String sampleType, String bloodSampleFilter)
.
JSP script samplereportgenerator.jsp
in reggie/resources/reports/
update:
- Function
goCreate()
updated with argumentexportOpt
:
a. If the value of argumentexportOpt
is "preview
" or "export
", the consent count and missing sample data report wizards directs the Ajax request to servletExportServlet.java
to obtain data for corresponding the missing data sample list.
b. If the value of argumentexportOpt
is "preview
", a preview is shown created by the one of the new functionscreateMissingConsentDataSampleListPreview(allLines, previewTitle, previewList)
orcreateMissingDataSampleListPreview(allLines, sampleTypes, previewTitle, previewList)
, that corresponds to the used report wizard.
c. If the value of argumentexportOpt
is "export
", the output from theExport
servlet request is redirected to be downloaded or opened with a program of the user's choice. - Function
goCreate(exportOpt)
updated for the consent and missing sample data reports to check if the user has permission to read patient names, and if so, add two new buttons to the right of the "Restart
" button at the end, "Export preview
" and "Export
", coupled to calling functiongoCreate(exportOpt)
with argumentexportOpt
having values "preview
" and "export
", respectively. - New function
createMissingConsentDataSampleListPreview(allLines, previewTitle, previewList)
added. It creates a sample list preview like the one created by JSP scriptexport_missing_consent_data_sample_list.jsp
inreggie/resources/personal/
, as described in Ticket #569 (Sample list export for missing consent data). - New function
createMissingDataSampleListPreview(allLines, sampleTypes, previewTitle, previewList)
added. It creates a sample list preview like the one created by JSP scriptexport_missing_data_sample_list.jsp
inreggie/resources/personal/
, as described in Ticket #565 (Missing sample data report should support sample list export). - HTML part updated with new
style
section for the sample list preview, button definitions for the "Export preview
" and "Export
" buttons, and newdiv
tags for the optional export preview.
Ticket accepted.