/// <summary>
 /// Add update users
 /// </summary>
 /// <param name="searchtheater"></param>
 /// <returns></returns>
 public static int AddEditUser(UserBO user)
 {
     return 0;
     //var context = new MoviesTicketDBEntities();
     //var userdal = new User();
     //if (user.UserId == 0)
     //{
     //    userdal.FirstName = user.FirstName;
     //    userdal.LastName = user.LastName;
     //    userdal.Address = user.Address;
     //    userdal.EmailId = user.EmailId;
     //    context.Users.Add(userdal);
     //    context.SaveChanges();
     //    return 1;
     //}
     //else
     //{
     //    userdal.FirstName = user.FirstName;
     //    userdal.LastName = user.LastName;
     //    userdal.Address = user.Address;
     //    userdal.EmailId = user.EmailId;
     //    userdal.UserId = user.UserId;
     //    context.Entry(user).State = EntityState.Modified;
     //    context.Users.Add(userdal);
     //    context.SaveChanges();
     //    return 1;
     //}
 }
 public bool Post(UserBO updatedUserDetails)
 {
     //Code to update user details in the DB.
     //Since we are using hard coded values for the demo, no sae operation is done here.
     return true;
 }
Exemple #3
0
 public static int AddEditUser(UserBO user)
 {
     return(MovieRepository.AddEditUser(user));
 }
 public static int AddEditUser(UserBO user)
 {
     return MovieRepository.AddEditUser(user);
 }