68 lines
1.2 KiB
Plaintext
68 lines
1.2 KiB
Plaintext
import { http } from '@/utils/http/axios';
|
|
|
|
/**
|
|
* @description: 公告列表
|
|
*/
|
|
export function getNoticeList(params?) {
|
|
return http.request({
|
|
url: '/notice/page',
|
|
method: 'GET',
|
|
params,
|
|
});
|
|
}
|
|
export function getNoticeAllList(params?) {
|
|
return http.request({
|
|
url: '/notice/list',
|
|
method: 'GET',
|
|
params,
|
|
});
|
|
}
|
|
/**
|
|
* @description: 根据ID获取详情
|
|
*/
|
|
export function getNoticeDetail(id) {
|
|
return http.request({
|
|
url: '/notice/detail/' + id,
|
|
method: 'get',
|
|
});
|
|
}
|
|
/**
|
|
* @description: 添加公告
|
|
*/
|
|
export function noticeAdd(data: any) {
|
|
return http.request({
|
|
url: '/notice/add',
|
|
method: 'POST',
|
|
data,
|
|
});
|
|
}
|
|
/**
|
|
* @description: 更新公告
|
|
*/
|
|
export function noticeUpdate(data: any) {
|
|
return http.request({
|
|
url: '/notice/update',
|
|
method: 'PUT',
|
|
data,
|
|
});
|
|
}
|
|
/**
|
|
* @description: 删除公告
|
|
*/
|
|
export function noticeDelete(id) {
|
|
return http.request({
|
|
url: '/notice/delete/' + id,
|
|
method: 'DELETE',
|
|
});
|
|
}
|
|
/**
|
|
* @description: 批量删除公告
|
|
*/
|
|
export function noticeBatchDelete(data: any) {
|
|
return http.request({
|
|
url: '/notice/batchDelete',
|
|
method: 'DELETE',
|
|
data,
|
|
});
|
|
}
|