62 lines
1.6 KiB
TypeScript
62 lines
1.6 KiB
TypeScript
import type { FaqManagementVO, FaqManagementForm, FaqManagementQuery } from './model';
|
|
|
|
import type { ID, IDS } from '#/api/common';
|
|
import type { PageResult } from '#/api/common';
|
|
|
|
import { commonExport } from '#/api/helper';
|
|
import { requestClient } from '#/api/request';
|
|
|
|
/**
|
|
* 查询常见问题管理列表
|
|
* @param params
|
|
* @returns 常见问题管理列表
|
|
*/
|
|
export function faqManagementList(params?: FaqManagementQuery) {
|
|
return requestClient.get<PageResult<FaqManagementVO>>('/property/faqManagement/list', { params });
|
|
}
|
|
|
|
/**
|
|
* 导出常见问题管理列表
|
|
* @param params
|
|
* @returns 常见问题管理列表
|
|
*/
|
|
export function faqManagementExport(params?: FaqManagementQuery) {
|
|
return commonExport('/property/faqManagement/export', params ?? {});
|
|
}
|
|
|
|
/**
|
|
* 查询常见问题管理详情
|
|
* @param id id
|
|
* @returns 常见问题管理详情
|
|
*/
|
|
export function faqManagementInfo(id: ID) {
|
|
return requestClient.get<FaqManagementVO>(`/property/faqManagement/${id}`);
|
|
}
|
|
|
|
/**
|
|
* 新增常见问题管理
|
|
* @param data
|
|
* @returns void
|
|
*/
|
|
export function faqManagementAdd(data: FaqManagementForm) {
|
|
return requestClient.postWithMsg<void>('/property/faqManagement', data);
|
|
}
|
|
|
|
/**
|
|
* 更新常见问题管理
|
|
* @param data
|
|
* @returns void
|
|
*/
|
|
export function faqManagementUpdate(data: FaqManagementForm) {
|
|
return requestClient.putWithMsg<void>('/property/faqManagement', data);
|
|
}
|
|
|
|
/**
|
|
* 删除常见问题管理
|
|
* @param id id
|
|
* @returns void
|
|
*/
|
|
export function faqManagementRemove(id: ID | IDS) {
|
|
return requestClient.deleteWithMsg<void>(`/property/faqManagement/${id}`);
|
|
}
|