From 4d4374126aba8f40f60fc9e6de4a4dc0c6a21494 Mon Sep 17 00:00:00 2001 From: Steelyard Date: Sun, 29 Jan 2017 14:15:27 +0100 Subject: Dutch added in datamodel and app --- www/js/DataModel.js | 12 ++++-------- www/js/app.js | 19 ++----------------- 2 files changed, 6 insertions(+), 25 deletions(-) mode change 100644 => 100755 www/js/DataModel.js mode change 100644 => 100755 www/js/app.js (limited to 'www/js') diff --git a/www/js/DataModel.js b/www/js/DataModel.js old mode 100644 new mode 100755 index 382f1f36..77e5ae9a --- a/www/js/DataModel.js +++ b/www/js/DataModel.js @@ -45,6 +45,10 @@ angular.module('zmApp.controllers') text: 'Italian', value: 'it' }, + { + text: 'Nederlands', + value: 'nl' + }, { text: 'Polski', value: 'pl' @@ -144,7 +148,6 @@ angular.module('zmApp.controllers') 'fastLogin': true, 'followTimeLine': false, 'timelineScale': -1, - 'hideArchived': false, }; @@ -965,13 +968,6 @@ angular.module('zmApp.controllers') } - if (typeof loginData.hideArchived == 'undefined') - { - - loginData.hideArchived = false; - - } - log("DataModel init recovered this loginData as " + JSON.stringify(loginData)); } else diff --git a/www/js/app.js b/www/js/app.js old mode 100644 new mode 100755 index 4827af11..52b25185 --- a/www/js/app.js +++ b/www/js/app.js @@ -102,22 +102,6 @@ angular.module('zmApp', [ }) -.filter ('eventListFilter', function(NVRDataModel) -{ - return function (input) { - var ld = NVRDataModel.getLogin(); - var out = []; - angular.forEach (input, function (item) - { - if (item.Event.Archived == '0' || !ld.hideArchived) { - out.push(item); - } - }); - return out; - }; - -}) - // filter for montage iteration .filter('onlyEnabled', function() { @@ -1986,7 +1970,7 @@ angular.module('zmApp', [ //$translateProvider.useLocalStorage(); - $translateProvider.registerAvailableLanguageKeys(['en', 'de', 'es', 'fr', 'it', 'ru', 'ja', 'ko', 'pl', 'zh', 'zh_CN', 'zh_TW', 'pt', 'ar', 'hi'], + $translateProvider.registerAvailableLanguageKeys(['en', 'de', 'es', 'fr', 'it', 'ru', 'ja', 'ko', 'nl', 'pl', 'zh', 'zh_CN', 'zh_TW', 'pt', 'ar', 'hi'], { 'en_*': 'en', 'de_*': 'de', @@ -1996,6 +1980,7 @@ angular.module('zmApp', [ 'ru_*': 'ru', 'ja_*': 'ja', 'ko_*': 'ko', + 'nl_*': 'nl', 'pt_*': 'pt', 'pl_*': 'pl', 'ar_*': 'ar', -- cgit v1.2.3 From 79abd405ca4366593b2456e4c5d9aab220d288a1 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Mon, 30 Jan 2017 11:25:13 +0530 Subject: updated files with code that got deleted when I merged the PR #433 --- www/js/DataModel.js | 10 ++++++++++ www/js/app.js | 18 ++++++++++++++++++ 2 files changed, 28 insertions(+) (limited to 'www/js') diff --git a/www/js/DataModel.js b/www/js/DataModel.js index 77e5ae9a..7c46c1d0 100755 --- a/www/js/DataModel.js +++ b/www/js/DataModel.js @@ -148,6 +148,7 @@ angular.module('zmApp.controllers') 'fastLogin': true, 'followTimeLine': false, 'timelineScale': -1, + 'hideArchived': false }; @@ -961,6 +962,8 @@ angular.module('zmApp.controllers') } + + if (typeof loginData.monSingleImageQuality == 'undefined') { @@ -968,6 +971,13 @@ angular.module('zmApp.controllers') } + if (typeof loginData.hideArchived == 'undefined') + { + + loginData.hideArchived = false; + + } + log("DataModel init recovered this loginData as " + JSON.stringify(loginData)); } else diff --git a/www/js/app.js b/www/js/app.js index 52b25185..f7bc5e69 100755 --- a/www/js/app.js +++ b/www/js/app.js @@ -102,6 +102,24 @@ angular.module('zmApp', [ }) + +// for events view +.filter ('eventListFilter', function(NVRDataModel) +{ + return function (input) { + var ld = NVRDataModel.getLogin(); + var out = []; + angular.forEach (input, function (item) + { + if (item.Event.Archived == '0' || !ld.hideArchived) { + out.push(item); + } + }); + return out; + }; + +}) + // filter for montage iteration .filter('onlyEnabled', function() { -- cgit v1.2.3