2025-03-26
This commit is contained in:
32
src/api/modules/articleClass.ts
Normal file
32
src/api/modules/articleClass.ts
Normal file
@@ -0,0 +1,32 @@
|
||||
import http from "@/api";
|
||||
// import qs from "qs";
|
||||
const ARTICLE_CATEGORY = `/article/category`;
|
||||
//文章分类列表
|
||||
export const getArticleClassListApi = (params: any) => {
|
||||
return http.get<any>(`${ARTICLE_CATEGORY}/index`, params);
|
||||
};
|
||||
//文章分类新增
|
||||
export const getArticleClassAddSaveApi = (params: any) => {
|
||||
return http.post<any>(`${ARTICLE_CATEGORY}/save`, params);
|
||||
};
|
||||
//文章分类删除
|
||||
export const getArticleClassDelApi = (params: any) => {
|
||||
return http.delete<any>(`${ARTICLE_CATEGORY}/delete/${params}`);
|
||||
};
|
||||
//文章分类更新(用于编辑后)
|
||||
export const getArticleClassEditUpApi = (params: any) => {
|
||||
const { id, name, sort, is_show, seo_title, seo_keywords, seo_desc } = params;
|
||||
|
||||
return http.put<any>(`/article/category/update/${id}`, {
|
||||
name,
|
||||
sort,
|
||||
is_show,
|
||||
seo_title,
|
||||
seo_keywords,
|
||||
seo_desc
|
||||
});
|
||||
};
|
||||
//文章分类详情(用于编辑)
|
||||
export const getArticleClassDetailsApi = (params: any) => {
|
||||
return http.get<any>(`${ARTICLE_CATEGORY}/read/${params}`);
|
||||
};
|
||||
Reference in New Issue
Block a user