104 lines
2.2 KiB
TypeScript
104 lines
2.2 KiB
TypeScript
|
|
import { LngPngApproPageModel, LngPngApproPageParams, LngPngApproPageResult } from './model/PngApproGdModel';
|
|||
|
|
import { defHttp } from '/@/utils/http/axios';
|
|||
|
|
import { ErrorMessageMode } from '/#/axios';
|
|||
|
|
|
|||
|
|
enum Api {
|
|||
|
|
// Page = '/dayPlan/pngApproGd/page',
|
|||
|
|
Page = '/magic-api//dayPlan/pngApproGd/page',
|
|||
|
|
List = '/dayPlan/pngApproGd/list',
|
|||
|
|
Info = '/dayPlan/pngApproGd/info',
|
|||
|
|
LngPngAppro = '/dayPlan/pngApproGd',
|
|||
|
|
approve = '/dayPlan/pngAppro/approveGD',
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
/**
|
|||
|
|
* @description: 审批LngPngAppro
|
|||
|
|
*/
|
|||
|
|
export async function approveLngPngAppro(lngPngAppro: Recordable, mode: ErrorMessageMode = 'modal') {
|
|||
|
|
return defHttp.post<boolean>(
|
|||
|
|
{
|
|||
|
|
url: Api.approve,
|
|||
|
|
params: lngPngAppro,
|
|||
|
|
},
|
|||
|
|
{
|
|||
|
|
errorMessageMode: mode,
|
|||
|
|
},
|
|||
|
|
);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* @description: 查询LngPngAppro分页列表
|
|||
|
|
*/
|
|||
|
|
export async function getLngPngApproPage(params: LngPngApproPageParams, mode: ErrorMessageMode = 'modal') {
|
|||
|
|
return defHttp.get<LngPngApproPageResult>(
|
|||
|
|
{
|
|||
|
|
url: Api.Page,
|
|||
|
|
params,
|
|||
|
|
},
|
|||
|
|
{
|
|||
|
|
errorMessageMode: mode,
|
|||
|
|
},
|
|||
|
|
);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* @description: 获取LngPngAppro信息
|
|||
|
|
*/
|
|||
|
|
export async function getLngPngAppro(id: String, mode: ErrorMessageMode = 'modal') {
|
|||
|
|
return defHttp.get<LngPngApproPageModel>(
|
|||
|
|
{
|
|||
|
|
url: Api.Info,
|
|||
|
|
params: { id },
|
|||
|
|
},
|
|||
|
|
{
|
|||
|
|
errorMessageMode: mode,
|
|||
|
|
},
|
|||
|
|
);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* @description: 新增LngPngAppro
|
|||
|
|
*/
|
|||
|
|
export async function addLngPngAppro(lngPngAppro: Recordable, mode: ErrorMessageMode = 'modal') {
|
|||
|
|
return defHttp.post<boolean>(
|
|||
|
|
{
|
|||
|
|
url: Api.LngPngAppro,
|
|||
|
|
params: lngPngAppro,
|
|||
|
|
},
|
|||
|
|
{
|
|||
|
|
errorMessageMode: mode,
|
|||
|
|
},
|
|||
|
|
);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* @description: 更新LngPngAppro
|
|||
|
|
*/
|
|||
|
|
export async function updateLngPngAppro(lngPngAppro: Recordable, mode: ErrorMessageMode = 'modal') {
|
|||
|
|
return defHttp.put<boolean>(
|
|||
|
|
{
|
|||
|
|
url: Api.LngPngAppro,
|
|||
|
|
params: lngPngAppro,
|
|||
|
|
},
|
|||
|
|
{
|
|||
|
|
errorMessageMode: mode,
|
|||
|
|
},
|
|||
|
|
);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* @description: 删除LngPngAppro(批量删除)
|
|||
|
|
*/
|
|||
|
|
export async function deleteLngPngAppro(ids: string[], mode: ErrorMessageMode = 'modal') {
|
|||
|
|
return defHttp.delete<boolean>(
|
|||
|
|
{
|
|||
|
|
url: Api.LngPngAppro,
|
|||
|
|
data: ids,
|
|||
|
|
},
|
|||
|
|
{
|
|||
|
|
errorMessageMode: mode,
|
|||
|
|
},
|
|||
|
|
);
|
|||
|
|
}
|