public List <MoneyUsage> GetAccountingDataList()
        {
            var result = new List <MoneyUsage>();

            using (var db = new AccountBookDbContext())
            {
                var query = db.AccountBook.Select(s => new MoneyUsage()
                {
                    CostType = ((CostCategoryEnum)s.Categoryyy).ToString(),
                    CostDate = s.Dateee,
                    Amount   = s.Amounttt
                });

                result = query.ToList();
            }

            return(result);
        }
Exemplo n.º 2
0
 public BooksResult()
 {
     this.db = new AccountBookDbContext();
 }