Exemple #1
0
 public Boolean RemoveGroup(Screengroups groupName)
 {
     InitDB();
     using (var session = documentStore.OpenSession())
     {
         Screengroups deleteGroup = new Screengroups();
         deleteGroup = session.Load<Screengroups>(groupName.Id);
         session.Delete(deleteGroup);
         session.SaveChanges();
         return true;
     }
     return false;
 }
Exemple #2
0
 public Boolean InsertScreenGroup(Screengroups scrg)
 {
     InitDB();
     using (var session = documentStore.OpenSession())
     {
         Screengroups l = new Screengroups();
         l.Name = scrg.Name;
         l.Description = scrg.Description;
         session.Store(l);
         session.SaveChanges();
         return true;
     }
     return false;
 }