示例#1
0
        public GetBuysSummaryResponse GetBuysSummary()
        {
            var getBuysSummaryResponse = new GetBuysSummaryResponse();

            try
            {
                getBuysSummaryResponse = _buyDataAccess.GetBuysSummary();
            }
            catch (Exception ex)
            {
                Console.WriteLine("BuyModel.GetBuysSummary : ERROR : " + ex.Message);
                //  Error interno del servidor
                throw;
            }
            return(getBuysSummaryResponse);
        }
示例#2
0
 public GetBuysSummaryResponse GetBuysSummary()
 {
     var getBuysSummaryResponse = new GetBuysSummaryResponse();
     try
     {
         var query = from b in context.BuysEntity
                     select b;
         getBuysSummaryResponse.BuysEntites = query.ToList();
     }
     catch (Exception ex)
     {
         Console.WriteLine("BuyDataAccess.GetBuysSummary : ERROR : "+ex.Message);
         throw;
     }
     return getBuysSummaryResponse;
 }