staffHandover.ts
1.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/**
* 离职交接 —— 源 src/api/usedCarManagement.js 的同名接口,路径 / method 逐字保留。
*
* 请求统一经 ../core/client 的 @uj/api-core 装配后由主壳 props.request 代发;
* 源系统没有 DTO 定义,这里不臆造结构:参数是一层平铺对象,返回类型由调用方泛型指定。
*/
import { usedcarClient } from '../core/client';
import type { UsedcarParams } from '../core/types';
/**
* 离职交接分页列表
*/
export function getStaffHandover<T = unknown>(data: UsedcarParams = {}) {
return usedcarClient.post<T>('/staffHandover/page', data, { timeout: 30000 });
}
/**
* 原责任人/新接收人下拉列表
*/
export function getStaffHandoverUserList<T = unknown>(data: UsedcarParams = {}) {
return usedcarClient.post<T>('/staffHandover/userList', data, { timeout: 30000 });
}
/**
* 创建离职交接
*/
export function createStaffHandover<T = unknown>(data: UsedcarParams = {}) {
return usedcarClient.post<T>('/staffHandover/create', data, { timeout: 30000 });
}
/**
* 查询待交接资产
*/
export function queryAssets<T = unknown>(data: UsedcarParams = {}) {
return usedcarClient.post<T>('/staffHandover/queryAssets', data, { timeout: 30000 });
}
/**
* 离职交接详情
*/
export function getStaffHandoverDetail<T = unknown>(data: UsedcarParams = {}) {
return usedcarClient.post<T>('/staffHandover/detail', data, { timeout: 30000 });
}
/** 模块单例出口,与 dashboardApi 同一调用面;实现与上方具名函数完全同源。 */
export const staffHandoverApi = {
getStaffHandover,
getStaffHandoverUserList,
createStaffHandover,
queryAssets,
getStaffHandoverDetail,
};