public bool Insert(Cargo office) { try { DadosdoCargo.Inserir(office); return true; } catch (Exception e) { throw e; } }
public bool Delete(Cargo office) { try { DadosdoCargo.Excluir(office); return true; } catch (Exception e) { throw e; } }
public bool Alter(Cargo office) { try { DadosdoCargo.Alterar(office); return true; } catch (Exception e) { throw e; } }
//Construtor sem PK public Membro(Cargo Office, Endereco Member_Address, string Name, DateTime Birth_Date, long cpf, int registro_geral, DateTime Register_Date, DateTime Baptism_Date, long Phone, int active, string sex) { Cargo_Membro2 = Office.Cod_Cargo1; Endereco_Membro = Member_Address.Cod_end; Nome = Name; Data_Nascimento = Birth_Date; CPF = cpf; RG = registro_geral; Data_Cadastro = Register_Date; Data_Batismo = Baptism_Date; Telefone = Phone; Ativo = active; Sexo = sex; }
public bool Insert(Cargo Office, Endereco Member_Address, string Name, DateTime Birth_Date, long cpf, int registro_geral, DateTime Register_Date, DateTime Baptism_Date, long Phone, int active, string sex) { Membro member = new Membro(Office, Member_Address, Name, Birth_Date, cpf, registro_geral, Register_Date, Baptism_Date, Phone, active, sex); try { DadosdoMembro.Inserir(member); return true; } catch (Exception e) { throw e; } }
public Membro formamembro(int id,Cargo Office, Endereco Member_Address, string Name, DateTime Birth_Date, long cpf, int registro_geral, DateTime Register_Date, DateTime Baptism_Date, long Phone, int active, string sex) { Membro membro = new Membro(id, Office, Member_Address, Name, Birth_Date, cpf, registro_geral, Register_Date, Baptism_Date, Phone, active, sex); return membro; }