Advertisement
Guest User

Untitled

a guest
Nov 17th, 2017
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.93 KB | None | 0 0
  1. package com.conceito.frota.controller;
  2.  
  3. import java.io.File;
  4. import java.io.FileInputStream;
  5. import java.io.FileNotFoundException;
  6. import java.io.InputStream;
  7. import java.util.Date;
  8. import java.util.HashMap;
  9.  
  10. import javax.faces.bean.ManagedBean;
  11. import javax.faces.bean.ManagedProperty;
  12. import javax.faces.bean.ViewScoped;
  13. import javax.faces.component.UIComponent;
  14. import javax.faces.context.FacesContext;
  15.  
  16. import org.apache.poi.ss.usermodel.Cell;
  17. import org.apache.poi.ss.usermodel.FormulaEvaluator;
  18. import org.apache.poi.ss.usermodel.Row;
  19. import org.apache.poi.ss.usermodel.Sheet;
  20. import org.apache.poi.ss.usermodel.Workbook;
  21. import org.apache.poi.ss.usermodel.WorkbookFactory;
  22.  
  23. import com.conceito.common.controller.GenericDynamicDataTablePaginatorCrudControllerImpl;
  24. import com.conceito.common.model.Cliente;
  25. import com.conceito.frota.model.Abastecimento;
  26. import com.conceito.frota.model.Combustivel;
  27. import com.conceito.frota.model.Modelo;
  28. import com.conceito.frota.model.Motorista;
  29. import com.conceito.frota.model.Veiculo;
  30. import com.conceito.frota.service.AbastecimentoService;
  31. import com.conceito.frota.service.CombustivelService;
  32. import com.conceito.frota.service.ModeloService;
  33. import com.conceito.frota.service.VeiculoService;
  34. import com.conceito.staff.model.Setor;
  35. import com.conceito.util.FacesUtil;
  36. import com.conceito.util.Formatador;
  37. import com.conceito.util.ReportUtil;
  38. import com.conceito.util.backbeanutil.QueryControl;
  39. import com.conceito.util.dataFilter.TypeOrder;
  40.  
  41. @ManagedBean(name="abastecimentoController")
  42. @ViewScoped
  43. public class AbastecimentoController extends GenericDynamicDataTablePaginatorCrudControllerImpl<Abastecimento>{
  44.  
  45. private static final long serialVersionUID = 1L;
  46.  
  47. @ManagedProperty(name="abastecimentoService", value="#{abastecimentoService}")
  48. private AbastecimentoService abastecimentoService;
  49.  
  50. @ManagedProperty(name="modeloService", value="#{modeloService}")
  51. private ModeloService modeloService;
  52.  
  53. @ManagedProperty(name="veiculoService", value="#{veiculoService}")
  54. private VeiculoService veiculoService;
  55.  
  56. @ManagedProperty(name="combustivelService", value="#{combustivelService}")
  57. private CombustivelService combustivelService;
  58.  
  59. private Date dataInicial;
  60. private Date dataFinal;
  61. private Date dataInicio;
  62. private Date dataFim;
  63. private String placaRelatorio;
  64. private Combustivel combustivelRelatorio;
  65. private Motorista motoristaRelatorio;
  66. private Setor setorRelatorio;
  67. private boolean renderedEscolherPeriodo;
  68. private boolean renderedEscolherFiltro;
  69. private String acompanhamentoPor = "1";
  70. private boolean renderedEscolherRelatorio;
  71. private String tipoRelatorio = "1";
  72. private QueryControl queryMotoristas;
  73. private QueryControl queryVeiculo;
  74. private QueryControl queryCombustivel;
  75.  
  76. public void migrarAbastecimentos(InputStream inputstream) throws Exception {
  77. QueryControl qc = new QueryControl(Cliente.class, this.getQueryService());
  78. qc.getDataFilter().addEq("id", new Long(106), false);
  79. qc.atualizarList();
  80.  
  81. Cliente cliente = null;
  82.  
  83. if(qc.getList().size() > 0) {
  84. cliente = (Cliente)qc.getList().get(0);
  85. }else {
  86. return;
  87. }
  88.  
  89. Workbook excel = WorkbookFactory.create(inputstream);
  90.  
  91. inputstream.close();
  92.  
  93. int numeroPlanilhas = excel.getNumberOfSheets();
  94.  
  95. for(int p = 0; p < numeroPlanilhas; p++) {
  96. Sheet planilha = excel.getSheetAt(p);
  97.  
  98. if(planilha == null) {
  99. throw new Exception("Planilha não encontrada");
  100. }
  101.  
  102. System.err.println("imax = " + planilha.getLastRowNum());
  103.  
  104. for(int i = 1; i < planilha.getLastRowNum(); i++) {
  105. Row linha = planilha.getRow(i);
  106.  
  107. if(linha == null) {
  108. break;
  109. }
  110.  
  111. FormulaEvaluator evaluator = excel.getCreationHelper().createFormulaEvaluator();
  112.  
  113. String modeloTexto = this.getValorCelula(evaluator, linha.getCell(0));
  114.  
  115. if(modeloTexto == null || modeloTexto.equals("")) {
  116. System.err.println("i = " + i);
  117. return;
  118. }
  119.  
  120. String placaTexto = this.getValorCelula(evaluator, linha.getCell(1));
  121. String combustivelTexto = this.getValorCelula(evaluator, linha.getCell(2));
  122. double litros = Double.parseDouble(this.getValorCelula(evaluator, linha.getCell(3)));
  123. double valor = Double.parseDouble(this.getValorCelula(evaluator, linha.getCell(4)));
  124. String setorTexto = this.getValorCelula(evaluator, linha.getCell(5));
  125. Date data = linha.getCell(6).getDateCellValue();
  126. //Date data = Formatador.toDate(this.getValorCelula(evaluator, linha.getCell(6)));
  127.  
  128. qc = new QueryControl(Setor.class, this.getQueryService());
  129. qc.getDataFilter().addEq("cliente.id", cliente.getId(), false);
  130. qc.getDataFilter().addEq("nome", setorTexto, false);
  131. qc.atualizarList();
  132.  
  133. Setor setor = null;
  134.  
  135. if(qc.getList().size() > 0) {
  136. setor = (Setor)qc.getList().get(0);
  137.  
  138. qc = new QueryControl(Combustivel.class, this.getQueryService());
  139. qc.getDataFilter().addEq("nome", combustivelTexto, false);
  140. qc.atualizarList();
  141.  
  142. Combustivel combustivel = null;
  143.  
  144. if(qc.getList().size() > 0) {
  145. combustivel = (Combustivel)qc.getList().get(0);
  146.  
  147. qc = new QueryControl(Modelo.class, this.getQueryService());
  148. qc.getDataFilter().addEq("nome", modeloTexto, false);
  149. qc.atualizarList();
  150.  
  151. Modelo modelo = null;
  152.  
  153. if(qc.getList().size() > 0) {
  154. modelo = (Modelo)qc.getList().get(0);
  155. }else {
  156. modelo = new Modelo();
  157. modelo.setNome(modeloTexto);
  158. modelo.setCombustivel(combustivel);
  159. this.getModeloService().save(modelo);
  160.  
  161. System.out.println("Modelo \"" + modeloTexto + "\" salvo com sucesso");
  162. }
  163.  
  164. qc = new QueryControl(Veiculo.class, this.getQueryService());
  165. qc.getDataFilter().addEq("cliente.id", cliente.getId(), false);
  166. qc.getDataFilter().addEq("modelo.id", modelo.getId(), false);
  167. qc.getDataFilter().addEq("placa", placaTexto, false);
  168. qc.atualizarList();
  169.  
  170. Veiculo veiculo = null;
  171.  
  172. if(qc.getList().size() > 0) {
  173. veiculo = (Veiculo)qc.getList().get(0);
  174. }else {
  175. veiculo = new Veiculo();
  176. veiculo.setModelo(modelo);
  177. veiculo.setPlaca(placaTexto);
  178. veiculo.setSetor(setor);
  179. veiculo.setCliente(cliente);
  180. this.getVeiculoService().save(veiculo);
  181.  
  182. System.out.println("Veículo \"" + placaTexto + "\" salvo com sucesso");
  183. }
  184.  
  185. qc = new QueryControl(Abastecimento.class, this.getQueryService());
  186. qc.getDataFilter().addEq("valor", valor, false);
  187. qc.getDataFilter().addEq("quantidadeLitros", litros, false);
  188. qc.getDataFilter().addEq("veiculo.id", veiculo.getId(), false);
  189. qc.getDataFilter().addEq("combustivel.id", combustivel.getId(), false);
  190. qc.getDataFilter().addEq("data", data, false);
  191. qc.atualizarList();
  192.  
  193. Abastecimento abastecimento = null;
  194.  
  195. if(qc.getList().size() > 0) {
  196. abastecimento = (Abastecimento)qc.getList().get(0);
  197.  
  198. System.err.println("Já existe abastecimento (" + i + ", " + abastecimento.getId() + ", " + placaTexto + ", " + Formatador.getDate(data) + ", " + combustivelTexto + ", " + valor + ", " + litros + ")");
  199. }else {
  200. abastecimento = new Abastecimento();
  201. abastecimento.setValor(valor);
  202. abastecimento.setQuantidadeLitros(litros);
  203. abastecimento.setVeiculo(veiculo);
  204. abastecimento.setCombustivel(combustivel);
  205. abastecimento.setData(data);
  206. this.getAbastecimentoService().save(abastecimento);
  207.  
  208. System.out.println("Abastecimento (" + i + ", " + placaTexto + ", " + Formatador.getDate(data) + ", " + combustivelTexto + ", " + valor + ", " + litros + ") salvo com sucesso");
  209. }
  210. }else {
  211. System.err.println("Não foi possível encontrar o combustível \"" + combustivelTexto + "\"");
  212. }
  213. }else {
  214. System.err.println("Não foi possível encontrar o setor \"" + setorTexto + "\"");
  215. }
  216. }
  217. }
  218. }
  219.  
  220. public String getValorCelula(FormulaEvaluator evaluator, Cell celula) {
  221. Cell cell = evaluator.evaluateInCell(celula);
  222.  
  223. if(cell == null) return "";
  224.  
  225. String retorno = "";
  226.  
  227. if(cell.getCellType() == Cell.CELL_TYPE_BLANK) {
  228. retorno = "";
  229. }else if(cell.getCellType() == Cell.CELL_TYPE_STRING) {
  230. retorno = cell.getStringCellValue();
  231. }else if(cell.getCellType() == Cell.CELL_TYPE_NUMERIC) {
  232. retorno = cell.getNumericCellValue() + "";
  233. }
  234.  
  235. return retorno;
  236. }
  237.  
  238. @Override
  239. public void init() {
  240. super.init();
  241.  
  242. File file = new File("C:\\Users\\Carlos\\Desktop\\Igarassu_Combustivel_2015.xlsx");
  243. try {
  244. FileInputStream is = new FileInputStream(file);
  245. this.migrarAbastecimentos(is);
  246. } catch (FileNotFoundException e) {
  247. e.printStackTrace();
  248. } catch (Exception e) {
  249. e.printStackTrace();
  250. }
  251.  
  252. this.setQueryMotoristas(new QueryControl(Motorista.class, this.getQueryService()));
  253. this.getQueryMotoristas().getDataFilter().addEq("pessoa.cliente.id", this.getCliente().getId(), false);
  254. this.getQueryMotoristas().getDataFilter().addOrder("pessoa.nome", TypeOrder.ASC);
  255. this.getQueryMotoristas().atualizarList();
  256.  
  257. this.setQueryVeiculo(new QueryControl(Veiculo.class, this.getQueryService()));
  258. this.getQueryVeiculo().getDataFilter().addEq("cliente.id", this.getCliente().getId(), false);
  259. this.getQueryVeiculo().getDataFilter().addOrder("placa", TypeOrder.ASC);
  260. this.getQueryVeiculo().atualizarList();
  261. }
  262.  
  263. @Override
  264. public void incluirShow() {
  265. if (this.getQueryVeiculo().getList().size() > 0) {
  266. super.incluirShow();
  267. this.getSelected().setVeiculo((Veiculo) this.getQueryVeiculo().getList().get(0));
  268. this.atualizarCombustivelFiltrado();
  269. }else {
  270. FacesUtil.exibirMensagemAlerta("Nenhum veículo cadastrado");
  271. }
  272. }
  273.  
  274. public void alterarShow() {
  275. Abastecimento itemSelected = this.getOneItemSelected();
  276. if (itemSelected != null) {
  277. FacesUtil.cleanSubmittedValues((UIComponent) FacesContext.getCurrentInstance().getViewRoot());
  278. this.setSelected(itemSelected);
  279. this.setCurrentState(ALTERACAO_STATE);
  280. this.atualizarCombustivelFiltrado();
  281. }
  282. this.afterShow();
  283. }
  284.  
  285. public void atualizarCombustivelFiltrado() {
  286. this.setQueryCombustivel(new QueryControl(Combustivel.class, this.getQueryService()));
  287. Combustivel combustivel = this.getSelected().getVeiculo().getModelo().getCombustivel();
  288. if(combustivel != null) {
  289. if(combustivel.getId() == 13) {
  290. this.getQueryCombustivel().getDataFilter().addEq("nome", "Gasolina", false);
  291. this.getQueryCombustivel().getDataFilter().addEq("nome", "Álcool", false);
  292. }else {
  293. this.getQueryCombustivel().getDataFilter().addEq("id", combustivel.getId(), false);
  294. }
  295. }
  296. this.getQueryCombustivel().getDataFilter().addOrder("nome", TypeOrder.ASC);
  297. this.getQueryCombustivel().atualizarList();
  298. if (this.getQueryCombustivel().getList().size() > 0) {
  299. if(this.isInclusaoState()){
  300. this.getSelected().setCombustivel((Combustivel) this.getQueryCombustivel().getList().get(0));
  301. }else {
  302. if(this.getSelected().getCombustivel() == null) {
  303. this.getSelected().setCombustivel((Combustivel) this.getQueryCombustivel().getList().get(0));
  304. }
  305. }
  306. } else {
  307. FacesUtil.exibirMensagemAlerta("Nenhum veículo adicionado");
  308. }
  309. }
  310.  
  311. @Override
  312. public void clearInputs() {
  313. this.setSelected(new Abastecimento());
  314. }
  315.  
  316. @Override
  317. public void setFilterDefinition() {
  318. this.getDataFilter().clear();
  319. this.getDataFilter().addEq("veiculo.cliente.id", this.getCliente().getId());
  320. this.getDataFilter().addOrder("data", TypeOrder.DESC);
  321. }
  322.  
  323. @Override
  324. public void configureDataColumns() {
  325. this.addDataColumn("id", "id");
  326. this.addDataColumn("Data", "dataAsString");
  327. this.addDataColumn("Placa", "veiculo.placa");
  328. this.addDataColumn("Setor do Veículo", "veiculo.setor.nome");
  329. this.addDataColumn("Motorista", "nomeMotorista");
  330. this.addDataColumn("Combustível", "combustivel.nome");
  331. this.addDataColumn("Valor do Abastecimento", "valorAsString");
  332. this.addDataColumn("Qtd Litros", "quantidadeLitrosAsString");
  333. this.addDataColumn("Quilometragem Atual", "kilometragemAsString");
  334. this.addDataColumn("Quilometragem Aquisição", "kmAquisicaoAsString");
  335. }
  336.  
  337. public void imprimirRelatorioShow() {
  338. this.setTipoRelatorio("1");
  339. this.setRenderedEscolherRelatorio(true);
  340. }
  341.  
  342. public void imprimirRelatorio() {
  343. if(this.getTipoRelatorio().equals("1")) {
  344. this.setRenderedEscolherFiltro(true);
  345. }else if(this.getTipoRelatorio().equals("2")) {
  346. this.setRenderedEscolherFiltro(true);
  347. }else if(this.getTipoRelatorio().equals("3")) {
  348. this.setRenderedEscolherPeriodo(true);
  349. this.setAcompanhamentoPor("1");
  350. }
  351. this.setRenderedEscolherRelatorio(false);
  352. }
  353.  
  354. public void imprimirAbastecimento() {
  355. if(this.getTipoRelatorio().equals("1")) {
  356. try {
  357. ReportUtil.printWithConnection("abastecimento_frota.jrxml", this.getParameters(), this.getDataSource().getConnection(), "Resumo de Abastecimento de Frota", "pdf");
  358. this.setRenderedEscolherFiltro(false);
  359. } catch (Exception e) {
  360. FacesUtil.exibirMensagemAlerta("Não foi possível imprimir o relatório");
  361. }
  362. }else if(this.getTipoRelatorio().equals("2")) {
  363. try {
  364. ReportUtil.printWithConnection("relacao_abastecimentos_frota.jrxml", this.getParameters(), this.getDataSource().getConnection(), "Relação de Abastecimentos de Frota", "pdf");
  365. this.setRenderedEscolherFiltro(false);
  366. } catch (Exception e) {
  367. FacesUtil.exibirMensagemAlerta("Não foi possível imprimir o relatório");
  368. }
  369. }else if(this.getTipoRelatorio().equals("3")) {
  370. if(this.getAcompanhamentoPor().equals("1")) {
  371. this.imprimirAcompanhamentoPorCombustivel();
  372. }else if(this.getAcompanhamentoPor().equals("2")) {
  373. this.imprimirAcompanhamentoPorSetor();
  374. }
  375. this.setRenderedEscolherPeriodo(false);
  376. }
  377. }
  378.  
  379. public void imprimirAcompanhamentoPorCombustivel() {
  380. try {
  381. ReportUtil.printWithConnection("acompanhamento_combustiveis_abastecimento.jrxml", this.getParametersAcompanhamento(), this.getDataSource().getConnection(), "Acompanhamento de Abastecimentos por Combustível", "pdf");
  382. this.setRenderedEscolherPeriodo(false);
  383. } catch (Exception e) {
  384. FacesUtil.exibirMensagemAlerta("Não foi possível imprimir o relatório");
  385. }
  386. }
  387.  
  388. public void imprimirAcompanhamentoPorSetor() {
  389. try {
  390. ReportUtil.printWithConnection("acompanhamento_setores_abastecimento.jrxml", this.getParametersAcompanhamento(), this.getDataSource().getConnection(), "Acompanhamento de Abastecimentos por Setor", "pdf");
  391. this.setRenderedEscolherPeriodo(false);
  392. } catch (Exception e) {
  393. FacesUtil.exibirMensagemAlerta("Não foi possível imprimir o relatório");
  394. }
  395. }
  396. @Override
  397. public void salvar() {
  398. super.salvar();
  399. }
  400. public HashMap<String, Object> getParameters() {
  401. HashMap<String, Object> hash = new HashMap<String, Object>();
  402. hash.put("dataInicio", this.getDataInicial());
  403. hash.put("dataFim", this.getDataFinal());
  404. hash.put("clienteId", getCliente().getId());
  405. hash.put("nomeCliente", getCliente().getNome());
  406. hash.put("logoCliente", this.getCliente().getCaminhoLogoReport());
  407.  
  408. String filtro = "";
  409.  
  410. if (getPlacaRelatorio() != "") {
  411. filtro = filtro + "Placa: " + getPlacaRelatorio() + ". ";
  412. }
  413.  
  414. if (getCombustivelRelatorio() != null) {
  415. hash.put("combustivel", getCombustivelRelatorio().getId());
  416. filtro = filtro + "Combustivel: " + getCombustivelRelatorio().getNome() + ". ";
  417. } else {
  418. hash.put("combustivel", new Long(-1));
  419. }
  420.  
  421. if (getMotoristaRelatorio() != null) {
  422. hash.put("motorista", getMotoristaRelatorio().getPessoa().getId());
  423. filtro = filtro + "Motorista: " + getMotoristaRelatorio().getPessoa().getNome() + ". ";
  424. } else {
  425. hash.put("motorista", new Long(-1));
  426. }
  427.  
  428. if (getSetorRelatorio() != null) {
  429. hash.put("setor", getSetorRelatorio().getId());
  430. filtro = filtro + "Setor: " + getSetorRelatorio().getNome() + ". ";
  431. } else {
  432. hash.put("setor", new Long(-1));
  433. }
  434.  
  435. hash.put("placa", "%" + getPlacaRelatorio() + "%");
  436. hash.put("filtro", filtro);
  437.  
  438. return hash;
  439. }
  440.  
  441. public HashMap<String, Object> getParametersAcompanhamento() {
  442. HashMap<String, Object> hash = new HashMap<String, Object>();
  443. hash.put("idCliente", getCliente().getId());
  444. hash.put("cliente", getCliente().getNome());
  445. hash.put("data_inicio", Formatador.getDate(this.getDataInicio()));
  446. hash.put("data_fim", Formatador.getDate(this.getDataFim()));
  447. hash.put("logoCliente", this.getCliente().getCaminhoLogoReport());
  448. return hash;
  449. }
  450.  
  451. /*public List<Combustivel> getCombustivelFiltrado() {
  452. List<Combustivel> retorno = new ArrayList<Combustivel>();
  453. QueryControl qc = new QueryControl(Combustivel.class, this.getQueryService());
  454. if(this.getSelected().getVeiculo().getModelo().getCombustivel().getId() == 13) {
  455.  
  456. }else {
  457.  
  458. }
  459. qc.getDataFilter().addEq("abastece", true, false);
  460. qc.getDataFilter().addOrder("nome", TypeOrder.ASC);
  461. qc.atualizarList();
  462. Iterator<Object> iterator = qc.getList().iterator();
  463. while(iterator.hasNext()) {
  464. retorno.add((Combustivel)iterator.next());
  465. }
  466. return retorno;
  467. }*/
  468.  
  469. public void voltar2() {
  470. this.setRenderedEscolherPeriodo(false);
  471. this.setRenderedEscolherFiltro(false);
  472. this.setRenderedEscolherRelatorio(false);
  473. }
  474.  
  475. public void setAbastecimentoService(AbastecimentoService abastecimentoService) {
  476. this.abastecimentoService = abastecimentoService;
  477. this.setService(abastecimentoService);
  478. }
  479.  
  480. public AbastecimentoService getAbastecimentoService() {
  481. return this.abastecimentoService;
  482. }
  483.  
  484. public Date getDataInicial() {
  485. return this.dataInicial;
  486. }
  487.  
  488. public void setDataInicial(Date dataInicial) {
  489. this.dataInicial = dataInicial;
  490. }
  491.  
  492. public Date getDataFinal() {
  493. return this.dataFinal;
  494. }
  495.  
  496. public void setDataFinal(Date dataFinal) {
  497. this.dataFinal = dataFinal;
  498. }
  499.  
  500. public boolean isRenderedEscolherFiltro() {
  501. return this.renderedEscolherFiltro;
  502. }
  503.  
  504. public void setRenderedEscolherFiltro(boolean renderedEscolherFiltro) {
  505. this.renderedEscolherFiltro = renderedEscolherFiltro;
  506. }
  507.  
  508. public Combustivel getCombustivelRelatorio() {
  509. return combustivelRelatorio;
  510. }
  511.  
  512. public void setCombustivelRelatorio(Combustivel combustivelRelatorio) {
  513. this.combustivelRelatorio = combustivelRelatorio;
  514. }
  515.  
  516. public String getPlacaRelatorio() {
  517. return placaRelatorio;
  518. }
  519.  
  520. public void setPlacaRelatorio(String placaRelatorio) {
  521. this.placaRelatorio = placaRelatorio;
  522. }
  523.  
  524. public Motorista getMotoristaRelatorio() {
  525. return motoristaRelatorio;
  526. }
  527.  
  528. public void setMotoristaRelatorio(Motorista motoristaRelatorio) {
  529. this.motoristaRelatorio = motoristaRelatorio;
  530. }
  531.  
  532. public Setor getSetorRelatorio() {
  533. return setorRelatorio;
  534. }
  535.  
  536. public void setSetorRelatorio(Setor setorRelatorio) {
  537. this.setorRelatorio = setorRelatorio;
  538. }
  539.  
  540. public Date getDataInicio() {
  541. return dataInicio;
  542. }
  543.  
  544. public void setDataInicio(Date dataInicio) {
  545. this.dataInicio = dataInicio;
  546. }
  547.  
  548. public Date getDataFim() {
  549. return dataFim;
  550. }
  551.  
  552. public void setDataFim(Date dataFim) {
  553. this.dataFim = dataFim;
  554. }
  555.  
  556. public boolean isRenderedEscolherPeriodo() {
  557. return renderedEscolherPeriodo;
  558. }
  559.  
  560. public void setRenderedEscolherPeriodo(boolean renderedEscolherPeriodo) {
  561. this.renderedEscolherPeriodo = renderedEscolherPeriodo;
  562. }
  563.  
  564. public String getAcompanhamentoPor() {
  565. return acompanhamentoPor;
  566. }
  567.  
  568. public void setAcompanhamentoPor(String acompanhamentoPor) {
  569. this.acompanhamentoPor = acompanhamentoPor;
  570. }
  571.  
  572. public boolean isRenderedEscolherRelatorio() {
  573. return renderedEscolherRelatorio;
  574. }
  575.  
  576. public void setRenderedEscolherRelatorio(boolean renderedEscolherRelatorio) {
  577. this.renderedEscolherRelatorio = renderedEscolherRelatorio;
  578. }
  579.  
  580. public String getTipoRelatorio() {
  581. return tipoRelatorio;
  582. }
  583.  
  584. public void setTipoRelatorio(String tipoRelatorio) {
  585. this.tipoRelatorio = tipoRelatorio;
  586. }
  587.  
  588. public QueryControl getQueryMotoristas() {
  589. return queryMotoristas;
  590. }
  591.  
  592. public void setQueryMotoristas(QueryControl queryMotoristas) {
  593. this.queryMotoristas = queryMotoristas;
  594. }
  595.  
  596. public QueryControl getQueryVeiculo() {
  597. return queryVeiculo;
  598. }
  599.  
  600. public void setQueryVeiculo(QueryControl queryVeiculo) {
  601. this.queryVeiculo = queryVeiculo;
  602. }
  603.  
  604. public QueryControl getQueryCombustivel() {
  605. return queryCombustivel;
  606. }
  607.  
  608. public void setQueryCombustivel(QueryControl queryCombustivel) {
  609. this.queryCombustivel = queryCombustivel;
  610. }
  611.  
  612. public ModeloService getModeloService() {
  613. return modeloService;
  614. }
  615.  
  616. public void setModeloService(ModeloService modeloService) {
  617. this.modeloService = modeloService;
  618. }
  619.  
  620. public VeiculoService getVeiculoService() {
  621. return veiculoService;
  622. }
  623.  
  624. public void setVeiculoService(VeiculoService veiculoService) {
  625. this.veiculoService = veiculoService;
  626. }
  627.  
  628. public CombustivelService getCombustivelService() {
  629. return combustivelService;
  630. }
  631.  
  632. public void setCombustivelService(CombustivelService combustivelService) {
  633. this.combustivelService = combustivelService;
  634. }
  635. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement