0, 'name' => 'Tanach', 'userId' => 1, ], ]; $nodes = [ [ 'id' => 0, 'title' => 'Tanach', 'textId' => 0, 'parentNodeId' => null, ], [ 'id' => 1, 'title' => 'Torah', 'textId' => 0, 'parentNodeId' => 0, ], [ 'id' => 2, 'title' => 'Bereishis', 'textId' => 0, 'parentNodeId' => 1, ], ]; // Default credentials: // admin@example.com / admin1234 (admin) // user@example.com / password1 (regular user) // user2@example.com / password2 (second regular user, no texts seeded) $users = [ [ 'id' => 0, 'email' => 'admin@example.com', 'passwordHash' => password_hash('admin1234', PASSWORD_DEFAULT), 'isAdmin' => true, ], [ 'id' => 1, 'email' => 'user@example.com', 'passwordHash' => password_hash('password1', PASSWORD_DEFAULT), 'isAdmin' => false, ], [ 'id' => 2, 'email' => 'user2@example.com', 'passwordHash' => password_hash('password2', PASSWORD_DEFAULT), 'isAdmin' => false, ], ]; $plans = []; $scheduledNodes = []; $sessions = []; $fileDataMap = [ 'texts.json' => $texts, 'nodes.json' => $nodes, 'users.json' => $users, 'plans.json' => $plans, 'scheduledNodes.json' => $scheduledNodes, 'sessions.json' => $sessions, ]; foreach ($fileDataMap as $file => $data) { $path = __DIR__ . "/$file"; file_put_contents($path, json_encode($data, JSON_PRETTY_PRINT)); }