-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
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
- Loading branch information
1 parent
1783351
commit 9486522
Showing
68 changed files
with
1,422 additions
and
514 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
.idea/ | ||
.vscode/ | ||
.meteor/local | ||
.meteor/meteorite | ||
.meteor/dev_bundle | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
OHIFViewer/client/components/ohifViewer/structuredReportModal/structureReportModal.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<template name="structuredReportModal"> | ||
{{#dialogForm (extend this | ||
id='structuredReportModal' | ||
dialogClass='themed modal-lg' | ||
title='Structured report' | ||
hideCancel=true | ||
hideConfirm=true | ||
)}} | ||
<div id="root"></div> | ||
{{/dialogForm}} | ||
</template> |
91 changes: 91 additions & 0 deletions
91
OHIFViewer/client/components/ohifViewer/structuredReportModal/structuredReportModal.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
import { $ } from 'meteor/jquery'; | ||
import { OHIF } from 'meteor/ohif:core'; | ||
|
||
Template.structuredReportModal.onRendered(() => { | ||
const structuredReport = getStructureReport(); | ||
|
||
render(structuredReport); | ||
}); | ||
|
||
// FIXME: we use just 1st SR for current study for now | ||
function getStructureReport() { | ||
let structuredReport; | ||
|
||
OHIF.viewer.StudyMetadataList.find(studyMetadata => { | ||
|
||
structuredReport = studyMetadata.findInstance(instance => instance.getData().modality === 'SR'); | ||
|
||
// If SR is found stop the search | ||
return !!structuredReport; | ||
}); | ||
|
||
return structuredReport; | ||
} | ||
|
||
function render(structureReport) { | ||
const root = $('#root'); | ||
|
||
if (structureReport) { | ||
renderStructuredReport(root, structureReport.getData()); | ||
} else { | ||
renderNoData(root); | ||
} | ||
|
||
} | ||
|
||
function renderStructuredReport(root, data) { | ||
root.append(getMainDataHtml(data)); | ||
root.append(getContentSequenceHtml(data.contentSequence)); | ||
} | ||
|
||
function renderNoData(root) { | ||
root.append('<div>No structured report found</div>'); | ||
} | ||
|
||
function getMainDataHtml(data) { | ||
const root = $('<div></div>'); | ||
|
||
const { completionFlag, verificationFlag, manufacturer, contentDateTime } = data; | ||
|
||
if (completionFlag) { | ||
root.append(getMainDataItemHtml('Completion flag', completionFlag)); | ||
} | ||
|
||
if (verificationFlag) { | ||
root.append(getMainDataItemHtml('Verification flag', verificationFlag)); | ||
} | ||
|
||
if (manufacturer) { | ||
root.append(getMainDataItemHtml('Manufacturer', manufacturer)); | ||
} | ||
|
||
if (contentDateTime) { | ||
root.append(getMainDataItemHtml('Content Date/Time', contentDateTime)); | ||
} | ||
|
||
return root; | ||
} | ||
|
||
const getContentSequenceHtml = (data, level = 1) => { | ||
const root = $('<div></div>'); | ||
const header = data.header; | ||
const items = data.items || []; | ||
|
||
if (header) { | ||
root.append(`<h${level}>${header}</h${level}>`); | ||
} | ||
|
||
items.forEach(item => { | ||
root.append( | ||
item instanceof Object | ||
? getContentSequenceHtml(item, level + 1) | ||
: `<div>${item}</div>` | ||
); | ||
}); | ||
|
||
return root; | ||
} | ||
|
||
function getMainDataItemHtml(key, value) { | ||
return $(`<div><b>${key}</b>: ${value}</div>`); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
Packages/ohif-demo-mode/client/components/demoSignin/demoSignin.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<template name="demoSignin"> | ||
<div class="demoSignin"> | ||
<div class="demo-content"> | ||
<div class="demo-brand"> | ||
<svg class="logo-image"> | ||
<use xlink:href={{absoluteUrl "packages/ohif_viewerbase/assets/icons.svg#icon-ohif-logo"}}></use> | ||
</svg> | ||
<div class="logo-text">Open Health Imaging Foundation</div> | ||
</div> | ||
<div class="demoSigninButtons"> | ||
<button type="submit" id="google-login-button" class="button button--nostyle"> | ||
<span class="sign-in-with-google-icon-tile"> | ||
<svg class="google-icon"> | ||
<use xlink:href={{absoluteUrl "packages/ohif_viewerbase/assets/icons.svg#google-icon"}}></use> | ||
</svg></span> | ||
<span>Sign in with Google</span> | ||
</button> | ||
<hr class="tint"> | ||
<button id="anonymous-login-button"> | ||
<span>Anonymous Sign in</span> | ||
</button> | ||
</div> | ||
</div> | ||
</div> | ||
</template> |
15 changes: 15 additions & 0 deletions
15
Packages/ohif-demo-mode/client/components/demoSignin/demoSignin.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { OHIF } from 'meteor/ohif:core'; | ||
import { Router } from 'meteor/clinical:router'; | ||
|
||
Template.demoSignin.events({ | ||
'click #google-login-button'() { | ||
OHIF.gcloud.setEnabled(true); | ||
OHIF.user.login(); | ||
}, | ||
'click #anonymous-login-button'() { | ||
OHIF.gcloud.setEnabled(false); | ||
OHIF.demoMode.login(); | ||
Router.go('/studylist', {}, { replaceState: true }); | ||
} | ||
}); | ||
|
93 changes: 93 additions & 0 deletions
93
Packages/ohif-demo-mode/client/components/demoSignin/demoSignin.styl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
@require '{ohif:design}/app' | ||
|
||
.demoSignin | ||
display flex | ||
flex 1 | ||
flex-flow row nowrap | ||
align-items stretch | ||
height 100vh | ||
min-height 600px | ||
width 100% | ||
background-color rgba(21, 25, 30, 0.7) | ||
|
||
.demo-content | ||
margin auto | ||
width 500px | ||
position relative | ||
top -150px | ||
|
||
.demoSigninButtons | ||
margin auto | ||
width 270px | ||
font-weight 500 | ||
|
||
#google-login-button | ||
display flex | ||
justify-content center | ||
height 40px | ||
width 100% | ||
color #fff | ||
border-color #4285F4 | ||
background #4285F4 | ||
border-radius 3px | ||
box-shadow 0 0 1px 0 rgba(0, 0, 0, 0.12), 0 1px 1px 0 rgba(0, 0, 0, 0.24) | ||
cursor pointer | ||
position relative | ||
align-items center | ||
|
||
#anonymous-login-button | ||
display flex | ||
justify-content center | ||
height 40px | ||
width 100% | ||
color #757575 | ||
border-color white | ||
background white | ||
border-radius 3px | ||
box-shadow 0 0 1px 0 rgba(0, 0, 0, 0.12), 0 1px 1px 0 rgba(0, 0, 0, 0.24) | ||
cursor pointer | ||
position relative | ||
align-items center | ||
|
||
#google-login-button .sign-in-with-google-icon-tile | ||
position absolute | ||
top 1px | ||
left 1px | ||
background #fff | ||
border-radius 2px | ||
height 32px | ||
width 32px | ||
display flex | ||
align-items center | ||
justify-content center | ||
font-weight 500 | ||
|
||
svg.google-icon | ||
width 24px | ||
height 24px | ||
|
||
hr.tint | ||
border-color hsla(0, 0%, 100%, 0.3) | ||
|
||
.demo-brand | ||
height 60px | ||
display inline-block | ||
text-decoration none | ||
margin-bottom 30px | ||
|
||
.logo-image | ||
display inline-block | ||
fill transparent | ||
float left | ||
height 100% | ||
margin 0 8px 0 0 | ||
width 60px | ||
margin-right 20px | ||
|
||
.logo-text | ||
display inline-block | ||
font-family Roboto, Arial, Helvetica, sans-serif | ||
font-size 26px | ||
font-weight 400 | ||
theme('color', '$textPrimaryColor') | ||
line-height 60px |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import './demoSignin/demoSignin.html'; | ||
import './demoSignin/demoSignin.js'; | ||
import './demoSignin/demoSignin.styl'; |
Oops, something went wrong.