public HttpResponseMessage updateloginDetail(Login login)
        {
            try
            {
                return Request.CreateResponse(HttpStatusCode.OK, _repo.Updatelogin(login));
            }
            catch (Exception)
            {

                return Request.CreateResponse(HttpStatusCode.BadRequest);
            }
        }
        public bool Updatelogin(Login LoginObj)
        {
            try
            {
                Login newlogin = _context.Logins.Where(x => x.LoginId == LoginObj.LoginId).FirstOrDefault();
                if (newlogin != null)
                {
                    newlogin = LoginObj;
                    _context.Entry(newlogin).State = System.Data.Entity.EntityState.Modified;
                    SaveContext();
                    return true;
                }
                return false;
            }
            catch (Exception)
            {

                throw;
            }
        }
        public Login Getlogin(Login obj)
        {
            try
            {
                return _context.Logins.Where(x => x.UserName == obj.UserName && x.Password == obj.Password).FirstOrDefault();
            }
            catch (Exception)
            {

                throw;
            }
        }
        public Login Addlogin(Login LoginObj)
        {
            try
            {
                LoginObj.CreatedDate = DateTime.Now;
                LoginObj.ModifiedDate = DateTime.Now;
                _context.Logins.Add(LoginObj);
                SaveContext();
                return LoginObj;
            }
            catch (Exception)
            {

                throw;
            }
        }