Source identity
| Field | Recorded value |
|---|---|
| Source type | GitHub source |
| Original record | Janady13/missionmatch / frontend/src/tools/slatematch/captureConstants.ts |
| Date | Not specified in source |
| Repository | Janady13/missionmatch |
| Revision | 720d47fae476b0d38477ae4401697d372b1ea2bc |
| Branch | feature/opportunity-to-outcome |
| Path or archive member | frontend/src/tools/slatematch/captureConstants.ts |
| Original SHA-256 | 267d136e2acf7ff1344f727903d7ff310f6b9e7323ef99b052dfb2bd2a59737b |
| Git blob SHA | 6d26cbead83e5e8fa3c7b4a0f6d0e356cb8002b8 |
| Reading-copy SHA-256 | 267d136e2acf7ff1344f727903d7ff310f6b9e7323ef99b052dfb2bd2a59737b |
Recovered source transcript
Download complete source text ↓42 lines · 1.4 KB
// Shared vocabulary and helpers for the opportunity capture screens. The value lists mirror the CHECK
// constraints in migration 0070 so the UI never offers a value the server will reject.
export const inputCls =
'w-full rounded-lg border border-line/70 bg-navy-900 px-3 py-2 text-sm text-ink outline-none focus:border-blue'
export const SOURCE_TYPES: [string, string][] = [
['sam_gov', 'SAM.gov'],
['agency_forecast', 'Agency forecast'],
['customer', 'Customer'],
['partner', 'Teaming partner'],
['internal', 'Internal'],
['spreadsheet', 'Spreadsheet import'],
['manual', 'Manual entry'],
]
export const STATUSES: [string, string][] = [
['identified', 'Identified'],
['qualifying', 'Qualifying'],
['qualified', 'Qualified'],
['pursuing', 'Pursuing'],
['no_bid', 'No bid'],
['submitted', 'Submitted'],
['won', 'Won'],
['lost', 'Lost'],
['cancelled', 'Cancelled'],
['archived', 'Archived'],
]
export const PRIME_OR_SUB: [string, string][] = [
['', 'Not set'],
['prime', 'Prime'],
['sub', 'Subcontract'],
]
export const STATUS_LABEL: Record<string, string> = Object.fromEntries(STATUSES)
export const SOURCE_LABEL: Record<string, string> = Object.fromEntries(SOURCE_TYPES)
export const fmtDeadline = (s: string) => (s ? new Date(s).toLocaleDateString() : 'No deadline')
// An <input type="date"> needs a bare YYYY-MM-DD; the API returns RFC3339.
export const toDateInput = (s: string) => (s ? s.slice(0, 10) : '')