Phase 10. 마에스트로 정보 수정 및 학생 목록 페이지네이션 적용
This commit is contained in:
@@ -73,7 +73,7 @@ export default async function MaestrosPage({
|
||||
</div>
|
||||
|
||||
<form
|
||||
className="grid grid-cols-1 gap-3 rounded-lg border bg-background p-4 sm:grid-cols-2 xl:grid-cols-3 2xl:grid-cols-[minmax(220px,1fr)_160px_180px_190px_110px_auto]"
|
||||
className="grid grid-cols-1 gap-3 rounded-lg border bg-background p-4 sm:grid-cols-2 xl:grid-cols-3 2xl:grid-cols-[minmax(220px,1fr)_160px_180px_190px_auto]"
|
||||
method="get"
|
||||
>
|
||||
<label className="min-w-0 space-y-1.5">
|
||||
@@ -148,23 +148,6 @@ export default async function MaestrosPage({
|
||||
</AutoSubmitSelect>
|
||||
</label>
|
||||
|
||||
<label className="min-w-0 space-y-1.5">
|
||||
<span className="text-xs font-medium text-muted-foreground">
|
||||
페이지 크기
|
||||
</span>
|
||||
<AutoSubmitSelect
|
||||
className="h-9 w-full min-w-0 rounded-md border bg-background px-3 text-sm outline-none transition-colors focus:border-ring focus:ring-3 focus:ring-ring/30"
|
||||
name="pageSize"
|
||||
value={result.pageSize}
|
||||
>
|
||||
{[10, 20, 50, 100].map((pageSize) => (
|
||||
<option key={pageSize} value={pageSize}>
|
||||
{pageSize}
|
||||
</option>
|
||||
))}
|
||||
</AutoSubmitSelect>
|
||||
</label>
|
||||
|
||||
<div className="flex min-w-0 flex-wrap items-end gap-2 sm:col-span-2 xl:col-span-1">
|
||||
<Button className="h-9" type="submit">
|
||||
적용
|
||||
@@ -185,9 +168,27 @@ export default async function MaestrosPage({
|
||||
<MaestrosTable data={result.items} />
|
||||
|
||||
<div className="flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between">
|
||||
<p className="text-sm text-muted-foreground">
|
||||
페이지당 {result.pageSize}개 표시
|
||||
</p>
|
||||
<form className="flex items-center gap-2" method="get">
|
||||
{Object.entries(params).flatMap(([key, value]) => {
|
||||
if (key === "page" || key === "pageSize") return [];
|
||||
const v = Array.isArray(value) ? value[0] : value;
|
||||
if (!v) return [];
|
||||
return [<input key={key} name={key} type="hidden" value={v} />];
|
||||
})}
|
||||
<span className="text-sm text-muted-foreground">페이지당</span>
|
||||
<AutoSubmitSelect
|
||||
className="h-7 rounded-md border bg-background px-2 text-sm outline-none transition-colors focus:border-ring focus:ring-3 focus:ring-ring/30"
|
||||
name="pageSize"
|
||||
value={result.pageSize}
|
||||
>
|
||||
{[10, 20, 50, 100].map((size) => (
|
||||
<option key={size} value={size}>
|
||||
{size}
|
||||
</option>
|
||||
))}
|
||||
</AutoSubmitSelect>
|
||||
<span className="text-sm text-muted-foreground">개 표시</span>
|
||||
</form>
|
||||
<nav
|
||||
aria-label="마에스트로 목록 페이지"
|
||||
className="flex flex-wrap items-center gap-1.5"
|
||||
|
||||
Reference in New Issue
Block a user