示例#1
0
文件: ESB2db.cs 项目: dsbjax/ESB2.0
        private static void CreateStaticStatusPage()
        {
            var statusPage = new StatusPage()
            {
                Title       = "Status Bar",
                Description = "System Generated Page",
                IsDisplayed = false
            };

            statusPage.StatusPageGroupings.Add(new StatusPageGrouping()
            {
                Title       = "Status Bar Group",
                Description = "System Generated, only one group allowed.",
                IsStatusBar = true
            });

            database.StatusPages.Add(statusPage);

            database.SaveChanges();
        }
示例#2
0
 public static void AddNewStatusPage(StatusPage newPage)
 {
     database.StatusPages.Add(newPage);
     GetAllStatusPages();
 }
示例#3
0
 public static void DeleteStatusPage(StatusPage selectedItem)
 {
     database.StatusPages.Remove(selectedItem);
     GetAllStatusPages();
 }