<?php
require_once __DIR__ . '/../../config/session.php';
require_once __DIR__ . '/../../config/db.php';
require_once __DIR__ . '/../../config/response.php';
require_login();
$role_id = (int)($_GET['role_id'] ?? 0);
$stmt = $pdo->prepare("SELECT permission_id FROM role_permissions WHERE role_id = ?");
$stmt->execute([$role_id]);
jsonResponse(['success' => true, 'data' => $stmt->fetchAll()]);
