Commit c35d964f authored by alinetenorio's avatar alinetenorio
Browse files

verificação se user é proponente

parent 3cb620ff
...@@ -29,7 +29,7 @@ class ParticipanteController extends Controller ...@@ -29,7 +29,7 @@ class ParticipanteController extends Controller
//$projetos = Auth::user()->participantes->where('user_id', Auth::user()->id)->first()->trabalhos; //$projetos = Auth::user()->participantes->where('user_id', Auth::user()->id)->first()->trabalhos;
//dd($projetos); //dd(Auth::user()->proponentes);
return view('participante.projetos')->with(['edital' => $edital, 'projetos' => $projetos]); return view('participante.projetos')->with(['edital' => $edital, 'projetos' => $projetos]);
} }
......
...@@ -13,7 +13,8 @@ ...@@ -13,7 +13,8 @@
<!-- Se usuário não é proponente, redirecionar para view de cadastro --> <!-- Se usuário não é proponente, redirecionar para view de cadastro -->
@if(Auth::user()->proponentes == null) @if(Auth::user()->proponentes == null)
<a href="{{ route('proponente.create' )}}" class="btn btn-primary">Criar projeto</a> <a href="{{ route('proponente.create' )}}" class="btn btn-primary">Criar projeto</a>
@else
<a href="{{ route('trabalho.index' )}}" class="btn btn-primary">Criar projeto</a>
@endif @endif
</div> </div>
</div> </div>
......
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