Пример #1
0
        public void Update()
        {
            LeverancierSQLContext lsc = new LeverancierSQLContext();
            LeverancierRepository lr  = new LeverancierRepository(lsc);
            Leverancier           l   = lr.Retrieve("2");

            l.Naam = l.Naam + "AAngepast";

            lr.Update(l);
        }
Пример #2
0
        public void SaveOrUpdate()
        {
            LeverancierSQLContext lsc = new LeverancierSQLContext();
            LeverancierRepository lr  = new LeverancierRepository(lsc);

            if (Id != 0)
            {
                lr.Update(this);
            }
            else
            {
                lr.Create(this);
            }
        }