LT-275: Fixing cornerstone residual data when opening a study
This commit is contained in:
parent
0ec4c6a555
commit
2d291251e9
@ -89,6 +89,7 @@ Template.viewer.onCreated(() => {
|
|||||||
measurementsPromise.then(() => {
|
measurementsPromise.then(() => {
|
||||||
Session.set('MeasurementsReady', true);
|
Session.set('MeasurementsReady', true);
|
||||||
|
|
||||||
|
console.warn('>>>>SYNC CALLED');
|
||||||
instance.data.measurementApi.syncMeasurementsAndToolData();
|
instance.data.measurementApi.syncMeasurementsAndToolData();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@ -85,6 +85,7 @@ class MeasurementApi {
|
|||||||
configuration.measurementTools.forEach(tool => {
|
configuration.measurementTools.forEach(tool => {
|
||||||
const measurements = this[tool.id].find().fetch();
|
const measurements = this[tool.id].find().fetch();
|
||||||
measurements.forEach(measurement => {
|
measurements.forEach(measurement => {
|
||||||
|
console.warn('>>>>MEASUREMENT', measurement);
|
||||||
OHIF.measurements.syncMeasurementAndToolData(measurement);
|
OHIF.measurements.syncMeasurementAndToolData(measurement);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@ -13,6 +13,9 @@ switchToTab = function(contentId) {
|
|||||||
|
|
||||||
OHIF.log.info('Switching to tab: ' + contentId);
|
OHIF.log.info('Switching to tab: ' + contentId);
|
||||||
|
|
||||||
|
// Clear the cornerstone tool data to sync the measurements with the measurements API
|
||||||
|
cornerstoneTools.globalImageIdSpecificToolStateManager.restoreToolState({});
|
||||||
|
|
||||||
$('.tab-content .tab-pane').removeClass('active');
|
$('.tab-content .tab-pane').removeClass('active');
|
||||||
if (contentId !== 'studylistTab') {
|
if (contentId !== 'studylistTab') {
|
||||||
$('.tab-content .tab-pane#viewerTab').addClass('active');
|
$('.tab-content .tab-pane#viewerTab').addClass('active');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user