feat(ADM-018): completed feature
This commit is contained in:
10
project/src/modules/cms/domain/ports.ts
Normal file
10
project/src/modules/cms/domain/ports.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import type { CreatePageInput, Page, UpdatePageInput } from './page.js';
|
||||
|
||||
export interface CmsRepository {
|
||||
create(input: CreatePageInput): Promise<Page | undefined>;
|
||||
update(id: string, patch: UpdatePageInput): Promise<Page | undefined>;
|
||||
setStatus(id: string, status: 'draft' | 'published'): Promise<Page | undefined>;
|
||||
findBySlug(slug: string): Promise<Page | undefined>;
|
||||
findById(id: string): Promise<Page | undefined>;
|
||||
listAll(): Promise<Page[]>;
|
||||
}
|
||||
Reference in New Issue
Block a user