Commit 15be784c authored by Marcos Albano's avatar Marcos Albano 💬

Tela cpfValidoSemTitulo funcionando

parent f3c8a294
...@@ -42,31 +42,35 @@ class TituloController extends Controller ...@@ -42,31 +42,35 @@ class TituloController extends Controller
foreach ($lotesTramites as $lotTramite) { foreach ($lotesTramites as $lotTramite) {
$tramites = Tramite::where('id', $lotTramite->tramite_id)->get(); $tramites = Tramite::where('id', $lotTramite->tramite_id)->get();
foreach ($tramites as $tramite) { foreach ($tramites as $tramite) {
if ($tramite->id === 67) { if ($tramite) {
$titulos = Titulo::where('lote_id', $pessoaLote->lote_id)->where('flag_cancelamento', '<>', 'S')->get(); if ($tramite->id === 67) {
foreach ($titulos as $titulo) { // $titulos = Titulo::where('lote_id', $pessoaLote->lote_id)->where('flag_cancelamento', '<>', 'S')->get();
$agendamentos = Agendamento::get()->last(); // foreach ($titulos as $titulo) {
if ($agendamentos) { $agendamentos = Agendamento::get()->last();
return view( if ($agendamentos) {
'admin.pages.titulos.index', return view(
[ 'admin.pages.titulos.index',
'pessoasLote' => $pessoasLote, [
'lotes' => $lotes, 'pessoasLote' => $pessoasLote,
'documentoPessoa' => $documentoPessoa, 'lotes' => $lotes,
'titulos' => $titulo, 'documentoPessoa' => $documentoPessoa,
'lotesTramites' => $lotesTramites, // 'titulos' => $titulo,
'tramite' => $tramite, 'lotesTramites' => $lotesTramites,
'agendamentos' => $agendamentos, 'tramite' => $tramite,
] 'agendamentos' => $agendamentos,
); ]
);
}
}else{
return view('cpfValidoSemTitulo')->with(['cpf' => $this->request->cpf, 'nome' => $tramite->nome]);
} }
} // }
} }
} }
} }
} }
} }
} }
} else { } else {
return view('cpfInvalido')->with(['cpf' => $this->request->cpf]); return view('cpfInvalido')->with(['cpf' => $this->request->cpf]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment