public AdministrationController(IAdministrationServiceAdapter adapter, InfoDataAdapter infoDataAdapter) { _adapter = adapter; _infoAdapter = infoDataAdapter; Dictionary<int, string> federalDistricts = _infoAdapter.GetFederalDistricts().ToDictionary(x => x.Id, x => x.Title); federalDistricts.Add(0, ""); ViewBag.FederalDistricts = federalDistricts.OrderBy(x => x.Key); ViewBag.FullReport = ""; ViewBag.Consolidate = ""; ViewBag.Summary = ""; ViewBag.Help = ""; ViewBag.Administration = "active"; }
public SummaryController() { _infoAdapter = new InfoDataAdapter(); _summaryAdapter = new SummaryReportAdapter(); Dictionary<int, string> federalDistricts = _infoAdapter.GetFederalDistricts().ToDictionary(x => x.Id, x => x.Title); federalDistricts.Add(0, "Все округа"); ViewBag.FederalDistricts = federalDistricts.OrderBy(x => x.Key); ViewBag.EndDate = DateTime.Now.ToShortDateString(); ViewBag.FullReport = ""; ViewBag.Consolidate = ""; ViewBag.Summary = "active"; ViewBag.Administration = ""; ViewBag.Help = ""; }