1234567891011121314151617 |
- <?php
- namespace App\Http\Controllers;
- use App\Events\DemoEvent;
- use App\Models\Demo;
- use Illuminate\Http\Request;
- class DemoController extends Controller
- {
- //
- public function index(Demo $demo){
- $all=Demo::find(1);
- event(new DemoEvent($all));
- return View('welcome');
- }
- }
|