summaryrefslogtreecommitdiff
path: root/www/js
diff options
context:
space:
mode:
authorPliablePixels <pliablepixels@gmail.com>2015-07-03 08:31:13 -0400
committerPliablePixels <pliablepixels@gmail.com>2015-07-03 08:31:13 -0400
commite0ba24662b631394b4076ac39fad970447879f8f (patch)
treea376c7822232389cefe6995d9b06e2ccc527f7f6 /www/js
parent1c137f2b75a18dfc3bfd8b729c58e43974c9ead2 (diff)
Added plugin that picks up version from config.xml and displays in app
Diffstat (limited to 'www/js')
-rw-r--r--www/js/app.js13
1 files changed, 13 insertions, 0 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