Opened 10 years ago
Closed 10 years ago
#723 closed task (fixed)
Retraction wizard - Step 2: Follow up
Reported by: | olle | Owned by: | olle |
---|---|---|---|
Priority: | major | Milestone: | Reggie v3.0 |
Component: | net.sf.basedb.reggie | Keywords: | |
Cc: |
Description
The first step of the retraction wizard was concerned with marking extracts for retraction, and to produce lists and protocols to simplify finding these in the lab or external storage. The second step will be focused on the follow-up of step 1, where a web form will be presented for a selected retraction object, allowing dates to be entered when different sub-steps are finished. When all sub-steps are marked to have been finished, the items should be marked to be ready for deletion/destruction.
Change History (12)
comment:1 by , 10 years ago
Status: | new → assigned |
---|
comment:2 by , 10 years ago
Traceability note:
- The retraction wizard was introduced in Ticket #526 (Retraction wizard).
comment:3 by , 10 years ago
Background:
The full retraction module is intended to contain 3 parts:
1. Mark extracts for retraction. (Ticket #526)
2. Retraction follow-up (this ticket)
3. Destruction (to be defined later)
Functional specification for the retraction follow-up step:
- A case name or personal number should be input:
a. If a case name is input, the patient related to that case should be found. When step 1 is finished, the patient type is changed to "Retracted
" or "RetroNo
".
b. Step 2 is not intended to be used until step is finished, so it is natural to include a check that the patient type is correct for retraction. - a. A form with input fields for seven dates should be presented for the patient in question (regarding requests forwarded to other projects, it is implied that the projects use samples or data stored using the SCAN-B consent):
Header | Date sent prompt | Date received prompt | Comment |
Laboratory | Date sent | Date received | Dates when retraction request sent to and received from laboratory (YYYYMMDD) |
Blood samples | Date sent | Date received | Dates when retraction request sent and received for blood samples (YYYYMMDD) |
Frozen samples | Date sent | Date received | Dates when retraction request sent and received for frozen samples (YYYYMMDD) |
Forwarded | Date sent | Date when retraction request forwarded to other projects (YYYYMMDD) |
b. The date fields should be loaded with previously stored dates for the patient, if any.
c. A "Cancel
" and a "Register
" button should appear below the form. When the "Register
" button is clicked, the data in the date fields should be stored in annotations for the patient.
comment:4 by , 10 years ago
Design specification for the retraction follow-up step:
- JSP file
index.jsp
inresources/
is updated with new entry "Retraction follow-up
" under header "Retraction wizard
" in section "Personal information wizards
". The entry has a link to new JSP fileretraction_followup_form.jsp
inresources/personal/
and a new data-counter "patientitems-ready-for-retraction-followup
". In addition, a new inactive entry "Destruction
" is also added, with a data-counter "patientitems-ready-for-destruction
". - JSP file
retraction_followup_form.jsp
inresources/personal/
is coupled to Javascript fileretraction_followup_form.js
, also inresources/personal/
.
a. The JSP file has an input field for entering a case name or personal number. After initial validation of the case name/personal number, functionrf.caseNameOnChange()
calls servletRetractionFollowUpFormServlet
with command "GetCaseInfo
" to obtain a JSONObject with information on all cases for the patient in question, that is processed by functionrf.onCaseInfoLoaded(response)
, to determine if the patient biosource type is correct ("Retract
" or "RetroNo
" are allowed for the follow-up step).
c. Functionrf.initializeStep2()
then calls servletRetractionFollowUpFormServlet
with command "GetCaseInfo
" a second time, where the response is processed by functionrf.caseInfoLoaded(response)
, which fills retract data retrieved from the database into input fields in the form. The second step of the form contains input fields for seven retraction request and response dates for the patient in question.
d. The date fields are coupled to validation checks by functionsrf.labDateOnChange()
,rf.bloodDateOnChange()
,rf.frozenDateOnChange()
, andrf.forwardedDateOnChange()
.
e. Button "Register" is coupled to functionrf.submit()
, that sends the retract request and response date values in the form together with the input case name/personal number to servletRetractionFollowUpFormServlet
with command "RegisterRetraction
". - New java servlet class/file
RetractionFollowUpFormServlet.java
insrc/net/sf/basedb/reggie/servlet/
acceptsGET
requests for command "GetCaseInfo
", andPOST
request for command "RegisterRetraction
". It accesses the database to retrieve the requested information, or update the contents, and sends the results back in JSON format. The functionality for command "GetCaseInfo
" is basically identical to that of servletRetractionFormServlet
, while command "RegisterRetraction
" stores date values from the form in new annotations for patient items of biosource type "Retract
" or "RetroNo
". If all seven dates are set, new enumerable string annotation "RetractStatus
" is set to value "ReadyForDestruction
" (default value isnull
). - XML servlet configuration file
servlets.xml
inMETA-INF/
updated with entry for new servletRetractionFollowUpFormServlet
. - Java class/file
Annotationtype.java
insrc/net/sf/basedb/reggie/dao/
updated with seven new retract date annotations:
RETRACT_REQUEST_SENT_TO_LABORATORY_DATE
RETRACT_RESPONSE_RECEIVED_FROM_LABORATORY_DATE
RETRACT_REQUEST_SENT_FOR_BLOOD_SAMPLES_DATE
RETRACT_RESPONSE_RECEIVED_FOR_BLOOD_SAMPLES_DATE
RETRACT_REQUEST_SENT_FOR_FROZEN_SAMPLES_DATE
RETRACT_RESPONSE_RECEIVED_FOR_FROZEN_SAMPLES_DATE
RETRACT_REQUEST_FORWARDED_TO_RELATED_PROJECTS_DATE
In addition, a new enumerable string annotationRETRACT_STATUS
is defined with two options "ReadyForDestruction
" and "RetractionCompleted
". - Java class/file
InstallServlet.java
insrc/net/sf/basedb/reggie/servlet/
updated inprotected
methodvoid doGet(HttpServletRequest req, HttpServletResponse resp)
to create the new annotation type items, if not existing. - Java class/file
CounterService.java
insrc/net/sf/basedb/reggie/counter/
updated:
a. Methodvoid count()
updated to call new private methodsvoid CountPatientsReadyForRetractionFollowUp(DbControl dc, JSONObject json)
andvoid CountPatientsReadyForDestruction(DbControl dc, JSONObject json)
.
b. New private methodvoid CountPatientsReadyForRetractionFollowUp(DbControl dc, JSONObject json)
added. It counts the number of biosource items of type "Retract
" or "RetroNo
" with annotationRETRACT_STATUS
set tonull
.
c. New private methodvoid CountPatientsReadyForDestruction(DbControl dc, JSONObject json)
added. It counts the number of biosource items of type "Retract
" or "RetroNo
" with annotationRETRACT_STATUS
set to "ReadyForDestruction
".
comment:5 by , 10 years ago
(In [3085]) Refs #723. First version of second step of the retraction wizard, which is a follow-up of the first step, that marked samples and extracts for destruction, given a biosource item selected for retraction. The follow-up step keeps track of dates when different types of retraction requests are sent to and responses are received from secondary storage facilities (laboratory, blood, frozen samples, and related projects using the same consent):
- JSP file
index.jsp
inresources/
is updated with new entry "Retraction follow-up
" under header "Retraction wizard
" in section "Personal information wizards
". The entry has a link to new JSP fileretraction_followup_form.jsp
inresources/personal/
and a new data-counter "patientitems-ready-for-retraction-followup
". In addition, a new inactive entry "Destruction
" is also added, with a data-counter "patientitems-ready-for-destruction
". - JSP file
retraction_followup_form.jsp
inresources/personal/
is coupled to Javascript fileretraction_followup_form.js
, also inresources/personal/
.
a. The JSP file has an input field for entering a case name or personal number. After initial validation of the case name/personal number, functionrf.caseNameOnChange()
calls servletRetractionFollowUpFormServlet
with command "GetCaseInfo
" to obtain a JSONObject with information on all cases for the patient in question, that is processed by functionrf.onCaseInfoLoaded(response)
, to determine if the patient biosource type is correct ("Retract
" or "RetroNo
" are allowed for the follow-up step).
c. Functionrf.initializeStep2()
then calls servletRetractionFollowUpFormServlet
with command "GetCaseInfo
" a second time, where the response is processed by functionrf.caseInfoLoaded(response)
, which fills retract data retrieved from the database into input fields in the form. The second step of the form contains input fields for seven retraction request and response dates for the patient in question.
d. The date fields are coupled to validation checks by functionsrf.labDateOnChange()
,rf.bloodDateOnChange()
,rf.frozenDateOnChange()
, andrf.forwardedDateOnChange()
.
e. Button "Register" is coupled to functionrf.submit()
, that sends the retract request and response date values in the form together with the input case name/personal number to servletRetractionFollowUpFormServlet
with command "RegisterRetraction
". - New java servlet class/file
RetractionFollowUpFormServlet.java
insrc/net/sf/basedb/reggie/servlet/
acceptsGET
requests for command "GetCaseInfo
", andPOST
request for command "RegisterRetraction
". It accesses the database to retrieve the requested information, or update the contents, and sends the results back in JSON format. The functionality for command "GetCaseInfo
" is basically identical to that of servletRetractionFormServlet
, while command "RegisterRetraction
" stores date values from the form in new annotations for patient items of biosource type "Retract
" or "RetroNo
". If all seven dates are set, new enumerable string annotation "RetractStatus
" is set to value "ReadyForDestruction
" (default value isnull
). - XML servlet configuration file
servlets.xml
inMETA-INF/
updated with entry for new servletRetractionFollowUpFormServlet
. - Java class/file
Annotationtype.java
insrc/net/sf/basedb/reggie/dao/
updated with seven new retract date annotations:
RETRACT_REQUEST_SENT_TO_LABORATORY_DATE
RETRACT_RESPONSE_RECEIVED_FROM_LABORATORY_DATE
RETRACT_REQUEST_SENT_FOR_BLOOD_SAMPLES_DATE
RETRACT_RESPONSE_RECEIVED_FOR_BLOOD_SAMPLES_DATE
RETRACT_REQUEST_SENT_FOR_FROZEN_SAMPLES_DATE
RETRACT_RESPONSE_RECEIVED_FOR_FROZEN_SAMPLES_DATE
RETRACT_REQUEST_FORWARDED_TO_RELATED_PROJECTS_DATE
In addition, a new enumerable string annotationRETRACT_STATUS
is defined with two options "ReadyForDestruction
" and "RetractionCompleted
". - Java class/file
InstallServlet.java
insrc/net/sf/basedb/reggie/servlet/
updated inprotected
methodvoid doGet(HttpServletRequest req, HttpServletResponse resp)
to create the new annotation type items, if not existing. - Java class/file
CounterService.java
insrc/net/sf/basedb/reggie/counter/
updated:
a. Methodvoid count()
updated to call new private methodsvoid CountPatientsReadyForRetractionFollowUp(DbControl dc, JSONObject json)
andvoid CountPatientsReadyForDestruction(DbControl dc, JSONObject json)
.
b. New private methodvoid CountPatientsReadyForRetractionFollowUp(DbControl dc, JSONObject json)
added. It counts the number of biosource items of type "Retract
" or "RetroNo
" with annotationRETRACT_STATUS
set tonull
.
c. New private methodvoid CountPatientsReadyForDestruction(DbControl dc, JSONObject json)
added. It counts the number of biosource items of type "Retract
" or "RetroNo
" with annotationRETRACT_STATUS
set to "ReadyForDestruction
".
comment:6 by , 10 years ago
(In [3086]) Refs #723. Retraction follow-up wizard updated to use own CSS file, in order to make "Next"-button in step 1 have same vertical placement as in other wizards:
- New CSS file
retractionfollowupform.css
inresources/css/
added. It is identical toretractionform.css
, except that it lacks entry "#wizard-status
". - JSP file
retraction_followup_form.jsp
inresources/personal/
updated by exchanging CSS fileretractionform.css
forretractionfollowupform.css
.
comment:7 by , 10 years ago
(In [3087]) Refs #723. Retraction follow-up wizard updated by removal of CSS file retractionfollowupform.css
in resources/css/
, since it is currently not necessary:
- CSS file
retractionfollowupform.css
inresources/css/
removed, since its functionality is currently not used. - JSP file
retraction_followup_form.jsp
inresources/personal/
updated by removing reference to CSS fileretractionfollowupform.css
.
comment:8 by , 10 years ago
(In [3088]) Refs #723. Retraction follow-up wizard updated to disable step 1 part of form, when action has continued to step 2 (the case name input field is already disabled). This is normally handled by Wizard
functionality, but the call structure of the follow-up wizard is complicated by the necessity of making a database query to check the biosource type of the patient item, before continuing to step 2:
- Javascript file
retraction_followup_form.js
inresources/personal/
updated in functionrf.caseInfoLoaded(response)
by adding command "Doc.addClass('step-1', 'disabled');
" after "Wizard.setCurrentStep(2);
".
If a way is found to disable step 1 using Wizard
functionality, while retaining the ability to check the patient biosource type before continuing, this would be a preferred solution.
comment:9 by , 10 years ago
(In [3089]) Refs #723. Retraction follow-up wizard updated to disable step 1 part of form, after action has continued to step 2, using Wizard
functionality (thanks to Nicklas Nordborg for pointing out the solution):
- Javascript file
retraction_followup_form.js
inresources/personal/
updated:
a. Functionrf.onCaseInfoLoaded(response)
updated by adding command "Wizard.goNext(true);
" at the end of code section for valid patient data input. Code has been cleaned up by removal of a number of unnecessary commands. - Javascript file
retraction_followup_form.js
inresources/personal/
updated in functionrf.caseInfoLoaded(response)
by removal of command "Doc.addClass('step-1', 'disabled');
" after "Wizard.setCurrentStep(2);
", since this is now no longer needed.
comment:10 by , 10 years ago
(In [3090]) Refs #723. Retraction follow-up wizard updated by using Javascript string function indexOf(searchstring)
to check if a string starts with a special sub-string (the function equals 0
in this case, since this is the index position of the start of the sub-string in the string of interest). This makes definition of a new string function startsWith(searchstring)
unnecessary:
- Javascript file
retraction_followup_form.js
inresources/personal/
updated:
a. Functionrf.onCaseInfoLoaded(response)
updated by using Javascript string functionindexOf(searchstring)
to check if a string starts with a special sub-string.
b. Functionrf.caseInfoLoaded(response)
updated by using Javascript string functionindexOf(searchstring)
to check if a string starts with a special sub-string.
comment:11 by , 10 years ago
(In [3091]) Refs #723. Retraction follow-up wizard updated by using shorter names of retract date annotations, since these are visible in some parts of the GUI, and shorter names increase clarity. The shortened names are created according to a simple logical scheme, in order to make the meaning clear, although the name is short ("Tx" = "Transmit", "Rx" = "Receive", "BB" = "BioBank", a swedish storage facility for biological samples, including blood samples):
- Java class/file
Annotationtype.java
insrc/net/sf/basedb/reggie/dao/
updated with shorter names for seven retract date annotations. - Java class/file
InstallServlet.java
insrc/net/sf/basedb/reggie/servlet/
updated in protected methodvoid doGet(HttpServletRequest req, HttpServletResponse resp)
to create the new annotation type items, if not existing. - Java class/file
RetractionFollowUpFormServlet.java
insrc/net/sf/basedb/reggie/servlet/
updated in private methodvoid loadPatientInfo(DbControl dc, Patient patient)
and protected methodvoid doPost(HttpServletRequest req, HttpServletResponse resp)
to use the new shorter names of retract date annotations.
comment:12 by , 10 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Ticket accepted.