delete the measurement in measurement-list but still showing in on image.
I want to remove all the measurements. How can I delete from on Images?
I try to this code.
var toolsGrops = OHIF.measurements.MeasurementApi.Instance.tools;
Object.entries(toolsGrops).forEach(([key, tooldata]) => {
if (tooldata.length > 0) {
tooldata.forEach(tool => {
var toolType = tool.toolType;
var toolId = tool.toolType;
measurementApi.deleteMeasurements(toolType, eventData.measurementTypeId, { toolId });
});
}
});
Please anyone help me what i wrong and how can I solve this issue.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
@Vishal568, I don't know that there's a great way to do this currently. If you use the cornerstone tools API to remove the toolstate, it should emit the proper event that would cause the measurement to be deleted from the Measurement's Panel as well?
What we really need is a Measurements Service that the cornerstone extension updates, and the Measurements Panel reads from.