Skip to content

Commit 285f5c3

Browse files
committed
[EEG] EEG uploader module
1 parent 22fc463 commit 285f5c3

16 files changed

+1535
-1
lines changed

SQL/0000-00-01-Modules.sql

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,6 @@ INSERT INTO modules (Name, Active) VALUES ('timepoint_list', 'Y');
5151
INSERT INTO modules (Name, Active) VALUES ('user_accounts', 'Y');
5252
INSERT INTO modules (Name, Active) VALUES ('electrophysiology_browser', 'Y');
5353
INSERT INTO modules (Name, Active) VALUES ('dqt', 'Y');
54+
INSERT INTO modules (Name, Active) VALUES ('electrophysiology_uploader', 'Y');
5455

5556
ALTER TABLE issues ADD CONSTRAINT `fk_issues_7` FOREIGN KEY (`module`) REFERENCES `modules` (`ID`);

SQL/0000-00-03-ConfigTables.sql

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,8 @@ INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType,
7878
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'MINCToolsPath', 'Path to the MINC tools', 1, 0, 'web_path', ID, 'Path to the MINC tools', 12 FROM ConfigSettings WHERE Name="paths";
7979
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'documentRepositoryPath', 'Path to uploaded document repository files', 1, 0, 'web_path', ID, 'Document Repository Upload Path', 13 FROM ConfigSettings WHERE Name="paths";
8080
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'dataReleasePath', 'Path to uploaded data release files', 1, 0, 'web_path', ID, 'Data release Upload Path', 14 FROM ConfigSettings WHERE Name="paths";
81+
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'EEGUploadIncomingPath', 'Path to the upload directory for incoming EEG studies', 1, 0, 'text', ID, 'EEG Incoming Directory', 7 FROM ConfigSettings WHERE Name="paths";
82+
8183

8284

8385
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, Label, OrderNumber) VALUES ('gui', 'Settings related to the overall display of LORIS', 1, 0, 'GUI', 3);
@@ -289,4 +291,4 @@ INSERT INTO Config (ConfigID, Value) SELECT ID, '' FROM ConfigSettings WHERE Na
289291
INSERT INTO Config (ConfigID, Value) SELECT ID, '' FROM ConfigSettings WHERE Name='bids_dataset_authors';
290292
INSERT INTO Config (ConfigID, Value) SELECT ID, '' FROM ConfigSettings WHERE Name='bids_acknowledgments_text';
291293
INSERT INTO Config (ConfigID, Value) SELECT ID, '' FROM ConfigSettings WHERE Name='bids_readme_text';
292-
INSERT INTO Config (ConfigID, Value) SELECT ID, '' FROM ConfigSettings WHERE Name='bids_validator_options_to_ignore';
294+
INSERT INTO Config (ConfigID, Value) SELECT ID, '' FROM ConfigSettings WHERE Name='bids_validator_options_to_ignore';

SQL/0000-00-05-ElectrophysiologyTables.sql

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -481,6 +481,21 @@ CREATE TABLE `physiological_annotation_rel` (
481481
REFERENCES `physiological_annotation_file` (`AnnotationFileID`)
482482
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
483483

484+
-- Create EEG upload table
485+
CREATE TABLE `electrophysiology_uploader` (
486+
`UploadID` int(10) unsigned NOT NULL AUTO_INCREMENT,
487+
`UploadedBy` varchar(255) NOT NULL DEFAULT '',
488+
`UploadDate` DateTime DEFAULT NULL,
489+
`UploadLocation` varchar(255) NOT NULL DEFAULT '',
490+
`Status` enum('Not Started', 'In Progress', 'Complete', 'Failed') DEFAULT 'Not Started',
491+
`SessionID` int(10) unsigned NOT NULL default '0',
492+
`MetaData` TEXT default NULL,
493+
PRIMARY KEY (`UploadID`),
494+
KEY (`SessionID`),
495+
CONSTRAINT `FK_eegupload_SessionID`
496+
FOREIGN KEY (`SessionID`) REFERENCES `session` (`ID`)
497+
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
498+
484499
-- Insert into physiological_output_type
485500
INSERT INTO physiological_output_type
486501
(`OutputTypeName`, `OutputTypeDescription`)
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
-- Create EEG upload table
2+
CREATE TABLE `electrophysiology_uploader` (
3+
`UploadID` int(10) unsigned NOT NULL AUTO_INCREMENT,
4+
`UploadedBy` varchar(255) NOT NULL DEFAULT '',
5+
`UploadDate` DateTime DEFAULT NULL,
6+
`UploadLocation` varchar(255) NOT NULL DEFAULT '',
7+
`Status` enum('Not Started', 'In Progress', 'Complete', 'Failed') DEFAULT 'Not Started',
8+
`SessionID` int(10) unsigned NOT NULL default '0',
9+
`MetaData` TEXT default NULL,
10+
PRIMARY KEY (`UploadID`),
11+
KEY (`SessionID`),
12+
CONSTRAINT `FK_eegupload_SessionID`
13+
FOREIGN KEY (`SessionID`) REFERENCES `session` (`ID`)
14+
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
15+
16+
-- Add to module table
17+
INSERT INTO modules (Name, Active) VALUES ('electrophysiology_uploader', 'Y');
18+
19+
-- Add new configurations for eeg uploader
20+
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'EEGUploadIncomingPath', 'Path to the upload directory for incoming EEG studies', 1, 0, 'text', ID, 'EEG Incoming Directory', 7 FROM ConfigSettings WHERE Name="paths";
21+
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
-- Create EEG upload table
2+
CREATE TABLE `electrophysiology_uploader` (
3+
`UploadID` int(10) unsigned NOT NULL AUTO_INCREMENT,
4+
`UploadedBy` varchar(255) NOT NULL DEFAULT '',
5+
`UploadDate` DateTime DEFAULT NULL,
6+
`UploadLocation` varchar(255) NOT NULL DEFAULT '',
7+
`Status` enum('Not Started', 'In Progress', 'Complete', 'Failed') DEFAULT 'Not Started',
8+
`SessionID` int(10) unsigned NOT NULL default '0',
9+
PRIMARY KEY (`UploadID`),
10+
KEY (`SessionID`),
11+
CONSTRAINT `FK_eegupload_SessionID`
12+
FOREIGN KEY (`SessionID`) REFERENCES `session` (`ID`)
13+
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
14+
15+
-- Add to module table
16+
INSERT INTO modules (Name, Active) VALUES ('electrophysiology_uploader', 'Y');
17+
18+
-- Add new configurations for eeg uploader
19+
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber)
20+
SELECT 'EEGUploadIncomingPath', 'Path to the upload directory for incoming EEG studies', 1, 0, 'text', ID, 'EEG Incoming Directory', 7
21+
FROM ConfigSettings
22+
WHERE Name="paths";
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
js/*

0 commit comments

Comments
 (0)