fix: Segmentation stats customization module (#5324)
This commit is contained in:
parent
e071ed740f
commit
b9d6f558cb
@ -16,9 +16,12 @@ export function setupSegmentationDataModifiedHandler({
|
||||
const { unsubscribe: debouncedUnsubscribe } = segmentationService.subscribeDebounced(
|
||||
segmentationService.EVENTS.SEGMENTATION_DATA_MODIFIED,
|
||||
async ({ segmentationId }) => {
|
||||
|
||||
const disableUpdateSegmentationStats = customizationService.getCustomization('panelSegmentation.disableUpdateSegmentationStats');
|
||||
|
||||
const segmentation = segmentationService.getSegmentation(segmentationId);
|
||||
|
||||
if (!segmentation) {
|
||||
if (!segmentation || disableUpdateSegmentationStats) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@ -1310,6 +1310,24 @@ window.config = {
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
`,
|
||||
},
|
||||
{
|
||||
id: 'panelSegmentation.disableUpdateSegmentationStats',
|
||||
description: 'Disables the automatic update of segmentation statistics in the panel.',
|
||||
default: false,
|
||||
image: [],
|
||||
configuration: `
|
||||
window.config = {
|
||||
// rest of window config
|
||||
customizationService: [
|
||||
{
|
||||
'panelSegmentation.disableUpdateSegmentationStats': {
|
||||
$set: true, // Disables the automatic update of segmentation statistics in the panel
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
`,
|
||||
},
|
||||
|
||||
Loading…
Reference in New Issue
Block a user