This commit is contained in:
quantulr
2023-10-27 17:29:50 +08:00
parent dd9ae31b30
commit 73bc779168
31 changed files with 591 additions and 165 deletions

37
app/types/article.ts Normal file
View File

@ -0,0 +1,37 @@
export interface Article {
id: number;
title: string;
image: string;
intro: string;
visit: number;
collect: boolean;
createTime: string;
}
export interface ArticleListParams {
cid?: string;
}
export interface ArticleDetail {
id: number;
cid: number;
category: string;
title: string;
intro: string;
summary: string;
image: string;
content: string;
author: string;
visit: number;
sort: number;
isCollect: number;
createTime: string;
updateTime: string;
// prev: Prev
// next: Next
// news: News[]
}
export interface ArticleDetailParams {
id: string;
}

13
app/types/base.ts Normal file
View File

@ -0,0 +1,13 @@
export interface BaseResponse<T> {
code: number;
msg: string;
data: T;
}
export interface PageData<T> {
count: number;
pageNo: number;
pageSize: number;
extend: any;
lists: T[];
}