public int GetProductValidbyCode([FromBody] string code) { int userDAta = 0; using (ICheckout chk = Factorizador.CrearConexionServicio2(APIUsers.Library.Models.ConnectionType.MSSQL, ConnectionStringLocal)) { userDAta = chk.getProductValidbyCode(code); } return(userDAta); }
public string GetPromotions(int idUser) { string listShopping = ""; using (ICheckout chk = Factorizador.CrearConexionServicio2(APIUsers.Library.Models.ConnectionType.MSSQL, ConnectionStringLocal)) { listShopping = chk.getShoping(idUser); } return(listShopping); }
public int InsertCheckout([FromBody] APIUsers.Library.Models.Checkout value) { int id = 0; using (ICheckout checkout = Factorizador.CrearConexionServicio2(APIUsers.Library.Models.ConnectionType.MSSQL, ConnectionStringLocal)) { id = checkout.InsertCheckout( value.idUser, value.code, value.paymentMethod ); } return(id); }