feat(PBI-59): /jobs server page met JobsBoard
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
cd4ca4279f
commit
b6124d9746
1 changed files with 25 additions and 0 deletions
25
app/(app)/jobs/page.tsx
Normal file
25
app/(app)/jobs/page.tsx
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
import { redirect } from 'next/navigation'
|
||||
import { getSession } from '@/lib/auth'
|
||||
import { fetchJobsPageData } from '@/actions/jobs-page'
|
||||
import JobsBoard from '@/components/jobs/jobs-board'
|
||||
|
||||
export const metadata = { title: 'Jobs — Scrum4Me' }
|
||||
|
||||
export default async function JobsPage() {
|
||||
const session = await getSession()
|
||||
if (!session.userId) redirect('/login')
|
||||
|
||||
const data = await fetchJobsPageData()
|
||||
if (!data) redirect('/login')
|
||||
|
||||
return (
|
||||
<main className="flex-1 flex flex-col overflow-hidden">
|
||||
<div className="px-6 py-4 border-b shrink-0 flex items-center gap-3">
|
||||
<h1 className="text-lg font-semibold">Jobs</h1>
|
||||
</div>
|
||||
<div className="flex-1 overflow-hidden">
|
||||
<JobsBoard initialActiveJobs={data.activeJobs} initialDoneJobs={data.doneJobs} />
|
||||
</div>
|
||||
</main>
|
||||
)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue