protected override void Seed(TicketDeskContext context) { var demoMode = ConfigurationManager.AppSettings["ticketdesk:DemoModeEnabled"]; if (!string.IsNullOrEmpty(demoMode) && demoMode.Equals("true", StringComparison.InvariantCultureIgnoreCase)) { DemoDataManager.SetupDemoData(context); } base.Seed(context); }
protected override void Seed(TdDomainContext context) { var demoMode = ConfigurationManager.AppSettings["ticketdesk:DemoModeEnabled"]; if (!context.Projects.Any()) { context.Projects.Add(new Project() { ProjectName = "Default", ProjectDescription = "Default project" }); } if (!string.IsNullOrEmpty(demoMode) && demoMode.Equals("true", StringComparison.InvariantCultureIgnoreCase)) { DemoDataManager.SetupDemoData(context); } base.Seed(context); }