예제 #1
0
        private static void SaveUserLogin(string epLiteId)
        {
            JsonHelper    jsonHelper = new JsonHelper(CommonConstants.USER_FILE);
            var           emp        = new { epLiteId };
            List <object> json       = jsonHelper.Get <object>();

            if (json != null)
            {
                var currentUser = JsonConvert.DeserializeAnonymousType(json.FirstOrDefault().ToString(), emp);
                if (emp.epLiteId != currentUser.epLiteId)
                {
                    jsonHelper.AddDefault <object>(emp);
                }
            }
            else
            {
                jsonHelper.AddDefault <object>(emp);
            }
        }