Add option to convert non-Targets to CR/NE/EX
This commit is contained in:
1 parent
dbeaba1684
commit
bee1e38044
8 files changed
+122
-13
No files matched your search
+5
@@ -83,6 +83,11 @@ Template.lesionTableTimepointCell.events({
|
||||
var currentTimepointID = this.timepointId;
|
||||
|
||||
var timepointData = currentMeasurement.timepoints[currentTimepointID];
|
||||
|
||||
if (!timepointData) {
|
||||
return;
|
||||
}
|
||||
|
||||
var measurementData = {
|
||||
id: currentMeasurement._id,
|
||||
timepointId: currentTimepointID,
|
||||
|
||||
+11
@@ -61,6 +61,17 @@
|
||||
</div>
|
||||
<div class="locationOK">
|
||||
<button class="btn btn-link" id="removeLesion">Remove</button>
|
||||
<div class="btn-group">
|
||||
<button type="button" class="btn btn-link dropdown-toggle"
|
||||
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
Convert
|
||||
</button>
|
||||
<div class="dropdown-menu">
|
||||
{{ #each conversionOptions }}
|
||||
<a class="btn btn-link dropdown-item convertNonTarget" data-type="{{id}}">{{name}}</a>
|
||||
{{ /each }}
|
||||
</div>
|
||||
</div>
|
||||
<button class="btn btn-primary" id="nonTargetLesionOK">OK</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
+28
-5
@@ -173,11 +173,6 @@ changeNonTargetLocationCallback = function(measurementData, eventData, doneCallb
|
||||
// Make sure the context menu is closed when the user clicks away
|
||||
$('.removableBackdrop').one('mousedown touchstart', function() {
|
||||
closeHandler(dialog);
|
||||
|
||||
if (doneCallback && typeof doneCallback === 'function') {
|
||||
var deleteTool = true;
|
||||
doneCallback(measurementData, deleteTool);
|
||||
}
|
||||
});
|
||||
|
||||
// Find the select option box
|
||||
@@ -320,6 +315,17 @@ Template.nonTargetLesionDialog.events({
|
||||
var dialog = Template.nonTargetLesionDialog.dialog;
|
||||
closeHandler(dialog);
|
||||
},
|
||||
'click a.convertNonTarget': function(evt) {
|
||||
var measurementData = Template.nonTargetLesionDialog.measurementData;
|
||||
var dialog = Template.nonTargetLesionDialog.dialog;
|
||||
|
||||
var button = $(evt.currentTarget);
|
||||
var toolType = button.data('type');
|
||||
|
||||
convertNonTarget(measurementData, toolType);
|
||||
|
||||
closeHandler(dialog);
|
||||
},
|
||||
'keydown #lesionLocationDialog, keydown #lesionLocationRelabelDialog': function(e) {
|
||||
var dialog = Template.nonTargetLesionDialog.dialog;
|
||||
|
||||
@@ -331,11 +337,28 @@ Template.nonTargetLesionDialog.events({
|
||||
}
|
||||
});
|
||||
|
||||
var conversionOptions = [{
|
||||
id: 'bidirectional',
|
||||
name: 'Measurable Target'
|
||||
}, {
|
||||
id: 'crTool',
|
||||
name: 'Complete Response (CR)'
|
||||
}, {
|
||||
id: 'unTool',
|
||||
name: 'Not Evaluable (NE)'
|
||||
}, {
|
||||
id: 'exTool',
|
||||
name: 'Excluded (EX)'
|
||||
}];
|
||||
|
||||
Template.nonTargetLesionDialog.helpers({
|
||||
lesionLocations: function() {
|
||||
return LesionLocations.find();
|
||||
},
|
||||
locationResponses: function() {
|
||||
return LocationResponses.find();
|
||||
},
|
||||
conversionOptions: function() {
|
||||
return conversionOptions;
|
||||
}
|
||||
});
|
||||
Reference in new issue
Block a user