Esempio n. 1
0
 public void ResetUser()
 {
     user = new VOUser()
     {
         Token = ""
     };
 }
Esempio n. 2
0
        public bool AuthenticateUser(string id, string pass)
        {
            user = new VOUser()
            {
                Token = "2942340232", Status = "Unavailable",
                Id    = "dsfddsfas233", Role = "Seller"
            };

            return(true);
        }
Esempio n. 3
0
        public bool AuthenticateUser(string id, string pass)
        {
            var response = DAL.AuthenticateUser(id, pass);

            if (response.IsSuccessStatusCode)
            {
                var keyValue = JsonConvert.DeserializeObject <Dictionary <string, string> >(response.Content.ReadAsStringAsync().Result);

                string token = null;

                keyValue.TryGetValue("token", out token);

                user = new VOUser()
                {
                    Token = token
                };

                return(true);
            }
            return(false);
        }
Esempio n. 4
0
 public void ResetUser()
 {
     user = null;
 }