Solucionado (ver solução)
Solucionado
(ver solução)
2
respostas

Class "App\Http\Controllers\Serie" not found

esta apresentando um erro no: Controllers\SeriesController.php:24

<?php

namespace App\Http\Controllers;
use Illuminate\Http\Request;

class SeriesController extends Controller
{

    public function index() {
        $series = [
            'Grey\'s Anatomy',
            'Lost',
            'Agents of SHIELD'
        ];
        return view('series.index',compact('series'));
    }

    public function create(){
        return view('series.create');
    }

    public function store(Request $req){
        $nome = $req->nome;
        $serie = new Serie();
        $serie->nome = $nome;
        var_dump($serie->save());

    }

}
2 respostas
solução!

Ariel, você se esqueceu do use para importar a classe do namespace correto. :-)

ERRO TARGET CLASS DOES NOT EXISTmeu controller

<?php

namespace App\Http\Controllers;

class objectControllers extends Controller
{
    public function infoArq()
    {
        $window = 2.00 * 1.90;
        $door   = 0.80 * 1.20;

        $html = '<pre>' . $window . 'm² <br>' . $door . 'm²</pre>';

        return $html;

    }
}

minha rota:

<?php

use Illuminate\Support\Facades\Route;

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/

Route::get('/', function () {
    return view('welcome');
});

Route::get('/home', 'objectControllers@infoArq');