From c652eda24f3caa446815194f32b78d049fa99076 Mon Sep 17 00:00:00 2001 From: Arjun Roychowdhury Date: Sat, 14 Nov 2015 14:17:25 -0500 Subject: Initial commits - #83 Former-commit-id: 2ee7fa15e0bd6964a5437a537aa4ebca5c0428c9 --- www/js/DataModel.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'www/js/DataModel.js') diff --git a/www/js/DataModel.js b/www/js/DataModel.js index f948e38b..9f6b6451 100644 --- a/www/js/DataModel.js +++ b/www/js/DataModel.js @@ -27,6 +27,7 @@ angular.module('zmApp.controllers') var serverGroupList={}; var loginData = { + 'serverName':'', 'username': '', 'password': '', 'url': '', // This is the ZM portal path @@ -107,7 +108,7 @@ angular.module('zmApp.controllers') zmDebug ("DataModel/setLogin: writing " + JSON.stringify(newLogin)); $localstorage.setObject($rootScope.currentServerGroup, loginData); - serverGroupList[$rootScope.currentServerGroup]=loginData; + serverGroupList[loginData.serverName]=loginData; console.log (JSON.stringify(serverGroupList)); $localstorage.setObject("serverlist", serverGroupList); -- cgit v1.2.3