Пример #1
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     $boleto = Boleto::find($id);
     $clientes = Cliente::orderBy('fantasia')->get();
     $fornecedores = Fornecedor::orderBy('fantasia')->get();
     $edit = true;
     if ($boleto->lancamento->status == '1') {
         return view('boletos.edit', compact('boleto', 'fornecedores', 'clientes'));
     }
     flash('Boleto já está pago');
     return redirect('/boletos');
 }
Пример #2
0
 public function getRelatorio()
 {
     $fornecedores = Fornecedor::orderBy('fantasia')->get(['id', 'fantasia', 'nome_razao']);
     return view('produtos/relatorios/capa', compact('fornecedores'));
 }
Пример #3
0
 public function relatorioCapa()
 {
     $fornecedores = Fornecedor::orderBy('fantasia')->get();
     return view('compras.relatorios.capa', compact('fornecedores'));
 }
Пример #4
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     $cheque = Cheque::find($id);
     $bancos = Banco::all()->lists('nome', 'id');
     $clientes = Cliente::orderBy('fantasia')->get();
     $fornecedores = Fornecedor::orderBy('fantasia')->get();
     if ($cheque->lancamento->status != '2' || $cheque->lancamento->status != '3') {
         return view('cheques.edit', compact('cheque', 'bancos', 'clientes', 'fornecedores'));
     }
     flash('Cheque já está pago');
     return redirect('/cheques');
 }