feat(google-cloud): Add support for Google Cloud Healthcare API DICOM Store Switch (#325)

* NOTASK: PoC for loading data from Healthcare API

* NOTASK: PoC for loading data from Healthcare API fix

* Add sample dialog for loading test dicom-picker

* Fix incorrect promise resolving

* NOTASK: PoC for loading dicom store

* Add web-components as git submodules. (Probably will be changed later)

* Add rough dicomStore picker

* Add dataset selector

* NOTASK: QIDO metadata first draft

* NOTASK: Not Implemented error for color images

* NOTASK: clean-up

* Dicom files uploader intermediate version

* NOTASK: Accept header

* NOTASK: docker configs

* NOTASK: fix

* NOTASK: howTo

* Add draft of DICOM uploader

* Add missing files

* Fix error with missing clientId

* Update submodule

* NOTASK: HowTo

* NOTASK: config for dev

* NOTASK: new docker file

* clean-up

* Update GCP web-components

* Add integration with async web components

* Fix errors in nginx.conf

* Structured reports views basic implementation

* NOTASK: qido -> wado

* NOTASK: config fix

* NOTASK: dirty copy-paste implementation

* Add "Change dicom store" button.
Add an ability to clear date.
Fix bug, when OAuth dosn't work if URL is not /

* Fix studylist filtering

* Fix dockerfile

* NOTASK: meteor update

* NOTASK: fix of package structure

* NOTASK: merge fix

* improvements

Move check for now SR into SR modal
Use simple button to open SR modal
Remove button styling
cleanup

* copy SR data retrieval to wado

* make search of SR simpler

* Codestyle fix

* NOTASK: palette color error message

* Fix date filter.
Fix server settings on first loading.
Add SR and PS buttons

* NOTASK: PS is now hidden by default

* NOTASK: dirty solution

* NOTASK:  new wadoimage lib version

* Fix PS and SR buttons

* Make modal dialogs vertically centered

* Update web components. Quick UI fixes

* Add missing files to the previous commit

* NOTASK:  show-hide for PS

* NOTASK:  show-hide for PS

* NOTASK:  fix of min-max PixelValue bug

* Add "sign out" functionality for Google OAuth. Update web-components.

* intermediate commit

* Add demo signin page

* Beautifying demo sign in page

* NOTASK:  merge

* NOTASK:  clean-up

* Use npm for getting healthcare-api-adapter instead of git submodule.

* NOTASK:  clean-up

* meteor update

* clean-up

* clean-up

* Clean up code

* Update healthcare-api-adapter version. Add location to dicom store path. Fix buttons style.

* Downgrade meteor and packages to master version. Use meteor-build-client-fixed2
This commit is contained in:
Egor Lezhnin authored and Erik Ziegler committed 2019-03-22 16:42:26 +01:00
1 parent 1783351f57
commit 9486522552
68 files changed
+1422 -514

No files matched your search

@@ -9,7 +9,7 @@ export function getWADORSImageUrl(instance, frame) {
frame = (frame || 0) + 1;
// Replaces /frame/1 by /frame/{frame}
wadorsuri = wadorsuri.replace(/(%2Fframes%2F)(\d+)/, `$1${frame}`);
wadorsuri = wadorsuri.replace(/(\/frames\/)(\d+)/, `$1${frame}`);
return wadorsuri;
}
@@ -9,10 +9,28 @@ const formatPN = context => {
// Convert the first ^ to a ', '. String.replace() only affects
// the first appearance of the character.
const commaBetweenFirstAndLast = context.replace('^', ', ');
//const commaBetweenFirstAndLast = context.replace('^', ', ');
// Replace any remaining '^' characters with spaces
const cleaned = commaBetweenFirstAndLast.replace(/\^/g, ' ');
//const cleaned = commaBetweenFirstAndLast.replace(/\^/g, ' ');
// for cloud healthcare replace all ^ with ', '
const cleaned = context.replace(/\^/g, ', ');
// Trim any extraneous whitespace
return cleaned.trim();
};
/**
* Formats a patient name for display purposes
*/
const reverseFormatPN = context => {
if (!context) {
context;
}
// Replace any remaining '^' characters with spaces
const cleaned = context.replace(/, /g, '^');
// Trim any extraneous whitespace
return cleaned.trim();
@@ -27,4 +45,8 @@ if (!Blaze._getGlobalHelper('formatPN')) {
Blaze.registerHelper('formatPN', formatPN);
}
export { formatPN };
if (!Blaze._getGlobalHelper('reverseFormatPN')) {
Blaze.registerHelper('reverseFormatPN', reverseFormatPN);
}
export { formatPN, reverseFormatPN };
@@ -3,7 +3,7 @@
*/
import { isTouchDevice } from './isTouchDevice';
import { formatPN } from './formatPN';
import { formatPN, reverseFormatPN } from './formatPN';
import { formatDA } from './formatDA';
import { formatTM } from './formatTM';
@@ -33,7 +33,8 @@ const helpers = {
isTouchDevice,
formatPN,
formatDA,
formatTM
formatTM,
reverseFormatPN
};
export { helpers };
@@ -225,6 +225,16 @@ Meteor.startup(function() {
name: 'Show/Hide Download Dialog',
action: viewportUtils.toggleDownloadDialog,
disabled: () => !viewportUtils.isDownloadEnabled()
},
ps: {
name: 'Show/Hide Presentation State',
action: () => Session.set('MeasurementsReady', !Session.get('MeasurementsReady')),
disabled: () => false
},
sr: {
name: 'Show/Hide Structured Report',
action: () => OHIF.ui.showDialog('structuredReportModal'),
disabled: () => false
}
}, true);
@@ -167,6 +167,18 @@ const clearTools = () => {
toolStateManager.clear(element);
cornerstone.updateImage(element);
};
const hideTools = () => {
const element = getActiveViewportElement();
const toolStateManager = cornerstoneTools.globalImageIdSpecificToolStateManager;
toolStateManager.hide(element);
cornerstone.updateImage(element);
};
const unhideTools = () => {
const element = getActiveViewportElement();
const toolStateManager = cornerstoneTools.globalImageIdSpecificToolStateManager;
toolStateManager.unhide(element);
cornerstone.updateImage(element);
};
const linkStackScroll = () => {
const synchronizer = OHIF.viewer.stackImagePositionOffsetSynchronizer;
@@ -383,6 +395,8 @@ const viewportUtils = {
flipH,
resetViewport,
clearTools,
hideTools,
unhideTools,
linkStackScroll,
toggleDialog,
toggleCinePlay,