Skip to content

Commit

Permalink
Merge remote-tracking branch 'aces/major' into SwitchRouter
Browse files Browse the repository at this point in the history
  • Loading branch information
driusan committed May 7, 2018
2 parents fe720ae + 9cefbcd commit e82de47
Show file tree
Hide file tree
Showing 259 changed files with 9,024 additions and 1,670 deletions.
14 changes: 8 additions & 6 deletions .phan/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,7 @@
// This is false on the assumption that that's a typo.
// It doesn't seem to have any effect on LORIS's codebase anyways.
"quick_mode" => false,
// FIXME: analyze signature compatibility should be true, but
// there's too many other things to fix first.
"analyze_signature_compatibility" => false,
"analyze_signature_compatibility" => true,
// FIXME: allow_missing_properties should be false, but there's
// too many other things to fix first.
"allow_missing_properties" => true,
Expand All @@ -31,8 +29,6 @@
"PhanUndeclaredClassMethod",
"PhanUndeclaredTypeParameter",
"PhanUndeclaredConstant",
"PhanUndeclaredClass",
"PhanUndeclaredExtendedClass",
"PhanTypeMismatchForeach",
"PhanTypeMismatchDefault",
"PhanTypeMismatchArgument",
Expand All @@ -51,7 +47,7 @@
"directory_list" => [
/* This doesn't include php/installer, because there's
(intentionally) classes in the installer namespace
which redeclare classes from php/libraries, in order
which redeclare classes from php/libraries, in order
to bootstrap the installer before the config/database
is set up */
"php/libraries",
Expand All @@ -60,8 +56,14 @@
"modules",
"src",
"vendor",
"test"
],
"exclude_analysis_directory_list" => [
"vendor",
],
'autoload_internal_extension_signatures' => [
// Xdebug stubs are bundled with Phan 0.10.1+/0.8.9+ for usage,
// because Phan disables xdebug by default.
'xdebug' => 'vendor/phan/phan/.phan/internal_stubs/xdebug.phan_php',
],
];
21 changes: 14 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
language: php


cache:
directories:
- vendor

php:
- "7.2"
- "7.1"

sudo: false
- "7.2"

addons:
firefox: "44.0"
Expand All @@ -24,22 +22,26 @@ before_install:
- nvm install node
- mkdir -p project project/libraries
- phpenv config-rm xdebug.ini
<<<<<<< HEAD
- pecl install -f ast-0.1.6

=======
- if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.0" ]]; then Dir="router.php" ; fi
- if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.1" ]]; then Dir="htdocs/router.php" ; fi
- php -S localhost:8000 -t htdocs $Dir 2>1 > /dev/null &
>>>>>>> aces/minor
install:
# Install composer modules
- composer install
- composer require --dev
- phpenv rehash


# Install node modules specified in package.json
- npm install

# Download a Selenium Web Driver release
- wget "http://selenium-release.storage.googleapis.com/2.52/selenium-server-standalone-2.52.0.jar"

- php -S localhost:8000 -t htdocs htdocs/router.php 2>1 > /dev/null &

# Extracting firefox and setting PATH variable...
- tar -xjf /tmp/firefox-44.0.tar.bz2 --directory /tmp
- export PATH="/tmp/firefox:$PATH"
Expand All @@ -51,6 +53,8 @@ install:
- DISPLAY=:99.0 java -jar selenium-server-standalone-2.52.0.jar 2>1 > /dev/null &

before_script:


# Set up the Loris environment
- mkdir -p project smarty/templates_c project/instruments project/tables_sql
- chmod 777 smarty/templates_c project/instruments project/tables_sql
Expand Down Expand Up @@ -95,7 +99,10 @@ before_script:
# - "LORIS_DB_CONFIG=test/config.xml"

script:
<<<<<<< HEAD
- vendor/bin/phan
=======
>>>>>>> aces/minor
- npm run lint:php && npm run lint:javascript && vendor/bin/phpunit --configuration test/phpunit.xml

dist: precise
47 changes: 24 additions & 23 deletions SQL/0000-00-00-schema.sql
Original file line number Diff line number Diff line change
Expand Up @@ -532,27 +532,26 @@ CREATE TABLE `tarchive_files` (


CREATE TABLE `ImagingFileTypes` (
`type` varchar(255) NOT NULL PRIMARY KEY
`type` varchar(12) NOT NULL PRIMARY KEY,
`description` varchar(255) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8;


INSERT INTO `ImagingFileTypes` VALUES
('mnc'),
('obj'),
('xfm'),
('xfmmnc'),
('imp'),
('vertstat'),
('xml'),
('txt'),
('nii'),
('nii.gz'),
('nrrd');
INSERT INTO `ImagingFileTypes` (type, description) VALUES
('mnc', 'MINC file'),
('obj', 'MNI BIC imaging format for a surface'),
('xfm', 'MNI BIC linear transformation matrix file'),
('vertstat', 'MNI BIC imaging format for a field on a surface (e.g. cortical thickness)'),
('xml', 'XML file'),
('txt', 'text file'),
('nii', 'NIfTI file'),
('nrrd', 'NRRD file format (used by DTIPrep)'),
('grid_0', 'MNI BIC non-linear field for non-linear transformation');

CREATE TABLE `mri_processing_protocol` (
`ProcessProtocolID` int(11) unsigned NOT NULL AUTO_INCREMENT,
`ProtocolFile` varchar(255) NOT NULL DEFAULT '',
`FileType` varchar(255) DEFAULT NULL,
`FileType` varchar(12) DEFAULT NULL,
`Tool` varchar(255) NOT NULL DEFAULT '',
`InsertTime` int(10) unsigned NOT NULL DEFAULT '0',
`md5sum` varchar(32) DEFAULT NULL,
Expand Down Expand Up @@ -620,7 +619,7 @@ CREATE TABLE `files` (
`CoordinateSpace` varchar(255) default NULL,
`OutputType` varchar(255) NOT NULL default '',
`AcquisitionProtocolID` int(10) unsigned default NULL,
`FileType` varchar(255) default NULL,
`FileType` varchar(12) default NULL,
`PendingStaging` tinyint(1) NOT NULL default '0',
`InsertedByUserID` varchar(255) NOT NULL default '',
`InsertTime` int(10) unsigned NOT NULL default '0',
Expand Down Expand Up @@ -1340,11 +1339,13 @@ CREATE TABLE `media` (
`uploaded_by` varchar(255) DEFAULT NULL,
`hide_file` tinyint(1) DEFAULT '0',
`date_uploaded` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`language_id` int(10) unsigned DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `file_name` (`file_name`),
FOREIGN KEY (`session_id`) REFERENCES `session` (`ID`),
FOREIGN KEY (`instrument`) REFERENCES `test_names` (`Test_name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
FOREIGN KEY (`instrument`) REFERENCES `test_names` (`Test_name`),
CONSTRAINT `FK_media_language` FOREIGN KEY (`language_id`) REFERENCES `language` (`language_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- ********************************
-- issues tables
Expand Down Expand Up @@ -1410,7 +1411,7 @@ CREATE TABLE `issues_history` (
`addedBy` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`issueHistoryID`),
KEY `fk_issues_comments_1` (`issueID`),
CONSTRAINT `fk_issues_comments_1` FOREIGN KEY (`issueID`) REFERENCES `issues` (`issueID`)
CONSTRAINT `fk_issues_comments_1` FOREIGN KEY (`issueID`) REFERENCES `issues` (`issueID`) ON DELETE CASCADE ON UPDATE RESTRICT
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

CREATE TABLE `issues_comments` (
Expand All @@ -1421,7 +1422,7 @@ CREATE TABLE `issues_comments` (
`issueComment` text NOT NULL,
PRIMARY KEY (`issueCommentID`),
KEY `fk_issue_comments_1` (`issueID`),
CONSTRAINT `fk_issue_comments_1` FOREIGN KEY (`issueID`) REFERENCES `issues` (`issueID`)
CONSTRAINT `fk_issue_comments_1` FOREIGN KEY (`issueID`) REFERENCES `issues` (`issueID`) ON DELETE CASCADE ON UPDATE RESTRICT
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

CREATE TABLE `issues_comments_history` (
Expand All @@ -1432,7 +1433,7 @@ CREATE TABLE `issues_comments_history` (
`editedBy` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`issueCommentHistoryID`),
KEY `fk_issues_comments_history` (`issueCommentID`),
CONSTRAINT `fk_issues_comments_history` FOREIGN KEY (`issueCommentID`) REFERENCES `issues_comments` (`issueCommentID`)
CONSTRAINT `fk_issues_comments_history` FOREIGN KEY (`issueCommentID`) REFERENCES `issues_comments` (`issueCommentID`) ON DELETE CASCADE ON UPDATE RESTRICT
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

CREATE TABLE `issues_watching` (
Expand Down Expand Up @@ -1545,7 +1546,7 @@ CREATE TABLE `parameter_session` (
KEY `session_type` (`SessionID`,`ParameterTypeID`),
KEY `parameter_value` (`ParameterTypeID`,`Value`(64)),
CONSTRAINT `FK_parameter_session_2` FOREIGN KEY (`ParameterTypeID`) REFERENCES `parameter_type` (`ParameterTypeID`),
CONSTRAINT `FK_parameter_session_1` FOREIGN KEY (`SessionID`) REFERENCES `session` (`ID`)
CONSTRAINT `FK_parameter_session_1` FOREIGN KEY (`SessionID`) REFERENCES `session` (`ID`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

CREATE TABLE `parameter_type_override` (
Expand Down Expand Up @@ -1779,8 +1780,8 @@ CREATE TABLE `genomic_cpg` (
`beta_value` decimal(4,3) DEFAULT NULL,
PRIMARY KEY (`sample_label`,`cpg_name`),
KEY `cpg_name` (`cpg_name`),
CONSTRAINT `genomic_cpg_ibfk_1` FOREIGN KEY (`sample_label`) REFERENCES `genomic_sample_candidate_rel` (`sample_label`),
CONSTRAINT `genomic_cpg_ibfk_2` FOREIGN KEY (`cpg_name`) REFERENCES `genomic_cpg_annotation` (`cpg_name`)
CONSTRAINT `genomic_cpg_ibfk_1` FOREIGN KEY (`sample_label`) REFERENCES `genomic_sample_candidate_rel` (`sample_label`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `genomic_cpg_ibfk_2` FOREIGN KEY (`cpg_name`) REFERENCES `genomic_cpg_annotation` (`cpg_name`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- ********************************
Expand Down
18 changes: 9 additions & 9 deletions SQL/0000-00-03-ConfigTables.sql
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType,
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'LivingPhantomRegex', 'Regex to be used on Living Phantom scan header', 1, 0, 'text', ID, 'Living phantom regex', 4 FROM ConfigSettings WHERE Name="imaging_modules";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'showTransferStatus', 'Show transfer status in the DICOM Archive table', 1, 0, 'boolean', ID, 'Show transfer status', 5 FROM ConfigSettings WHERE Name="imaging_modules";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'tblScanTypes', 'Scan types from the mri_scan_type table that the project wants to see displayed in Imaging Browser table', 1, 1, 'scan_type', ID, 'Imaging Browser Tabulated Scan Types', 6 FROM ConfigSettings WHERE Name="imaging_modules";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'ImagingBrowserLinkedInstruments', 'Instruments that the users want to see linked from Imaging Browser', 1, 1, 'instrument', ID, 'Imaging Browser Links to Instruments', 7 FROM ConfigSettings WHERE Name="imaging_modules";


INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, Label, OrderNumber) VALUES ('statistics', 'Statistics module settings', 1, 0, 'Statistics', 7);
Expand Down Expand Up @@ -136,14 +137,13 @@ INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType,
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'prefix', 'Study prefix or study name', 1, 0, 'text', ID, 'Study Name', 2 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'mail_user', 'User to be notified during imaging pipeline execution', 1, 0, 'text', ID, 'User to notify when executing the pipeline', 3 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'get_dicom_info', 'Full path to get_dicom_info.pl', 1, 0, 'text', ID, 'Full path to get_dicom_info.pl script', 4 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'horizontalPics', 'Generate horizontal pictures', 1, 0, 'boolean', ID, 'Horizontal pictures creation', 5 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'no_nii', 'Create NIFTII files if set to 0', 1, 0, 'boolean', ID, 'NIFTII file creation', 6 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'horizontalPics', 'Enable generation of horizontal pictures', 1, 0, 'boolean', ID, 'Horizontal pictures creation', 5 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'create_nii', 'Enable creation of NIfTI files', 1, 0, 'boolean', ID, 'NIfTI file creation', 6 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'converter', 'If converter is set to dcm2mnc, the c-version of dcm2mnc will be used. If however you want to use any of the various versions of the converter, you will have to specify what it is called and the uploader will try to invoke it', 1, 0, 'text', ID, 'dcm2mnc binary to use when converting', 7 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'tarchiveLibraryDir', 'Location of storing the library of used tarchives. If this is not set, they will not be moved', 1, 0, 'text', ID, 'Path to Tarchives', 8 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'lookupCenterNameUsing', 'The element of the tarchive table to be used in getPSC(), being either PatientID or PatientName', 1, 0, 'text', ID, 'Center name lookup variable', 9 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'createCandidates', 'Creation of candidates if set to 1', 1, 0, 'boolean', ID, 'Upload creation of candidates', 10 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'is_qsub', 'Do not use batch management if qsub is set to 0', 1, 0, 'boolean', ID, 'Project batch management used', 11 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'if_site', 'Use site if set to 1', 1, 0, 'boolean', ID, 'If site is used', 12 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'lookupCenterNameUsing', 'DICOM field (either PatientName or PatientID) to use to get the patient identifiers and the center name of the DICOM study', 1, 0, 'text', ID, 'Patient identifiers and center name lookup variable', 9 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'createCandidates', 'Enable candidate creation in the imaging pipeline', 1, 0, 'boolean', ID, 'Upload creation of candidates', 10 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'is_qsub', 'Enable use of batch management in the imaging pipeline', 1, 0, 'boolean', ID, 'Project batch management used', 11 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'DTI_volumes', 'Number of volumes in native DTI acquisitions', 1, 0, 'text', ID, 'Number of volumes in native DTI acquisitions', 13 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 't1_scan_type', 'Scan type of native T1 acquisition (as in the mri_scan_type table)', 1, 0, 'text', ID, 'Scan type of native T1 acquisition', 14 FROM ConfigSettings WHERE Name="imaging_pipeline";
INSERT INTO ConfigSettings (Name, Description, Visible, AllowMultiple, DataType, Parent, Label, OrderNumber) SELECT 'reject_thresh', 'Max number of directions that can be rejected to PASS QC', 1, 0, 'text', ID, 'Max number of DTI rejected directions for passing QC', 15 FROM ConfigSettings WHERE Name="imaging_pipeline";
Expand Down Expand Up @@ -210,7 +210,8 @@ INSERT INTO Config (ConfigID, Value) SELECT ID, "/phantom/i" FROM ConfigSettings
INSERT INTO Config (ConfigID, Value) SELECT ID, "false" FROM ConfigSettings WHERE Name="showTransferStatus";
INSERT INTO Config (ConfigID, Value) SELECT cs.ID, GROUP_CONCAT(mst.Scan_Type) FROM ConfigSettings cs JOIN mri_scan_type mst WHERE cs.Name="tblScanTypes" AND mst.ID=44;
INSERT INTO Config (ConfigID, Value) SELECT cs.ID, GROUP_CONCAT(mst.Scan_Type) FROM ConfigSettings cs JOIN mri_scan_type mst WHERE cs.Name="tblScanTypes" AND mst.ID=45;

INSERT INTO Config (ConfigID, Value) SELECT cs.ID, "mri_parameter_form" FROM ConfigSettings cs WHERE cs.Name="ImagingBrowserLinkedInstruments";
INSERT INTO Config (ConfigID, Value) SELECT cs.ID, "radiology_review" FROM ConfigSettings cs WHERE cs.Name="ImagingBrowserLinkedInstruments";

INSERT INTO Config (ConfigID, Value) SELECT ID, "radiology_review" FROM ConfigSettings WHERE Name="excludedMeasures";
INSERT INTO Config (ConfigID, Value) SELECT ID, "mri_parameter_form" FROM ConfigSettings WHERE Name="excludedMeasures";
Expand All @@ -229,13 +230,12 @@ INSERT INTO Config (ConfigID, Value) SELECT ID, "project" FROM ConfigSettings cs
INSERT INTO Config (ConfigID, Value) SELECT ID, "yourname\@example.com" FROM ConfigSettings cs WHERE cs.Name="mail_user";
INSERT INTO Config (ConfigID, Value) SELECT ID, "/PATH/TO/get_dicom_info.pl" FROM ConfigSettings cs WHERE cs.Name="get_dicom_info";
INSERT INTO Config (ConfigID, Value) SELECT ID, 1 FROM ConfigSettings cs WHERE cs.Name="horizontalPics";
INSERT INTO Config (ConfigID, Value) SELECT ID, 0 FROM ConfigSettings cs WHERE cs.Name="no_nii";
INSERT INTO Config (ConfigID, Value) SELECT ID, 1 FROM ConfigSettings cs WHERE cs.Name="create_nii";
INSERT INTO Config (ConfigID, Value) SELECT ID, "dcm2mnc" FROM ConfigSettings cs WHERE cs.Name="converter";
INSERT INTO Config (ConfigID, Value) SELECT ID, "/PATH/TO/dicomlib/" FROM ConfigSettings cs WHERE cs.Name="tarchiveLibraryDir";
INSERT INTO Config (ConfigID, Value) SELECT ID, "PatientName" FROM ConfigSettings cs WHERE cs.Name="lookupCenterNameUsing";
INSERT INTO Config (ConfigID, Value) SELECT ID, 1 FROM ConfigSettings cs WHERE cs.Name="createCandidates";
INSERT INTO Config (ConfigID, Value) SELECT ID, 0 FROM ConfigSettings cs WHERE cs.Name="is_qsub";
INSERT INTO Config (ConfigID, Value) SELECT ID, 1 FROM ConfigSettings cs WHERE cs.Name="if_site";
INSERT INTO Config (ConfigID, Value) SELECT ID, 65 FROM ConfigSettings cs WHERE cs.Name="DTI_volumes";
INSERT INTO Config (ConfigID, Value) SELECT ID, "adniT1" FROM ConfigSettings cs WHERE cs.Name="t1_scan_type";
INSERT INTO Config (ConfigID, Value) SELECT ID, 19 FROM ConfigSettings cs WHERE cs.Name="reject_thresh";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ CREATE TABLE `language` (
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

INSERT INTO language (language_code, language_label) VALUES ('en-CA', 'English');
--INSERT INTO language (language_code, language_label) VALUES ('fr-CA', 'French');

ALTER TABLE users ADD language_preference integer unsigned DEFAULT NULL;
ALTER TABLE users ADD CONSTRAINT `FK_users_2` FOREIGN KEY (`language_preference`) REFERENCES `language` (`language_id`);
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ALTER TABLE media ADD COLUMN language_id INT UNSIGNED DEFAULT NULL;
ALTER TABLE media ADD CONSTRAINT `FK_media_language` FOREIGN KEY (`language_id`) REFERENCES `language` (`language_id`);

Loading

0 comments on commit e82de47

Please sign in to comment.