diff --git a/dashboard.php b/dashboard.php index 66aad54..d1418b2 100644 --- a/dashboard.php +++ b/dashboard.php @@ -1,72 +1,25 @@ "unauthorized"]); exit; } -?> - - - - - - Dashboard - AI Cinema Engine - - - - -
-

Welcome to your Dashboard

-

Hello, !

-

This is your protected dashboard. You can manage your projects and scenes from here.

+$stmt = $pdo->prepare(" + SELECT id, title, status, created_at, updated_at, final_video_url + FROM projects + WHERE user_id = ? + ORDER BY created_at DESC +"); +$stmt->execute([$userId]); -
-

My Projects

- Create New Project -
- - prepare("SELECT * FROM projects WHERE user_id = ? ORDER BY created_at DESC"); - $stmt->execute([$_SESSION['user_id']]); - $projects = $stmt->fetchAll(); - - if (count($projects) > 0): - ?> -
- - -
-
- Status: -
-

Last updated:

-
- -
- -
-

No projects yet.

-

Get started by creating your first project.

-
- - - -
- - - +echo json_encode($stmt->fetchAll()); +exit; +?> \ No newline at end of file