소스 검색

add IPaliBookListResponse IChapterListResponse

visuddhinanda 3 년 전
부모
커밋
0b2c353375
1개의 변경된 파일27개의 추가작업 그리고 0개의 파일을 삭제
  1. 27 0
      dashboard/src/components/api/Corpus.ts

+ 27 - 0
dashboard/src/components/api/Corpus.ts

@@ -1,5 +1,6 @@
 import { IUser } from "../auth/User";
 import { IUser } from "../auth/User";
 import { IChannel } from "../channel/Channel";
 import { IChannel } from "../channel/Channel";
+import { TagNode } from "../tag/TagArea";
 
 
 export interface IApiPaliChapterList {
 export interface IApiPaliChapterList {
   id: string;
   id: string;
@@ -152,3 +153,29 @@ export interface IPaliTocListResponse {
   message: string;
   message: string;
   data: { rows: IPaliToc[]; count: number };
   data: { rows: IPaliToc[]; count: number };
 }
 }
+
+export interface IPaliBookListResponse {
+  name: string;
+  tag: string[];
+  children?: IPaliBookListResponse[];
+}
+
+export interface IChapterData {
+  title: string;
+  toc: string;
+  book: number;
+  para: number;
+  path: string;
+  tags: TagNode[];
+  channel: { name: string; owner_uid: string };
+  summary: string;
+  view: number;
+  like: number;
+  created_at: string;
+  updated_at: string;
+}
+export interface IChapterListResponse {
+  ok: boolean;
+  message: string;
+  data: { rows: IChapterData[]; count: number };
+}