Rev 721 | Rev 732 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 721 | Rev 722 | ||
|---|---|---|---|
| Line 270... | Line 270... | ||
| 270 | 270 | ||
| 271 | public void atualizarCentrosDeCustos() { |
271 | public void atualizarCentrosDeCustos() { |
| 272 | new VerificadorLancamentoException().tratarIhRelancarExcecaoSemLimparEntidade(new CommandBean() { |
272 | new VerificadorLancamentoException().tratarIhRelancarExcecaoSemLimparEntidade(new CommandBean() { |
| 273 | public void execute() { |
273 | public void execute() { |
| 274 | for (FolhaPagamentoFuncionarioDTO folhaPagamentoFuncionario : getFolhaPagamentoDTO().getFuncionarios()) { |
274 | for (FolhaPagamentoFuncionarioDTO folhaPagamentoFuncionario : getFolhaPagamentoDTO().getFuncionarios()) { |
| 275 | if (VerificadorUtil.naoEstaNulo(folhaPagamentoFuncionario.getValorSalarioImportado()) && |
- | |
| 276 | !VerificadorUtil.isListaNulaOuVazia(folhaPagamentoFuncionario.getParcelas())) { |
- | |
| - | 275 | if (!VerificadorUtil.isListaNulaOuVazia(folhaPagamentoFuncionario.getParcelas())) { |
|
| 277 | if (VerificadorUtil.naoEstaNulo(folhaPagamentoFuncionario.getParcelas().get(0))) { |
276 | if (VerificadorUtil.naoEstaNulo(folhaPagamentoFuncionario.getParcelas().get(0))) { |
| 278 | ParcelaDTO parcela = folhaPagamentoFuncionario.getParcelas().get(0); |
277 | ParcelaDTO parcela = folhaPagamentoFuncionario.getParcelas().get(0); |
| 279 | Long sequencialConta = parcela.getContaDTO().getSequencial(); |
278 | Long sequencialConta = parcela.getContaDTO().getSequencial(); |
| 280 | folhaPagamentoService.atualizarCentroDeCustos(sequencialConta, folhaPagamentoFuncionario.getAvaliacaoFuncionarioDTO().getSequencialDaLoja()); |
279 | folhaPagamentoService.atualizarCentroDeCustos(sequencialConta, folhaPagamentoFuncionario.getAvaliacaoFuncionarioDTO().getSequencialDaLoja()); |
| 281 | }
|
280 | }
|
| 282 | }
|
281 | }
|
| 283 | }
|
282 | }
|
| 284 | detalharFolhaPagamento(); |
283 | detalharFolhaPagamento(); |
| 285 | LancadorMensagem.lancarSucesso("VALORES ATUALIZADOS COM SUCESSO"); |
- | |
| - | 284 | setArquivoParaImportacao(null); |
|
| - | 285 | LancadorMensagem.lancarSucesso("CENTROS DE CUSTOS ATUALIZADOS COM SUCESSO"); |
|
| 286 | }
|
286 | }
|
| 287 | }); |
287 | }); |
| 288 | }
|
288 | }
|
| 289 | 289 | ||
| 290 | public void efetuarPagamentos() { |
290 | public void efetuarPagamentos() { |
| Line 294... | Line 294... | ||
| 294 | if (!VerificadorUtil.isListaNulaOuVazia(folhaPagamentoFuncionario.getParcelas())) { |
294 | if (!VerificadorUtil.isListaNulaOuVazia(folhaPagamentoFuncionario.getParcelas())) { |
| 295 | parcelaService.efetuarPagamentoRecebimento(folhaPagamentoFuncionario.getParcelas().get(0), getDataPagamento()); |
295 | parcelaService.efetuarPagamentoRecebimento(folhaPagamentoFuncionario.getParcelas().get(0), getDataPagamento()); |
| 296 | vigenciaService.alterarSituacaoFolha(getVigenciaSelecionada().getSequencial(), TipoSituacoesVigencia.EM_ANDAMENTO_A.getValor()); |
296 | vigenciaService.alterarSituacaoFolha(getVigenciaSelecionada().getSequencial(), TipoSituacoesVigencia.EM_ANDAMENTO_A.getValor()); |
| 297 | }
|
297 | }
|
| 298 | }
|
298 | }
|
| 299 | setArquivoParaImportacao(null); |
- | |
| 300 | detalharFolhaPagamento(); |
299 | detalharFolhaPagamento(); |
| - | 300 | setArquivoParaImportacao(null); |
|
| 301 | LancadorMensagem.lancarSucesso("PAGAMENTOS EFETUADOS COM SUCESSO"); |
301 | LancadorMensagem.lancarSucesso("PAGAMENTOS EFETUADOS COM SUCESSO"); |
| 302 | }
|
302 | }
|
| 303 | }); |
303 | }); |
| 304 | }
|
304 | }
|
| 305 | 305 | ||