public void Incluir(ModeloAbastecimento modelo) { if (modelo.IdMotorista == 0) { throw new Exception("O Codigo do Motorista é necessario"); } if (modelo.IdVeiculo == 0) { throw new Exception("O Codigo do Veiculo é necessario"); } if (modelo.IdTpCombustivel == 0) { throw new Exception("O Codigo do Tipo de Combustivel é necessario"); } if (modelo.AbaQtde == 0) { throw new Exception("A Quantidade é necessario"); } if (modelo.AbaValor == 0) { throw new Exception("O Valor é necessario"); } DALAbastecimento DALObj = new DALAbastecimento(conexao); DALObj.Incluir(modelo); }
public DataTable LocalizarData(DateTime data) { DALAbastecimento DALObj = new DALAbastecimento(conexao); return DALObj.LocalizarData(data); }
public void Excluir(int Codigo) { DALAbastecimento DALObj = new DALAbastecimento(conexao); DALObj.Excluir(Codigo); }
public ModeloAbastecimento CarregaModeloAbastecimento(int Codigo) { DALAbastecimento DALObj = new DALAbastecimento(conexao); return DALObj.CarregaModeloAbastecimento(Codigo); }
public DataTable LocalizarCombustivel(string tpcomb) { DALAbastecimento DALObj = new DALAbastecimento(conexao); return DALObj.LocalizarCombustivel(tpcomb); }
public DataTable LocalizarVeiculo(int Veiculo) { DALAbastecimento DALObj = new DALAbastecimento(conexao); return DALObj.LocalizarVeiculo(Veiculo); }
public DataTable LocalizarMotorista(int Motorista) { DALAbastecimento DALObj = new DALAbastecimento(conexao); return DALObj.LocalizarMotorista(Motorista); }