Job application tracker and AI-powered job search assistant. Helps job seekers manage their search journey with AI resume review, job matching, task logging, and application analytics, all while keeping your data private.
TypeScript ai-agentai-resume-analyzerapplication-trackerapplication-tracking-systematscareerjob-applicationjob-automationjob-huntingjob-searchjob-seeker-toolsjob-trackerjob-trackingjobsearchjobseekersmcpollamaresumeresume-reviewself-hosted
feat(jobs): add Offer Accepted/Declined statuses and make the status badge a picker
Khuram Niaz2a4f30cbd0df
diff --git a/__tests__/MyJobsTable.spec.tsx b/__tests__/MyJobsTable.spec.tsxindex 6c67793..875ab30 100644--- a/__tests__/MyJobsTable.spec.tsx+++ b/__tests__/MyJobsTable.spec.tsx@@ -214,4 +214,48 @@ describe("MyJobsTable", () => {});});});++ describe("status badge menu", () => {+ const user = userEvent.setup();++ it("opens a status menu when the badge is clicked", async () => {+ renderTable([makeJob()]);++ await user.click(+ screen.getByRole("button", { name: "Change status, currently Applied" }),+ );++ expect(await screen.findByText("Interview")).toBeInTheDocument();+ });++ it("calls onChangeJobStatus with the job id and selected status", async () => {+ const { onChangeJobStatus } = renderTable([makeJob()]);++ await user.click(+ screen.getByRole("button", { name: "Change status, currently Applied" }),+ );+ await user.click(await screen.findByText("Interview"));++ expect(onChangeJobStatus).toHaveBeenCalledWith("job-1", {+ id: "2",+ label: "Interview",+ value: "interview",+ });+ });++ it("checks and disables the current status", async () => {+ renderTable([makeJob()]);++ await user.click(+ screen.getByRole("button", { name: "Change status, currently Applied" }),+ );++ const appliedOption = (await screen.findAllByText("Applied")).find((el) =>+ el.closest('[role="menuitem"]'),+ );+ expect(appliedOption?.closest('[role="menuitem"]')).toHaveAttribute(+ "data-disabled",+ );+ });+ });});diff --git a/prisma/migrations/20260904000000_job_status_offer_outcomes/migration.sql b/prisma/migrations/20260904000000_job_status_offer_outcomes/migration.sqlnew file mode 100644index 0000000..d15862c--- /dev/null+++ b/prisma/migrations/20260904000000_job_status_offer_outcomes/migration.sql@@ -0,0 +1,5 @@+-- Data-only: JobStatus rows are seeded at signup, so existing databases+-- need the two new statuses inserted.+INSERT OR IGNORE INTO "JobStatus" ("id", "label", "value") VALUES+ ('ed067643-9887-467d-b870-a5bad64de662', 'Offer Accepted', 'offer-accepted'),+ ('ef09b767-29bb-4800-8713-daebe4600b41', 'Offer Declined', 'offer-declined');diff --git a/src/components/myjobs/JobActionsMenu.tsx b/src/components/myjobs/JobActionsMenu.tsxindex 887c587..096b7a4 100644--- a/src/components/myjobs/JobActionsMenu.tsx+++ b/src/components/myjobs/JobActionsMenu.tsx@@ -16,6 +16,7 @@ import {} from "../ui/dropdown-menu";import { Button } from "../ui/button";import { JobResponse, JobStatus } from "@/models/job.model";+import { JobStatusMenuItems } from "./JobStatusMenuItems";type JobActionsMenuProps = {job: JobResponse;@@ -81,18 +82,11 @@ export function JobActionsMenu({</DropdownMenuSubTrigger><DropdownMenuPortal><DropdownMenuSubContent className="p-0">- {jobStatuses.map((status) => (- <DropdownMenuItem- className="cursor-pointer"- key={status.id}- onSelect={(_) => {- onChangeJobStatus(job.id, status);- }}- disabled={status.id === job.Status.id}- >- <span>{status.label}</span>- </DropdownMenuItem>- ))}+ <JobStatusMenuItems+ jobStatuses={jobStatuses}+ currentStatusId={job.Status.id}+ onSelectStatus={(status) => onChangeJobStatus(job.id, status)}+ /></DropdownMenuSubContent></DropdownMenuPortal></DropdownMenuSub>diff --git a/src/components/myjobs/JobDetails.tsx b/src/components/myjobs/JobDetails.tsxindex 1208652..5d62db3 100644--- a/src/components/myjobs/JobDetails.tsx+++ b/src/components/myjobs/JobDetails.tsx@@ -3,6 +3,7 @@ import { format } from "date-fns";import { Badge } from "../ui/badge";import { StatusBadge } from "../StatusBadge";import { getJobStatusBadgeColor } from "@/lib/badge-colors";+import { JobStatusMenuItems } from "./JobStatusMenuItems";import { formatUrl } from "@/lib/utils";import {Company,@@ -254,16 +255,11 @@ function JobDetails({</DropdownMenuSubTrigger><DropdownMenuPortal><DropdownMenuSubContent className="p-0">- {jobStatuses.map((status) => (- <DropdownMenuItem- className="cursor-pointer"- key={status.id}- onSelect={() => onChangeStatus(status)}- disabled={status.id === currentStatus.id}- >- <span>{status.label}</span>- </DropdownMenuItem>- ))}+ <JobStatusMenuItems+ jobStatuses={jobStatuses}+ currentStatusId={currentStatus.id}+ onSelectStatus={onChangeStatus}+ /></DropdownMenuSubContent></DropdownMenuPortal></DropdownMenuSub>@@ -354,13 +350,13 @@ function JobDetails({<StatusBadgelabel="Expired"color="amber"- className="w-[70px] justify-center"+ className="w-[110px] whitespace-nowrap justify-center"/>) : (<StatusBadgelabel={currentStatus?.label ?? ""}color={getJobStatusBadgeColor(currentStatus?.value ?? "")}- className="w-[70px] justify-center"+ className="w-[110px] whitespace-nowrap justify-center"/>)}{job?.appliedDate && (diff --git a/src/components/myjobs/JobStatusBadgeMenu.tsx b/src/components/myjobs/JobStatusBadgeMenu.tsxnew file mode 100644index 0000000..971bc6e--- /dev/null+++ b/src/components/myjobs/JobStatusBadgeMenu.tsx@@ -0,0 +1,54 @@+"use client";+import {+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuTrigger,+} from "../ui/dropdown-menu";+import {+ Tooltip,+ TooltipContent,+ TooltipTrigger,+} from "../ui/tooltip";+import { JobStatusBadge } from "./JobStatusBadge";+import { JobStatusMenuItems } from "./JobStatusMenuItems";+import { JobResponse, JobStatus } from "@/models/job.model";++type JobStatusBadgeMenuProps = {+ job: JobResponse;+ jobStatuses: JobStatus[];+ onChangeJobStatus: (id: string, status: JobStatus) => void;+ className?: string;+};++export function JobStatusBadgeMenu({+ job,+ jobStatuses,+ onChangeJobStatus,+ className,+}: JobStatusBadgeMenuProps) {+ return (+ <DropdownMenu>+ <Tooltip>+ <TooltipTrigger asChild>+ <DropdownMenuTrigger asChild>+ <button+ type="button"+ aria-label={`Change status, currently ${job.Status?.label ?? ""}`}+ className="cursor-pointer rounded-full focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2"+ >+ <JobStatusBadge job={job} className={className} />+ </button>+ </DropdownMenuTrigger>+ </TooltipTrigger>+ <TooltipContent>Click to change status</TooltipContent>+ </Tooltip>+ <DropdownMenuContent align="start" className="p-0">+ <JobStatusMenuItems+ jobStatuses={jobStatuses}+ currentStatusId={job.Status?.id ?? ""}+ onSelectStatus={(status) => onChangeJobStatus(job.id, status)}+ />+ </DropdownMenuContent>+ </DropdownMenu>+ );+}diff --git a/src/components/myjobs/JobStatusMenuItems.tsx b/src/components/myjobs/JobStatusMenuItems.tsxnew file mode 100644index 0000000..d35c68f--- /dev/null+++ b/src/components/myjobs/JobStatusMenuItems.tsx@@ -0,0 +1,38 @@+"use client";+import { Check } from "lucide-react";+import { DropdownMenuItem } from "../ui/dropdown-menu";+import { JobStatus } from "@/models/job.model";++type JobStatusMenuItemsProps = {+ jobStatuses: JobStatus[];+ currentStatusId: string;+ onSelectStatus: (status: JobStatus) => void;+};++// Shared by the ⋮ menus and the clickable status badge so the three+// status pickers can't drift apart.+export function JobStatusMenuItems({+ jobStatuses,+ currentStatusId,+ onSelectStatus,+}: JobStatusMenuItemsProps) {+ return (+ <>+ {jobStatuses.map((status) => (+ <DropdownMenuItem+ className="cursor-pointer relative pl-8"+ key={status.id}+ onSelect={() => onSelectStatus(status)}+ disabled={status.id === currentStatusId}+ >+ {status.id === currentStatusId && (+ <span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">+ <Check className="h-4 w-4" />+ </span>+ )}+ <span>{status.label}</span>+ </DropdownMenuItem>+ ))}+ </>+ );+}diff --git a/src/components/myjobs/MyJobsTable.tsx b/src/components/myjobs/MyJobsTable.tsxindex 744f3c5..0e67091 100644--- a/src/components/myjobs/MyJobsTable.tsx+++ b/src/components/myjobs/MyJobsTable.tsx@@ -15,7 +15,8 @@ import { JobResponse, JobStatus } from "@/models/job.model";import Link from "next/link";import { DeleteAlertDialog } from "../DeleteAlertDialog";import { CircularScore } from "@/components/CircularScore";-import { JobStatusBadge } from "./JobStatusBadge";+import { JobStatusBadgeMenu } from "./JobStatusBadgeMenu";+import { TooltipProvider } from "../ui/tooltip";import { JobActionsMenu } from "./JobActionsMenu";type MyJobsTableProps = {@@ -44,7 +45,7 @@ function MyJobsTable({};return (- <>+ <TooltipProvider delayDuration={300}><Table><TableHeader><TableRow>@@ -104,9 +105,11 @@ function MyJobsTable({<span className="block truncate">{job.Location?.label}</span></TableCell><TableCell>- <JobStatusBadge+ <JobStatusBadgeMenujob={job}- className="w-[70px] justify-center"+ jobStatuses={jobStatuses}+ onChangeJobStatus={onChangeJobStatus}+ className="w-[110px] whitespace-nowrap justify-center"/></TableCell><TableCell className="hidden md:table-cell">@@ -140,7 +143,7 @@ function MyJobsTable({onOpenChange={setAlertOpen}onDelete={() => deleteJob(jobIdToDelete)}/>- </>+ </TooltipProvider>);}diff --git a/src/lib/badge-colors.ts b/src/lib/badge-colors.tsindex b4bc0ef..c6fdd61 100644--- a/src/lib/badge-colors.ts+++ b/src/lib/badge-colors.ts@@ -24,6 +24,8 @@ export const JOB_STATUS_BADGE_COLORS: Record<JobStatusValue, BadgeColor> = {applied: "blue",interview: "violet",offer: "emerald",+ "offer-accepted": "emerald",+ "offer-declined": "slate",rejected: "red",expired: "amber",archived: "slate",diff --git a/src/lib/constants.ts b/src/lib/constants.tsindex 0a0d973..f35b6f8 100644--- a/src/lib/constants.ts+++ b/src/lib/constants.ts@@ -271,6 +271,8 @@ export const JOB_STATUSES = [{ label: "Applied", value: "applied" },{ label: "Interview", value: "interview" },{ label: "Offer", value: "offer" },+ { label: "Offer Accepted", value: "offer-accepted" },+ { label: "Offer Declined", value: "offer-declined" },{ label: "Rejected", value: "rejected" },{ label: "Expired", value: "expired" },{ label: "Archived", value: "archived" },diff --git a/src/lib/data/jobStatusesData.ts b/src/lib/data/jobStatusesData.tsindex 4f4c170..e8a04d7 100644--- a/src/lib/data/jobStatusesData.ts+++ b/src/lib/data/jobStatusesData.ts@@ -19,6 +19,16 @@ export const JOB_STATUSES = [label: "Offer",value: "offer",},+ {+ id: "ed067643-9887-467d-b870-a5bad64de662",+ label: "Offer Accepted",+ value: "offer-accepted",+ },+ {+ id: "ef09b767-29bb-4800-8713-daebe4600b41",+ label: "Offer Declined",+ value: "offer-declined",+ },{id: "2ff7fed9-82ed-43f5-89ff-e8a676c1c4fe",label: "Rejected",diff --git a/wiki/jobs.md b/wiki/jobs.mdindex 4161831..d4f0efb 100644--- a/wiki/jobs.md+++ b/wiki/jobs.md@@ -3,7 +3,7 @@ type: how-totitle: Jobsdescription: Adding jobs by hand or by pasting a posting into AI chat, moving them through the status workflow, and finding, editing, exporting or deleting them.feature: jobs-tags: [jobs, applications, add a job, status, applied, interview, offer, rejected, csv, export, paste, filter, search]+tags: [jobs, applications, add a job, status, applied, interview, offer, offer accepted, offer declined, rejected, csv, export, paste, filter, search]aliases: [job tracker, application tracker, my jobs, job board, track an application, job list]status: stablestale_after: 2027-08-31@@ -27,13 +27,11 @@ This requires an AI provider and model to be set under **Settings → AI Provide## What do the job statuses mean?-A job carries exactly one status from: **New**, **Draft**, **Applied**, **Interview**, **Offer**, **Rejected**, **Expired** and **Archived**. They are labels you move by hand, not a state machine — nothing stops you going from Interview back to Draft, and nothing changes a status on your behalf.--*New* is where a job discovered by an automation starts. *Draft* is a job you have entered but not applied to. *Applied* through *Offer* track a live application. *Expired* is for a posting that closed before you acted; *Archived* is for anything you want out of the way without deleting it.+A job carries exactly one status from: **New**, **Draft**, **Applied**, **Interview**, **Offer**, **Offer Accepted**, **Offer Declined**, **Rejected**, **Expired** and **Archived** — *Offer Declined* for an offer you turned down, *Rejected* for one the company turned down. They are labels you move by hand, not a state machine — nothing stops you going from Interview back to Draft, and nothing changes a status on your behalf.## How do I change a job's status?-Open the job from the Jobs list, click the **⋮** menu at the top-right of the job details, and choose **Change status** — the submenu lists every status, with the current one greyed out. The change saves immediately; there is no separate save step.+There are two ways. In the Jobs list, click a row's status badge and pick the new status from the menu. Or open the job and use the **⋮** menu at the top-right of the job details, choosing **Change status**. Either menu lists every status with the current one greyed out, and the change saves immediately — there is no separate save step.The Add Job dialog also has a Status field, so a status can be set when you first create the job or from **Edit Job** later.