示例#1
0
        public bool ChangeClassDate(ClassDate classdate, EntityState state)
        {
            var entry = db.Entry <ClassDate>(classdate);

            entry.State = state;
            return(db.SaveChanges() > 0);
        }
示例#2
0
 public bool InsertClassDate(ClassDate classdate)
 {
     db.ClassDates.Add(classdate);
     return(db.SaveChanges() > 0);
 }