public int AddPartTask(int taskid, string[] ids)
        {
            DALT_Event_StuClassTask dal = new DALT_Event_StuClassTask();

            foreach (string id in ids)
            {
                T_Event_StuClassTask item = new T_Event_StuClassTask();
                item.ClassTaskId = taskid;
                item.StuId       = Convert.ToInt32(id);

                dal.Add(item);
            }

            return(1);
        }
        //获取所有该班级日程的学生
        public string GetStus(int taskid)
        {
            DALT_Event_StuClassTask dal = new DALT_Event_StuClassTask();

            string where = "ClassTaskId = " + taskid;
            List <T_Event_StuClassTask> lst = dal.GetAllList(where);

            string res = "";

            foreach (T_Event_StuClassTask item in lst)
            {
                res += item.StuId + ",";
            }

            res = res.Substring(0, res.LastIndexOf(","));

            return(res);
        }
        public int EditPartTask(int taskid, string[] ids)
        {
            DALT_Event_StuClassTask dal = new DALT_Event_StuClassTask();

            string where = "ClassTaskId = " + taskid;
            dal.DeleteWhere(where);

            foreach (string id in ids)
            {
                T_Event_StuClassTask item = new T_Event_StuClassTask();
                item.ClassTaskId = taskid;
                item.StuId       = Convert.ToInt32(id);

                dal.Add(item);
            }

            return(1);
        }