From 37f6e07ed6c16cb234fca3b275632c4471dc3979 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Fri, 15 May 2020 08:04:48 -0400 Subject: make sure we don't block transition for first use --- www/js/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/js/app.js b/www/js/app.js index 3dde24f1..bcdbc93f 100755 --- a/www/js/app.js +++ b/www/js/app.js @@ -1520,7 +1520,7 @@ angular.module('zmApp', [ $rootScope.$on('$stateChangeStart', function (event, toState, toParams) { - if (!$rootScope.initComplete) { + if (!$rootScope.initComplete && (toState!= 'app.first-use')) { NVR.debug ("---> Init not complete, ignoring state change request to "+toState.name); event.preventDefault(); return; -- cgit v1.2.3 From 5b1501766521b0c8685840f454793087021216d6 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Fri, 15 May 2020 08:05:36 -0400 Subject: typo --- www/js/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/js/app.js b/www/js/app.js index bcdbc93f..eefaa7e5 100755 --- a/www/js/app.js +++ b/www/js/app.js @@ -1520,7 +1520,7 @@ angular.module('zmApp', [ $rootScope.$on('$stateChangeStart', function (event, toState, toParams) { - if (!$rootScope.initComplete && (toState!= 'app.first-use')) { + if (!$rootScope.initComplete && (toState.name!= 'app.first-use')) { NVR.debug ("---> Init not complete, ignoring state change request to "+toState.name); event.preventDefault(); return; -- cgit v1.2.3 From cbc4c1c188e138040174ee9380c5ac264cf76cb5 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Fri, 15 May 2020 08:14:02 -0400 Subject: for first time init, make sure we don't block --- www/js/app.js | 1 + 1 file changed, 1 insertion(+) diff --git a/www/js/app.js b/www/js/app.js index eefaa7e5..baf51648 100755 --- a/www/js/app.js +++ b/www/js/app.js @@ -1832,6 +1832,7 @@ angular.module('zmApp', [ NVR.debug("isFirstUse returned: " + val); if (val == null || val == true) { NVR.log("First time detected "); + $rootScope.initComplete = true; $state.go("app.first-use"); return; -- cgit v1.2.3 From fc032910b1f418db1eb4ad30907808c98be25f92 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Fri, 15 May 2020 08:14:08 -0400 Subject: null check --- www/js/NVR.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/www/js/NVR.js b/www/js/NVR.js index c09c37f0..46669659 100644 --- a/www/js/NVR.js +++ b/www/js/NVR.js @@ -1898,8 +1898,11 @@ angular.module('zmApp.controllers') insertSpecialTokens: function () { var tokens = ''; - var cid = loginData.zmNinjaCustomId.replace('%APPVER%', zmAppVersion); - tokens+='&id='+cid; + if (loginData.zmNinjaCustomId) { + var cid = loginData.zmNinjaCustomId.replace('%APPVER%', zmAppVersion); + tokens+='&id='+cid; + } + if (loginData.insertBasicAuthToken && $rootScope.basicAuthToken) { tokens += "&basicauth=" + $rootScope.basicAuthToken; } -- cgit v1.2.3 From 0bdb6d2e7bc36a39d3f1d11a8e11f1fa2c8f9b41 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Sun, 17 May 2020 17:26:18 -0400 Subject: nits --- config.xml | 3 --- electron_js/main.js | 1 + package.json | 8 ++------ www/js/NVR.js | 2 +- 4 files changed, 4 insertions(+), 10 deletions(-) diff --git a/config.xml b/config.xml index 852f3fc2..080e6502 100644 --- a/config.xml +++ b/config.xml @@ -186,9 +186,6 @@ - - - diff --git a/electron_js/main.js b/electron_js/main.js index 50d86d89..defa006d 100644 --- a/electron_js/main.js +++ b/electron_js/main.js @@ -33,6 +33,7 @@ if (argv.lang) { // be closed automatically when the JavaScript object is garbage collected. let win; app.commandLine.appendSwitch ('ignore-certificate-errors', 'true'); +app.commandLine.appendArgument('no-sandbox'); const gotTheLock = app.requestSingleInstanceLock() diff --git a/package.json b/package.json index 04a1ba1d..e1dc2a80 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "zmninjapro", "description": "Home security mobile app for ZoneMinder", - "version": "1.4.006", + "version":"1.4.007", "displayName": "zmNinja", "author": "Pliable Pixels", "license": "custom see LICENSE.md", @@ -61,9 +61,6 @@ "cordova-plugin-inappbrowser": {}, "cordova-plugin-app-version": {}, "cordova-plugin-statusbar-pp-fork": {}, - "cordova-plugin-ionic-webview": { - "ANDROID_SUPPORT_ANNOTATIONS_VERSION": "27.+" - }, "cordova-plugin-media-pp-fork": {} } }, @@ -89,7 +86,6 @@ "cordova-plugin-inappbrowser": "git+https://github.com/apache/cordova-plugin-inappbrowser.git", "cordova-plugin-insomnia": "^4.3.0", "cordova-plugin-ionic-keyboard": "2.2.0", - "cordova-plugin-ionic-webview": "git+https://github.com/pliablepixels/cordova-plugin-ionic-webview.git", "cordova-plugin-media-pp-fork": "^1.0.2-dev", "cordova-plugin-multi-window": "0.0.3", "cordova-plugin-network-information": "^2.0.2", @@ -228,4 +224,4 @@ ] } } -} \ No newline at end of file +} diff --git a/www/js/NVR.js b/www/js/NVR.js index 46669659..5af67a8c 100644 --- a/www/js/NVR.js +++ b/www/js/NVR.js @@ -21,7 +21,7 @@ angular.module('zmApp.controllers') DO NOT TOUCH zmAppVersion It is changed by sync_version.sh */ - var zmAppVersion = "1.4.006"; + var zmAppVersion = "1.4.007"; var isBackground = false; var justResumed = false; -- cgit v1.2.3