- Event ORM model with status/level enums, domain categories, review tracking - Alembic migration e7f3a9b1c5d0 for events table - Event crawler service with placeholder data (12 sample events) - GET /api/v1/events with status/domain/search filtering and overdue_days - EventArchivePage with filter toolbar (status, domain, search) and adaptive card grid - Status badges, level badges, domain tags, overdue markers on event cards - Loading/error/empty states, hover-to-honey card interaction Co-Authored-By: Claude <noreply@anthropic.com>
27 lines
588 B
TypeScript
27 lines
588 B
TypeScript
import client from './client'
|
|
|
|
export interface EventItem {
|
|
id: string
|
|
title: string
|
|
level: 'A' | 'B' | 'C'
|
|
domain: string
|
|
status: 'active' | 'fading' | 'dissipating' | 'closed'
|
|
occurred_date: string
|
|
last_reviewed: string | null
|
|
no_new_info_count: number
|
|
next_review: string | null
|
|
overdue_days: number
|
|
created_at: string | null
|
|
updated_at: string | null
|
|
}
|
|
|
|
export interface EventsResponse {
|
|
events: EventItem[]
|
|
}
|
|
|
|
export const getEvents = (params?: {
|
|
status?: string
|
|
domain?: string
|
|
search?: string
|
|
}) => client.get<EventsResponse>('/events', { params })
|