Keeping bidirectional arm selected after moving handles
This commit is contained in:
parent
10a6b2f094
commit
4dcff38a53
@ -1,24 +1,32 @@
|
||||
import { SimpleSchema } from 'meteor/aldeed:simple-schema';
|
||||
import { MeasurementSchemaTypes } from 'meteor/ohif:measurements/both/schema/measurements';
|
||||
// import { OHIF } from 'meteor/ohif:core';
|
||||
|
||||
const CornerstoneHandleSchema = MeasurementSchemaTypes.CornerstoneHandleSchema;
|
||||
const { CornerstoneHandleSchema } = MeasurementSchemaTypes;
|
||||
|
||||
const BidirectionalHandleSchema = new SimpleSchema([CornerstoneHandleSchema, {
|
||||
selected: {
|
||||
type: Boolean,
|
||||
label: 'Selected',
|
||||
optional: true,
|
||||
defaultValue: false
|
||||
}
|
||||
}]);
|
||||
|
||||
const BidirectionalHandlesSchema = new SimpleSchema({
|
||||
start: {
|
||||
type: CornerstoneHandleSchema,
|
||||
type: BidirectionalHandleSchema,
|
||||
label: 'Start'
|
||||
},
|
||||
end: {
|
||||
type: CornerstoneHandleSchema,
|
||||
type: BidirectionalHandleSchema,
|
||||
label: 'End'
|
||||
},
|
||||
perpendicularStart: {
|
||||
type: CornerstoneHandleSchema,
|
||||
type: BidirectionalHandleSchema,
|
||||
label: 'Perpendicular Start'
|
||||
},
|
||||
perpendicularEnd: {
|
||||
type: CornerstoneHandleSchema,
|
||||
type: BidirectionalHandleSchema,
|
||||
label: 'Perpendicular End'
|
||||
},
|
||||
textBox: {
|
||||
|
||||
@ -149,7 +149,7 @@ const CornerstoneViewport = new SimpleSchema({
|
||||
decimal: true,
|
||||
optional: true
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
const InstanceLevelMeasurement = new SimpleSchema([
|
||||
StudyLevelMeasurement,
|
||||
|
||||
@ -113,7 +113,7 @@ class MeasurementHandlers {
|
||||
}
|
||||
|
||||
// Clean the measurement according to the Schema
|
||||
Collection._c2._simpleSchema.clean(measurement);
|
||||
Collection._c2._simpleSchema.clean(_.clone(measurement));
|
||||
|
||||
// Insert the new measurement into the collection
|
||||
Collection.update(measurementId, {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user