public Dashboard(DateTime date, string period) { SelectedYear = null; Period = period; SelectedMonth = date; SalesInformation = new SalesInfo(date); Initialize(); }
public Dashboard(string year, string period) { if (!string.IsNullOrEmpty(year)) { SelectedYear = year; } else { SelectedYear = DateTime.Now.Year.ToString(); } Period = period; SelectedMonth = DateTime.Now; SalesInformation = new SalesInfo(int.Parse(SelectedYear)); Initialize(); }