public MasterDetailContainerPageDetailViewModel() { var result = BillingCycleData.Summary(); SumCredits = result.Item1.Value; SumDebits = result.Item2.Value; ValueConsolidated = result.Item3; }
public MainPage() { InitializeComponent(); this.BindingContext = new ViewModel.MainPageViewModel(); BillingCycleData.InitializeData(); }
public List <BillingCycle> GetBillingCycles() { var currentMonth = DateTime.Now.ToString("MMMM"); var currentYear = DateTime.Now.Year; var data = new BillingCycleData().GetBillingCycles(); var currentBillingCycle = data.Where(w => w.BillingMonth == currentMonth && w.BillingYear == currentYear).FirstOrDefault(); return(data.Where(w => w.Id < currentBillingCycle.Id + 2).ToList()); }