From 7737f20a46b5d2582a3d4d37ed0183bc9346bb17 Mon Sep 17 00:00:00 2001 From: Charlotte Sacre Date: Tue, 1 Aug 2023 13:54:37 -0400 Subject: [PATCH 1/4] CouchDB_MRI_Import - fix date MRI --- tools/CouchDB_MRI_Importer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/CouchDB_MRI_Importer.php b/tools/CouchDB_MRI_Importer.php index c58c28f73c5..b45158db8fa 100755 --- a/tools/CouchDB_MRI_Importer.php +++ b/tools/CouchDB_MRI_Importer.php @@ -249,7 +249,7 @@ function _addMRIHeaderInfo($FileObj, $scan_type) $FileObj, 'acquisition_date' ); - $header['FileInsertDate_'.$type] = $FileObj->getParameter('InsertTime'); + $header['FileInsertDate_'.$type] = date('Y-m-d', $FileObj->getParameter('InsertTime')); $header['SeriesDescription_'.$type] = $FileObj->getParameter($ser_desc); $header['SeriesNumber_'.$type] = $FileObj->getParameter($ser_num); $header['EchoTime_'.$type] = number_format( @@ -438,7 +438,7 @@ function updateCandidateDocs($data, $ScanTypes) $row['PSCID'], $row['Visit_label'], ]; - $docid = 'MRI_Files:' . join($identifier, '_'); + $docid = 'MRI_Files:' . join('_', $identifier); unset($doc['PSCID']); unset($doc['Visit_label']); unset($doc['SessionID']); From 28f43c62946bab74c5a336e401205d2f05f835df Mon Sep 17 00:00:00 2001 From: Charlotte Sacre Date: Tue, 1 Aug 2023 14:13:41 -0400 Subject: [PATCH 2/4] CouchDB_MRI_Importer - fix php line max characters --- tools/CouchDB_MRI_Importer.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tools/CouchDB_MRI_Importer.php b/tools/CouchDB_MRI_Importer.php index b45158db8fa..a8d3dde87ec 100755 --- a/tools/CouchDB_MRI_Importer.php +++ b/tools/CouchDB_MRI_Importer.php @@ -249,7 +249,10 @@ function _addMRIHeaderInfo($FileObj, $scan_type) $FileObj, 'acquisition_date' ); - $header['FileInsertDate_'.$type] = date('Y-m-d', $FileObj->getParameter('InsertTime')); + $header['FileInsertDate_'.$type] = date( + 'Y-m-d', + $FileObj->getParameter('InsertTime') + ); $header['SeriesDescription_'.$type] = $FileObj->getParameter($ser_desc); $header['SeriesNumber_'.$type] = $FileObj->getParameter($ser_num); $header['EchoTime_'.$type] = number_format( From b9798f90eb541c9a56074968c41fe4e59807378e Mon Sep 17 00:00:00 2001 From: Charlotte Sacre Date: Tue, 1 Aug 2023 14:36:00 -0400 Subject: [PATCH 3/4] CouchDB_MRI_Importer - redo missing commit --- tools/CouchDB_MRI_Importer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/CouchDB_MRI_Importer.php b/tools/CouchDB_MRI_Importer.php index a8d3dde87ec..c0d9253801f 100755 --- a/tools/CouchDB_MRI_Importer.php +++ b/tools/CouchDB_MRI_Importer.php @@ -250,7 +250,7 @@ function _addMRIHeaderInfo($FileObj, $scan_type) 'acquisition_date' ); $header['FileInsertDate_'.$type] = date( - 'Y-m-d', + 'Y-m-d', $FileObj->getParameter('InsertTime') ); $header['SeriesDescription_'.$type] = $FileObj->getParameter($ser_desc); From 05343552253679b5046fa16e8cb04a5b9dc98e3d Mon Sep 17 00:00:00 2001 From: Charlotte Sacre Date: Tue, 1 Aug 2023 14:36:08 -0400 Subject: [PATCH 4/4] CouchDB_MRI_Importer - redo missing commit --- tools/CouchDB_MRI_Importer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/CouchDB_MRI_Importer.php b/tools/CouchDB_MRI_Importer.php index c0d9253801f..a8d3dde87ec 100755 --- a/tools/CouchDB_MRI_Importer.php +++ b/tools/CouchDB_MRI_Importer.php @@ -250,7 +250,7 @@ function _addMRIHeaderInfo($FileObj, $scan_type) 'acquisition_date' ); $header['FileInsertDate_'.$type] = date( - 'Y-m-d', + 'Y-m-d', $FileObj->getParameter('InsertTime') ); $header['SeriesDescription_'.$type] = $FileObj->getParameter($ser_desc);