Feat: Landing Page (welcome)
✅ Hero секция с градиентом ✅ Преимущества платформы (3 карточки) ✅ Публичные курсы (до 6) ✅ CTA секция ✅ Footer ✅ Login Modal ✅ Адаптивный дизайн Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
parent
dcb89380aa
commit
4ee0b55643
|
|
@ -0,0 +1,20 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\Course;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
class HomeController extends Controller
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
// Получаем публичные курсы (или просто активные)
|
||||
$courses = Course::where('is_active', true)
|
||||
->with('category')
|
||||
->limit(6)
|
||||
->get();
|
||||
|
||||
return view('welcome', compact('courses'));
|
||||
}
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
|
||||
use App\Http\Controllers\HomeController;
|
||||
use App\Http\Controllers\Auth\LoginController;
|
||||
use App\Http\Controllers\Auth\RegisterController;
|
||||
use App\Http\Controllers\Admin\OrganizationController;
|
||||
|
|
@ -28,9 +29,7 @@ use Illuminate\Support\Facades\Route;
|
|||
*/
|
||||
|
||||
// Главная страница
|
||||
Route::get('/', function () {
|
||||
return view('welcome');
|
||||
})->name('home');
|
||||
Route::get('/', [HomeController::class, 'index'])->name('home');
|
||||
|
||||
// Маршруты аутентификации
|
||||
Route::middleware('guest')->group(function () {
|
||||
|
|
|
|||
Loading…
Reference in New Issue