예제 #1
0
        private static void AddMachDir(MachineContents m, DirectoryContents d)
        {
            MachineDir md1 = MachineDir.CreateMachineDir(m.Id, d.Id, d.LocalPath);

            using (filesyncEntitiesNew context = new filesyncEntitiesNew()) {
                context.MachineDirs.AddObject(md1);
                context.SaveChanges();
            }
        }
예제 #2
0
        private static void AddMachDir(MachineModel m, DirModel d)
        {
            MachineDir md1 = MachineDir.CreateMachineDir(m.Id, d.Id, d.Path);

            using (filesyncEntities context = new filesyncEntities())
            {
                context.MachineDirs.AddObject(md1);
                context.SaveChanges();
            }
        }
예제 #3
0
        public static void Add(MachdirModel md)
        {
            MachineDir md1 = MachineDir.CreateMachineDir(1, md.Dir, md.Path);

            using (filesyncEntities context = new filesyncEntities())
            {
                context.MachineDirs.AddObject(md1);
                context.SaveChanges();
            }
        }