public OrderModel(IMailer mailer)
 {
     _orderDataAccess  = new OrderDataAccess();
     _buyDataAccess    = new BuyDataAccess();
     _clientDataAccess = new ClientDataAccess();
     _orderHelper      = new OrderHelper(mailer);
 }
Exemple #2
0
 public BuyModel()
 {
     _buyDataAccess    = new BuyDataAccess();
     _clientDataAccess = new ClientDataAccess();
     _orderDataAccess  = new OrderDataAccess();
     _orderModel       = new OrderModel();
     _buyHelper        = new BuyHelper();
 }
Exemple #3
0
 public int PostDetail(BuyDetailRequest request)
 {
     try
     {
         BuyDataAccess _dataAccess = new BuyDataAccess();
         _dataAccess.InsertDetail(request);
         //Retorna 204: La peticion ha sido manejada con exito y la respuesta no tiene contenido
         return(204);
     }
     catch (Exception ex)
     {
         Console.WriteLine("BuyModel.PostDetail : ERROR : " + ex.Message);
         //Error interno del servidor
         return(500);
     }
 }