diff --git a/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.html b/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.html
index 9ea39789f..e24036ac0 100644
--- a/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.html
+++ b/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.html
@@ -16,7 +16,7 @@
{{entryTimestamp}}
- {{userName}} initialized HIPAA Audit Log.
+ {{userName}} initialized HIPAA Audit Log.
@@ -60,7 +60,7 @@
{{entryTimestamp}}
{{#if hasPatientInfo}}
-
{{userName}} modified record
{{getRecordId}} in the
{{getCollectionName}} collection, regarding patient
{{getPatientName}}.
+
{{userName}} modified record
{{getRecordId}} in the
{{getCollectionName}} collection, regarding patient
{{getPatientName}}.
{{else}}
{{userName}} modified record
{{getRecordId}} in the
{{getCollectionName}} collection.
{{/if}}
@@ -77,7 +77,7 @@
{{entryTimestamp}}
- {{userName}} cloned record {{getRecordId}} in the {{getCollectionName}} collection.
+ {{userName}} cloned record {{getRecordId}} in the {{getCollectionName}} collection.
@@ -90,7 +90,7 @@
{{entryTimestamp}}
- {{userName}} deleted record {{getRecordId}} in the {{getCollectionName}} collection.
+ {{userName}} deleted record {{getRecordId}} in the {{getCollectionName}} collection.
@@ -103,7 +103,7 @@
{{entryTimestamp}}
- {{userName}} was denied access to record {{getRecordId}} in the {{getCollectionName}} collection.
+ {{userName}} was denied access to record {{getRecordId}} in the {{getCollectionName}} collection.
@@ -117,9 +117,9 @@
{{entryTimestamp}}
{{#if hasPatientInfo}}
- {{userName}} viewed record {{getRecordId}} in the {{getCollectionName}} collection, regarding patient {{getPatientName}}.
+ {{userName}} viewed record {{getRecordId}} in the {{getCollectionName}} collection, regarding patient {{getPatientName}}.
{{else}}
- {{userName}} viewed record {{getRecordId}} in the {{getCollectionName}} collection.
+ {{userName}} viewed record {{getRecordId}} in the {{getCollectionName}} collection.
{{/if}}
@@ -133,7 +133,7 @@
{{entryTimestamp}}
- {{userName}} published record {{getRecordId}} in the {{getCollectionName}} collection.
+ {{userName}} published record {{getRecordId}} in the {{getCollectionName}} collection.
@@ -146,7 +146,7 @@
{{entryTimestamp}}
- {{userName}} unpublished record {{getRecordId}} in the {{getCollectionName}} collection.
+ {{userName}} unpublished record {{getRecordId}} in the {{getCollectionName}} collection.
@@ -159,7 +159,7 @@
{{entryTimestamp}}
- {{userName}} received a data access error while performing an action!
+ {{userName}} received a data access error while performing an action!
{{getErrorMessage}}
diff --git a/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.js b/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.js
index acd458a9b..ffe8fc177 100644
--- a/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.js
+++ b/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.js
@@ -20,7 +20,7 @@ Template.hipaaAuditLog.helpers({
},
hipaaAudit: function () {
// return HipaaLog.find();
- return HipaaLog.find({
+ return HipaaLog.find({
$or: [
{
userName: {
@@ -33,6 +33,18 @@ Template.hipaaAuditLog.helpers({
$regex: Session.get('hipaaSearchFilter'),
$options: 'i'
}
+ },
+ {
+ recordId: {
+ $regex: Session.get('hipaaSearchFilter'),
+ $options: 'i'
+ }
+ },
+ {
+ collectionName: {
+ $regex: Session.get('hipaaSearchFilter'),
+ $options: 'i'
+ }
}
],
eventType: {
@@ -54,6 +66,23 @@ Template.hipaaAuditLog.helpers({
Template.hipaaAuditLog.events({
"keyup #hipaaSearchFilter": function (event, template) {
Session.set("hipaaSearchFilter", $('#hipaaSearchFilter').val());
+ },
+ "click .userName": function(event, template) {
+ var userName = $(event.currentTarget).text();
+ Session.set('hipaaSearchFilter', userName);
+ },
+ "click .patientName": function(event, template) {
+ var patientName = $(event.currentTarget).text();
+ var patientNameRegex = patientName.replace(/[!@#$%^&*()+=\-[\]\\';,./{}|":<>?~_]/g, "\\$&");
+ Session.set('hipaaSearchFilter', patientNameRegex);
+ },
+ "click .mongoRecordId": function(event, template) {
+ var mongoRecordId = $(event.currentTarget).text();
+ Session.set('hipaaSearchFilter', mongoRecordId);
+ },
+ "click .collectionName": function(event, template) {
+ var collectionName = $(event.currentTarget).text();
+ Session.set('hipaaSearchFilter', collectionName);
}
});
diff --git a/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.less b/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.less
index 0d902457e..e600a3850 100644
--- a/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.less
+++ b/Packages/hipaa-audit-log/components/hipaaAuditLog/hipaaAuditLog.less
@@ -70,5 +70,9 @@
width: 100%;
}
+ .userName, .patientName, .mongoRecordId, .collectionName{
+ cursor: pointer;
+ }
+
}
diff --git a/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.html b/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.html
index c0a38264a..076b5e387 100644
--- a/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.html
+++ b/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.html
@@ -1,13 +1,17 @@
diff --git a/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.js b/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.js
index 01f38cc6f..fa5dffc3b 100644
--- a/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.js
+++ b/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.js
@@ -8,7 +8,10 @@ Template.hipaaRibbon.events({
"change #endDateInput": function (event, template) {
Session.set("endDateFilter", $('#endDateInput').val() + "T00:00:00.000Z");
},
-
+ 'change #actionFilter': function(e) {
+ var actionType = e.currentTarget.value;
+ Session.set("hipaaTypeFilter", actionType);
+ },
'click #filterCreatedButton': function () {
Session.set("hipaaTypeFilter", 'create');
},
@@ -20,6 +23,9 @@ Template.hipaaRibbon.events({
},
'click #filterAllButton': function () {
Session.set("hipaaTypeFilter", '');
+ },
+ 'click #searchClear': function() {
+ Session.set("hipaaSearchFilter", '');
}
});
diff --git a/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.less b/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.less
index f4beb9abf..001c3bd62 100644
--- a/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.less
+++ b/Packages/hipaa-audit-log/components/hipaaRibbon/hipaaRibbon.less
@@ -28,6 +28,17 @@
.form-control{
display: inline-block !important;
}
+ #searchClear {
+ position: absolute;
+ right: 14px;
+ top: 0;
+ bottom: 0;
+ height: 14px;
+ margin: auto;
+ font-size: 14px;
+ cursor: pointer;
+ color: #ccc;
+ }
}
// @media only screen and (max-width: 850px) {