summaryrefslogtreecommitdiff
path: root/www
diff options
context:
space:
mode:
Diffstat (limited to 'www')
-rw-r--r--www/js/app.js13
-rw-r--r--www/templates/log.html6
2 files changed, 16 insertions, 3 deletions
diff --git a/www/js/app.js b/www/js/app.js
index 6e7b72ed..3abcb634 100644
--- a/www/js/app.js
+++ b/www/js/app.js
@@ -3,6 +3,7 @@
/* global cordova,StatusBar,angular,console */
+var appVersion = "0.0.0";
// core app start stuff
angular.module('zmApp', [
'ionic',
@@ -12,6 +13,7 @@ angular.module('zmApp', [
])
+
//------------------------------------------------------------------
// this directive will be load any time an image completes loading
// via img tags where this directive is added (I am using this in
@@ -220,6 +222,8 @@ angular.module('zmApp', [
console.log("**** DEVICE READY ***");
+
+
$fileLogger.checkFile().then(function(resp) {
if (parseInt(resp.size) > 50000)
{
@@ -240,7 +244,15 @@ angular.module('zmApp', [
$fileLogger.setStorageFilename('zmNinjaLog.txt');
+ if (window.cordova)
+ {
+ cordova.getAppVersion(function(version) {
+ appVersion = version;
+ ZMDataModel.zmLog ("zmNinja Version: " + appVersion);
+ ZMDataModel.setAppVersion(appVersion);
+ });
+ }
setTimeout(function () {
if (window.cordova)
@@ -290,6 +302,7 @@ angular.module('zmApp', [
}
+
}); //platformReady
diff --git a/www/templates/log.html b/www/templates/log.html
index 102877ae..913094d2 100644
--- a/www/templates/log.html
+++ b/www/templates/log.html
@@ -9,8 +9,8 @@
</ion-nav-buttons>
<ion-content class="padding">
- <pre>
- {{zmLog.logString}}
- </pre>
+ <b>zmNinja Version: {{zmAppVersion}}</b><br/>
+ <!-- don't indent here -- its a pre-->
+ <pre>{{zmLog.logString}}</pre>
</ion-content>