feat(worklist): New worklist buttons and tooltips (#3989)
This commit is contained in:
1 parent
6b79dff5c1
commit
9bcd1ae6f5
13 files changed
+120
-36
No files matched your search
@@ -133,8 +133,15 @@ function modeFactory({ modeConfiguration }) {
|
||||
]);
|
||||
},
|
||||
onModeExit: ({ servicesManager }) => {
|
||||
const { toolGroupService, measurementService, toolbarService } = servicesManager.services;
|
||||
|
||||
const {
|
||||
toolGroupService,
|
||||
measurementService,
|
||||
toolbarService,
|
||||
uiDialogService,
|
||||
uiModalService,
|
||||
} = servicesManager.services;
|
||||
uiDialogService.dismissAll();
|
||||
uiModalService.hide();
|
||||
toolGroupService.destroy();
|
||||
},
|
||||
validationTags: {
|
||||
@@ -145,7 +152,10 @@ function modeFactory({ modeConfiguration }) {
|
||||
const modalities_list = modalities.split('\\');
|
||||
|
||||
// Slide Microscopy modality not supported by basic mode yet
|
||||
return !modalities_list.includes('SM');
|
||||
return {
|
||||
valid: !modalities_list.includes('SM'),
|
||||
description: 'The mode does not support the following modalities: SM',
|
||||
};
|
||||
},
|
||||
routes: [
|
||||
{
|
||||
|
||||
@@ -143,8 +143,12 @@ function modeFactory() {
|
||||
syncGroupService,
|
||||
segmentationService,
|
||||
cornerstoneViewportService,
|
||||
uiDialogService,
|
||||
uiModalService,
|
||||
} = servicesManager.services;
|
||||
|
||||
uiDialogService.dismissAll();
|
||||
uiModalService.hide();
|
||||
toolGroupService.destroy();
|
||||
syncGroupService.destroy();
|
||||
segmentationService.destroy();
|
||||
@@ -159,8 +163,12 @@ function modeFactory() {
|
||||
const modalities_list = modalities.split('\\');
|
||||
|
||||
// Exclude non-image modalities
|
||||
return !!modalities_list.filter(modality => NON_IMAGE_MODALITIES.indexOf(modality) === -1)
|
||||
.length;
|
||||
return {
|
||||
valid: !!modalities_list.filter(modality => NON_IMAGE_MODALITIES.indexOf(modality) === -1)
|
||||
.length,
|
||||
description:
|
||||
'The mode does not support studies that ONLY include the following modalities: SM, ECG, SR, SEG',
|
||||
};
|
||||
},
|
||||
routes: [
|
||||
{
|
||||
|
||||
@@ -179,11 +179,15 @@ function modeFactory({ modeConfiguration }) {
|
||||
toolbarService,
|
||||
segmentationService,
|
||||
cornerstoneViewportService,
|
||||
uiDialogService,
|
||||
uiModalService,
|
||||
} = servicesManager.services;
|
||||
|
||||
_activatePanelTriggersSubscriptions.forEach(sub => sub.unsubscribe());
|
||||
_activatePanelTriggersSubscriptions = [];
|
||||
|
||||
uiDialogService.dismissAll();
|
||||
uiModalService.hide();
|
||||
toolGroupService.destroy();
|
||||
syncGroupService.destroy();
|
||||
segmentationService.destroy();
|
||||
@@ -198,8 +202,12 @@ function modeFactory({ modeConfiguration }) {
|
||||
const modalities_list = modalities.split('\\');
|
||||
|
||||
// Exclude non-image modalities
|
||||
return !!modalities_list.filter(modality => NON_IMAGE_MODALITIES.indexOf(modality) === -1)
|
||||
.length;
|
||||
return {
|
||||
valid: !!modalities_list.filter(modality => NON_IMAGE_MODALITIES.indexOf(modality) === -1)
|
||||
.length,
|
||||
description:
|
||||
'The mode does not support studies that ONLY include the following modalities: SM, ECG, SR, SEG, RTSTRUCT',
|
||||
};
|
||||
},
|
||||
routes: [
|
||||
{
|
||||
|
||||
@@ -56,8 +56,10 @@ function modeFactory({ modeConfiguration }) {
|
||||
},
|
||||
|
||||
onModeExit: ({ servicesManager }) => {
|
||||
const { toolbarService } = servicesManager.services;
|
||||
const { toolbarService, uiDialogService, uiModalService } = servicesManager.services;
|
||||
|
||||
uiDialogService.dismissAll();
|
||||
uiModalService.hide();
|
||||
toolbarService.reset();
|
||||
},
|
||||
|
||||
@@ -69,8 +71,10 @@ function modeFactory({ modeConfiguration }) {
|
||||
isValidMode: ({ modalities }) => {
|
||||
const modalities_list = modalities.split('\\');
|
||||
|
||||
// Slide Microscopy and ECG modality not supported by basic mode yet
|
||||
return modalities_list.includes('SM');
|
||||
return {
|
||||
valid: modalities_list.includes('SM'),
|
||||
description: 'Microscopy mode only supports the SM modality',
|
||||
};
|
||||
},
|
||||
|
||||
routes: [
|
||||
|
||||
@@ -106,8 +106,12 @@ function modeFactory({ modeConfiguration }) {
|
||||
toolbarService,
|
||||
segmentationService,
|
||||
cornerstoneViewportService,
|
||||
uiDialogService,
|
||||
uiModalService,
|
||||
} = servicesManager.services;
|
||||
|
||||
uiDialogService.dismissAll();
|
||||
uiModalService.hide();
|
||||
toolGroupService.destroy();
|
||||
syncGroupService.destroy();
|
||||
segmentationService.destroy();
|
||||
@@ -127,11 +131,10 @@ function modeFactory({ modeConfiguration }) {
|
||||
// Don't show the mode if the selected studies have only one modality
|
||||
// that is not supported by the mode
|
||||
const modalitiesArray = modalities.split('\\');
|
||||
if (modalitiesArray.length === 1) {
|
||||
return !['SM', 'US', 'MG', 'OT', 'DOC', 'CR'].includes(modalitiesArray[0]);
|
||||
return {
|
||||
valid: modalitiesArray.length === 1 ? !['SM', 'US', 'MG', 'OT', 'DOC', 'CR'].includes(modalitiesArray[0]) : true,
|
||||
description: 'The mode does not support studies that ONLY include the following modalities: SM, US, MG, OT, DOC, CR',
|
||||
}
|
||||
|
||||
return true;
|
||||
},
|
||||
/**
|
||||
* Mode Routes are used to define the mode's behavior. A list of Mode Route
|
||||
|
||||
@@ -165,9 +165,13 @@ function modeFactory({ modeConfiguration }) {
|
||||
syncGroupService,
|
||||
segmentationService,
|
||||
cornerstoneViewportService,
|
||||
uiDialogService,
|
||||
uiModalService,
|
||||
} = servicesManager.services;
|
||||
|
||||
unsubscriptions.forEach(unsubscribe => unsubscribe());
|
||||
uiDialogService.dismissAll();
|
||||
uiModalService.hide();
|
||||
toolGroupService.destroy();
|
||||
syncGroupService.destroy();
|
||||
segmentationService.destroy();
|
||||
@@ -193,7 +197,10 @@ function modeFactory({ modeConfiguration }) {
|
||||
study.studyInstanceUid !== '1.3.6.1.4.1.12842.1.1.14.3.20220915.105557.468.2963630849';
|
||||
|
||||
// there should be both CT and PT modalities and the modality should not be SM
|
||||
return isValid;
|
||||
return {
|
||||
valid: isValid,
|
||||
description: 'The mode requires both PT and CT series in the study',
|
||||
};
|
||||
},
|
||||
routes: [
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user