public PartialViewResult SeminarItems(int ParentID, string delete, int Id = 0)
        {
            if (delete == "CoreTopic")
                db.deleteSeminarCoreTopic(Id);
            else if (delete == "Task")
                db.deleteSeminarTask(Id);

            ListViewModel coretopics = null;
            ListViewModel tasks = null;

            if (delete == "CoreTopic" || delete == null)
            {
                coretopics = new ListViewModel()
                {
                    Items = db.getCoreTopics().Where(ct => ct.SeminarID == ParentID).
                    Select(ct => new ListItem() { Id = ct.CoreTopicID, Name = ct.CoreTopicNum + " " + ct.CoreTopicDesc}),
                    Entity = "CoreTopic",
                    createAction = "createSeminarCoreTopic",
                    deleteAction = "SeminarItems",
                    editAction = "editCoreTopic"
                };
            }

            if (delete == "Task" || delete == null)
            {
                tasks = new ListViewModel()
                {
                    Items = db.getTasks().Where(t => t.SeminarID == ParentID).
                    Select(t => new ListItem() { Id = t.TaskID, Name = t.TaskCode + ": " + t.TaskName }),
                    Entity = "Task",
                    createAction = "createSeminarTask",
                    deleteAction = "SeminarItems",
                    editAction = "editTask",
                };
            }

            ChildViewModel model = new ChildViewModel()
            {
                ParentID = ParentID,
                Items = new List<ListViewModel>() { coretopics, tasks }
            };

            return PartialView("ChildPanel", model);
        }
        public PartialViewResult ProgramItems(int ParentID, string delete, int Id = 0)
        {
            if (delete == "Cohort")
                db.deleteProgramCohort(Id);
            else if (delete == "Seminar")
                db.deleteProgramSeminar(Id);

            ListViewModel cohorts = null;
            ListViewModel seminars = null;

            if(delete == "Cohort" || delete == null)
            {
                cohorts = new ListViewModel()
                {
                    Items = db.getCohorts().Where(pc => pc.ProgramID == ParentID).
                    Select(pc => new ListItem() { Id = pc.ProgramCohortID, Name = pc.Program.ProgramTitle + " " + pc.AcademicYear }),
                    Entity = "Cohort",
                    createAction = "createProgramCohort",
                    deleteAction = "ProgramItems",
                    editAction = "createProgramCohort"
                };
            }

            if(delete == "Seminar" || delete == null)
            {
                seminars = new ListViewModel()
                {
                    Items = db.getSeminars().Where(s => s.ProgramID == ParentID).
                    Select(s => new ListItem() { Id = s.SeminarID, Name = s.SeminarTitle }),
                    Entity = "Seminar",
                    createAction = "createProgramSeminar",
                    deleteAction = "ProgramItems",
                    editAction = "createProgramSeminar",
                };
            }

            ChildViewModel model = new ChildViewModel()
            {
                ParentID = ParentID,
                Items = new List<ListViewModel>() { cohorts, seminars }
            };

            return PartialView("ChildPanel", model);
        }