public async Task <Core.Model.CoreBills> AddBillAsync(Core.Model.CoreBills bills)
        {
            var newBill = Mapper.MapBills(bills);

            _context.Bills.Add(newBill);
            await _context.SaveChangesAsync();

            return Mapper.MapBills(newBill);
        }
 public static Model.Bills MapBills(Core.Model.CoreBills bills)
 {
     return(new Model.Bills
     {
         Id = bills.Id,
         BillDate = bills.BillDate,
         Cost = bills.Cost,
         Location = bills.Location,
         PurchaseName = bills.PurchaseName,
         Quantity = bills.Quantity,
         UserId = bills.UserId,
         //User = MapUsers(bills.CurrentUser)
     });
 }
 public EntityState Changed(Core.Model.CoreBills bills)
 {
     return _context.Entry(bills).State = EntityState.Modified;
 }