예제 #1
0
 public void UpdateManuscriptErrorCategory(Entities.ManuscriptErrorCategory manuscriptErrorCategory)
 {
     manuscriptErrorCategory.ModifiedDateTime     = System.DateTime.Now;
     manuscriptErrorCategory.Status               = 2;
     context.Entry(manuscriptErrorCategory).State = EntityState.Modified;
     context.SaveChanges();
 }
예제 #2
0
        //public List<Entities.ManuscriptErrorCategory> GetManuscriptErrorCategories()
        //{
        //    return context.ManuscriptErrorCategory.ToList<Entities.ManuscriptErrorCategory>();
        //}

        //public List<Entities.ManuscriptErrorCategory> GetManuscriptErrorCategoryList(int manuscriptID)
        //{
        //    var ManuscriptErrorCategoryList = from q in context.ManuscriptErrorCategory
        //                                      where q.ManuscriptID == manuscriptID
        //                                      select q;
        //        return ManuscriptErrorCategoryList.ToList();
        //}

        //public Entities.ManuscriptErrorCategory GetManuscriptErrorCategory(int id)
        //{
        //    return context.ManuscriptErrorCategory.Find(id);
        //}

        public void AddManuscriptErrorCategory(Entities.ManuscriptErrorCategory manuscriptErrorCategory)
        {
            manuscriptErrorCategory.ModifiedDateTime = System.DateTime.Now;
            manuscriptErrorCategory.Status           = 1;
            context.ManuscriptErrorCategory.Add(manuscriptErrorCategory);
            context.SaveChanges();
        }