Merge branch 'studyDate'

This commit is contained in:
Erik Ziegler committed 2015-11-17 18:36:48 +01:00
commit 7174dfe73f
17 files changed
+146 -44

No files matched your search

+3 -3
View File
@@ -17,6 +17,9 @@ var StudyMetaData = {};
// Create the WorklistTabs collection
WorklistTabs = new Meteor.Collection(null);
// Create the WorklistStudies collection
WorklistStudies = new Meteor.Collection(null);
/**
* Retrieves study metadata using a server call, and fires a callback
* when completed.
@@ -105,9 +108,6 @@ switchToTab = function(contentId) {
studies: [study]
};
// Update the Session variable with the loaded studies
Session.set('studies', data.studies);
// Remove the loading text template that is inside the tab container by default
container.innerHTML = "";
@@ -2,6 +2,7 @@
// This is a client-side only Collection which
// Stores the list of studies in the Worklist
Studies = new Mongo.Collection(null);
PatientStudies = new Mongo.Collection(null);
Template.worklistResult.helpers({
/**
@@ -9,6 +10,6 @@ Template.worklistResult.helpers({
* by Patient name and Study Date in Ascending order.
*/
studies : function() {
return Studies.find({}, {sort: {patientName : 1, studyDate : 1}});
return WorklistStudies.find({}, {sort: {patientName : 1, studyDate : 1}});
}
});
@@ -69,7 +69,7 @@ function search() {
var modality = replaceUndefinedColumnValue($('#modality').val());
// Clear all current studies
Studies.remove({});
WorklistStudies.remove({});
Meteor.call('WorklistSearch', filter, function(error, studies) {
if (!studies) {
@@ -85,7 +85,7 @@ function search() {
(convertStringToStudyDate(study.studyDate) <= new Date(studyDateTo).setHours(0,0,0,0) || !checkTo)) {
// Insert any matching studies into the Studies Collection
Studies.insert(study);
WorklistStudies.insert(study);
}
});
});
+2 -1
View File
@@ -57,7 +57,8 @@ Package.onUse(function (api) {
// Export the global ViewerData object
api.export('ViewerData', 'client');
// Export the WorklistTabs Collection
// Export the Collections
api.export('WorklistTabs', 'client');
api.export('WorklistStudies', 'client');
});