1、工单处理
Some checks are pending
Gitea Actions Demo / Explore-Gitea-Actions (push) Waiting to run

This commit is contained in:
2025-07-09 10:36:42 +08:00
parent e860009b61
commit fb963ff3a7
8 changed files with 820 additions and 11 deletions

View File

@@ -0,0 +1,61 @@
import type { WorkOrdersVO, WorkOrdersForm, WorkOrdersQuery } 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 workOrdersList(params?: WorkOrdersQuery) {
return requestClient.get<PageResult<WorkOrdersVO>>('/property/workOrders/list', { params });
}
/**
* 导出工单处理列表
* @param params
* @returns 工单处理列表
*/
export function workOrdersExport(params?: WorkOrdersQuery) {
return commonExport('/property/workOrders/export', params ?? {});
}
/**
* 查询工单处理详情
* @param id id
* @returns 工单处理详情
*/
export function workOrdersInfo(id: ID) {
return requestClient.get<WorkOrdersVO>(`/property/workOrders/${id}`);
}
/**
* 新增工单处理
* @param data
* @returns void
*/
export function workOrdersAdd(data: WorkOrdersForm) {
return requestClient.postWithMsg<void>('/property/workOrders', data);
}
/**
* 更新工单处理
* @param data
* @returns void
*/
export function workOrdersUpdate(data: WorkOrdersForm) {
return requestClient.putWithMsg<void>('/property/workOrders', data);
}
/**
* 删除工单处理
* @param id id
* @returns void
*/
export function workOrdersRemove(id: ID | IDS) {
return requestClient.deleteWithMsg<void>(`/property/workOrders/${id}`);
}