feat: 支持教学案例展示功能

This commit is contained in:
richarjiang
2026-09-18 18:26:47 +08:00
parent 95b9f6511c
commit 87afb786b9
28 changed files with 950 additions and 5 deletions

View File

@@ -140,3 +140,5 @@ export * from './types/member-care'
export * from './types/body-portrait'
export * from './types/shop'
export * from './types/teaching-case'

View File

@@ -0,0 +1,36 @@
/** Public teaching stories are separate from private member progress. */
export interface TeachingCaseFrame {
kind: 'pair' | 'composite'
beforeId: string
afterId?: string
caption: string
beforeUrl?: string
afterUrl?: string
}
export interface TeachingCaseInput {
title: string
displayName: string
lessonCount: number
background: string
achievement: string
frames: TeachingCaseFrame[]
sortOrder: number
published: boolean
consentConfirmed: boolean
consentNote: string
version: number
}
export interface TeachingCasePublic {
id: string
title: string
displayName: string
lessonCount: number
background: string
achievement: string
frames: TeachingCaseFrame[]
}
export interface TeachingCaseAdmin extends TeachingCasePublic, TeachingCaseInput {
consentedAt: string | null
}
export interface TeachingCasePage<T = TeachingCasePublic> { items: T[]; total: number; page: number; limit: number }
export interface TeachingCaseUpload { id: string; uploadUrl: string; formData: Record<string, string> }