chore: 前端调整博客结构定义
This commit is contained in:
@@ -2,5 +2,7 @@ import { Blog } from "@/lib/types/blog";
|
||||
import { serverFetch } from "../server";
|
||||
|
||||
export async function list() {
|
||||
return serverFetch<Blog[]>('/api/blog')
|
||||
return serverFetch<Pick<Blog,
|
||||
'id' | 'title' | 'description' | 'viewCount' | 'createdAt' | 'updatedAt' | 'deletedAt'
|
||||
>[]>('/api/blog')
|
||||
}
|
||||
@@ -7,5 +7,7 @@ export interface Blog {
|
||||
viewCount: number;
|
||||
contentUrl: string;
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
deletedAt: string;
|
||||
permissions: BlogPermission[];
|
||||
}
|
||||
Reference in New Issue
Block a user