diff --git a/app/models/notice.rb b/app/models/notice.rb
index 12b0e08..9d3b43b 100644
--- a/app/models/notice.rb
+++ b/app/models/notice.rb
@@ -119,6 +119,12 @@ class Notice
end
end
+ def app_version
+ if server_environment
+ server_environment['app-version'] || ''
+ end
+ end
+
protected
def decrease_counter_cache
diff --git a/app/views/notices/_summary.html.haml b/app/views/notices/_summary.html.haml
index f832ef0..1ca6d54 100644
--- a/app/views/notices/_summary.html.haml
+++ b/app/views/notices/_summary.html.haml
@@ -25,9 +25,14 @@
%tr
%th Tenant
%td= tenant_graph(problem)
- %tr
- %th App Server
- %td= notice.server_environment && notice.server_environment["hostname"]
+ - if notice.server_environment && notice.server_environment["hostname"]
+ %tr
+ %th App Server
+ %td= notice.server_environment && notice.server_environment["hostname"]
+ - if notice.app_version.present?
+ %tr
+ %th App Version
+ %td= notice.app_version
- if notice.framework
%tr
%th Framework
diff --git a/public/javascripts/notifier.js b/public/javascripts/notifier.js
index 850d1a8..085c042 100644
--- a/public/javascripts/notifier.js
+++ b/public/javascripts/notifier.js
@@ -514,6 +514,7 @@ printStackTrace.implementation.prototype = {
'' +
'{project_root}' +
'{environment}' +
+ '{appVersion}' +
'' +
'' +
'{user_id}' +
@@ -551,10 +552,11 @@ printStackTrace.implementation.prototype = {
"url": "{request_url}",
"rootDirectory": "{project_root}",
"action": "{request_action}",
+ "app-version": "{appVersion}",
- "userId": "{user_id}",
- "userName": "{user_name}",
- "userEmail": "{user_email}",
+ "userId": "{user_id}",
+ "userName": "{user_name}",
+ "userEmail": "{user_email}",
},
"environment": {},
//"session": "",
@@ -859,6 +861,9 @@ printStackTrace.implementation.prototype = {
stack: e.stack
});
})
+ }, {
+ variable: 'appVersion',
+ namespace: 'xmlData'
}
];
--
libgit2 0.21.2