Exemple #1
0
        public void CriarCliente(long userID, string userName)
        {
            using (GccContext db = new GccContext())
            {
                Cliente cliente = new Cliente();
                cliente.UserId = userID;
                cliente.Nome = userName;
                cliente.Endereco = new Endereco();

                db.Clientes.Add(cliente);
                db.SaveChanges();
            }
        }
Exemple #2
0
 public UnitOfWork(GccContext context)
 {
     _context = context;
 }
Exemple #3
0
 public UnitOfWork()
 {
     _context = new GccContext();
 }