Exemplo n.º 1
0
        public void Alterar(Entities.tb_benefits ben)
        {
            Entities.tb_benefits tb = db.tb_benefits.First(t => t.id_emp == ben.id_emp);
            tb.bt_transport  = ben.bt_transport;
            tb.bt_food       = ben.bt_food;
            tb.bt_meal       = ben.bt_meal;
            tb.bt_lifeSafe   = ben.bt_lifeSafe;
            tb.bt_planHealth = ben.bt_planHealth;
            tb.bt_planDental = ben.bt_planDental;
            tb.vl_transport  = ben.vl_transport;
            tb.vl_food       = ben.vl_food;
            tb.vl_meal       = ben.vl_meal;
            tb.vl_lifeSafe   = ben.vl_lifeSafe;
            tb.vl_planHealth = ben.vl_planHealth;
            tb.vl_planDental = ben.vl_planDental;

            db.SaveChanges();
        }
Exemplo n.º 2
0
        public void Remover(Entities.tb_benefits ben)
        {
            db.tb_benefits.Remove(ben);

            db.SaveChanges();
        }
Exemplo n.º 3
0
        public void Inserir(Entities.tb_benefits ben)
        {
            db.tb_benefits.Add(ben);

            db.SaveChanges();
        }