Difference between revisions of "Documentation/Nightly/Modules/DatabaseInteractor"

From Slicer Wiki
Jump to: navigation, search
Line 10: Line 10:
 
Extension: '''Database Interactor'''<br>
 
Extension: '''Database Interactor'''<br>
 
Acknowledgments: This work was supported by the National Institues of Dental and Craniofacial Research and Biomedical Imaging and Bioengineering of the National Institutes of Health.<br>
 
Acknowledgments: This work was supported by the National Institues of Dental and Craniofacial Research and Biomedical Imaging and Bioengineering of the National Institutes of Health.<br>
Author: Clément Mirabel, (University of Michigan)<br>
+
Author: Clément Mirabel (University of Michigan)<br>
Contributor1: Juan Carlos Prieto, (UNC)<br>
+
Contributor1: Juan Carlos Prieto (UNC)<br>
 
Contributor2: Lucia Cevidanes (University of Michigan)<br>
 
Contributor2: Lucia Cevidanes (University of Michigan)<br>
 
Contact: Clément Mirabel, <email>clement.mirabel@gmail.com</email><br>
 
Contact: Clément Mirabel, <email>clement.mirabel@gmail.com</email><br>

Revision as of 18:22, 23 November 2016

Home < Documentation < Nightly < Modules < DatabaseInteractor


For the latest Slicer documentation, visit the read-the-docs.


Introduction and Acknowledgements

Extension: Database Interactor
Acknowledgments: This work was supported by the National Institues of Dental and Craniofacial Research and Biomedical Imaging and Bioengineering of the National Institutes of Health.
Author: Clément Mirabel (University of Michigan)
Contributor1: Juan Carlos Prieto (UNC)
Contributor2: Lucia Cevidanes (University of Michigan)
Contact: Clément Mirabel, <email>clement.mirabel@gmail.com</email>
License: Apache License, Version 2.0

Module Description

This extension contains multiple panels that allow the user to manage data from a web database. The data displayed in this extension dynamically reacts with user local folders and online database. The user should login with the same credentials than on the server entered as input.

Use Cases

Logo for Database Interactor
Interface of Database Interactor
Database Interactor in Slicer

Tutorials

Login to the database

LoginPanelDatabaseInteractor.png This tab allows the user to connect to a web database using the credentials registered in this database. The user can only access the web system if he has the correct permissions.

Download data using a patient Id

DownloadPanelOnlyId.png After connecting to the database, the user will have access to the file stored in the database and has 2 options:
  • Downloading an entire collection. This button will download the selected collection using the following architecture.
CollectionName
       |
       |-- .DBIDescriptor
       |
       |-- Patient1
       |        |
       |        |-- Date1
       |        |
       |        |        |-- .DBIDescriptor
       |        |        |
       |        |        |-- Attachment1(.vtk|.nrrd|...)
       |        |        .
       |        |        .
       |        .        .
       |        .        .
       .        .        .
       .        .        .
  • Downloading only one attachment. If the user has already downloaded the collection locally, the destination would be PathToTheCollection/CollectionName/PatienId/Date/. The user needs to select first a collection, then a patient Id and finally the wanted attachment in an attachment list generated by the collection and patient selected.

Download data using date and patient Id

To switch to this functionality, it only needs to tick the option "PatientId and date" in the download panel.

DownloadPanelDateAndIdWrongDate.png This panel is a bit different than the previous one as it allows the user to use a calendar to find a file date corresponding to the patient Id selected. The user first needs to select a collection, then a patient Id in this collection and the attachment dates corresponding to this patient Id will be displayed in blue and bold in the calendar.

It is still possible to download the entire collection in this panel.

DownloadPanelDateAndIdGoodDate.png When a date containing one or multiple attachments is selected, the user can now select in a list an attachment to be downloaded. By clicking on the button "Download selected attachment", the user will download this attachment from the database and store it in the destination specified.

Upload panel

UploadPanelWithCollection.png In this panel, the user can now upload local data to the web-based system. To do that, it needs first to select the collection directory. That will automatically fill the lists bellow with the content in the collection folder using the same architecture than here.

The user will have the possibility to tick one or multiple attachments to be uploaded. Be careful, switching to another date or patient Id won't keep in memory the attachments you have ticked.
Then, by clicking on the Upload button, the user can upload to the database the attachments ticked.

Create patient Id in a collection

This functionality and the next one are part of the management panel. This panel should be restricted to "admin" users as defined in the database. To show this panel, the "admin" user just needs to click on the collapsible button.

AddPatientId.png This panel has been implemented to facilitate the work for the collection owner. This module is based on a specific architecture as shown upper and needs some temporary files to perfectly parse the collection folder. That means adding a patient Id to a collection is not just creating a folder with a name and a folder with a date in it.

So, all the clean process is done by this panel, in which the user should select the collection folder, then type a patient Id and click on a date to be a default folder. This will generate the files needed for a later use of the upload panel.

Add a date to a patient Id in a collection

AddDateToPatientId.png In the case the "admin" user gets more data for a patient with a different date than the ones already created, this panel gives the possibility to add a new one. First, it needs to select the collection, then a patient Id and finally the date wanted. The last step is to click on the button and check in the collection folder that everything has been correctly done.

Similar Modules

N/A

References

N/A

Information for Developers

The source code is available on github