public ResponseBL DeleteUser(int id) { ResponseBL status = new ResponseBL(); iuser.DeleteCustomer(id); status.Status = "success"; return(status); }
public ResponseBL UpdateProduct(Products values) { ResponseBL status = new ResponseBL(); if (values != null) { details.UpdateProductDAL(values); status.Status = "success"; } else { status.Status = "error"; } return(status); }
public ResponseBL AddProductBL(Products values) { ResponseBL status = new ResponseBL(); if (values != null) { details.AddProducts(values); status.Status = "success"; } else { status.Status = "error"; } return(status); }
public ResponseBL AddToCart(CartView model) { ResponseBL response = new ResponseBL(); if (model != null) { //if (model.quantity == 0) //{ // model.quantity = model.quantity + 1; //} cart.AddToCart(model); response.Status = "success"; } else { response.Status = "error"; } return(response); }
public Object LoginUser(LoginModel customermodel) { ResponseBL response = new ResponseBL(); if (customermodel != null) { var user = iuser.CheckUser(customermodel); if (user != null) { response.Status = "success"; response.obj = user; return(user); } else { response.Status = "Invalid User"; } } else { response.Status = "Error"; } return(response); }