권한설정 페이지 수정/student만
This commit is contained in:
@@ -22,17 +22,22 @@ export async function getInstructors(): Promise<UserRow[]> {
|
||||
?.split('=')[1])
|
||||
: null;
|
||||
|
||||
const apiUrl = process.env.NEXT_PUBLIC_API_BASE_URL
|
||||
const baseUrl = process.env.NEXT_PUBLIC_API_BASE_URL
|
||||
? `${process.env.NEXT_PUBLIC_API_BASE_URL}/admin/users/compact`
|
||||
: 'https://hrdi.coconutmeet.net/admin/users/compact';
|
||||
|
||||
// 쿼리 파라미터 추가: type=STUDENT, limit=10
|
||||
const apiUrl = new URL(baseUrl);
|
||||
apiUrl.searchParams.set('type', 'STUDENT');
|
||||
apiUrl.searchParams.set('limit', '10');
|
||||
|
||||
console.log('🔍 [getInstructors] API 호출 정보:', {
|
||||
url: apiUrl,
|
||||
url: apiUrl.toString(),
|
||||
hasToken: !!token,
|
||||
tokenLength: token?.length || 0
|
||||
});
|
||||
|
||||
const response = await fetch(apiUrl, {
|
||||
const response = await fetch(apiUrl.toString(), {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
|
||||
Reference in New Issue
Block a user