This commit is contained in:
61
apps/web-antd/src/api/sis/authRecord/index.ts
Normal file
61
apps/web-antd/src/api/sis/authRecord/index.ts
Normal file
@@ -0,0 +1,61 @@
|
||||
import type { AuthRecordVO, AuthRecordForm, AuthRecordQuery } 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 authRecordList(params?: AuthRecordQuery) {
|
||||
return requestClient.get<PageResult<AuthRecordVO>>('/sis/authRecord/list', { params });
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出授权记录列表
|
||||
* @param params
|
||||
* @returns 授权记录列表
|
||||
*/
|
||||
export function authRecordExport(params?: AuthRecordQuery) {
|
||||
return commonExport('/sis/authRecord/export', params ?? {});
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询授权记录详情
|
||||
* @param id id
|
||||
* @returns 授权记录详情
|
||||
*/
|
||||
export function authRecordInfo(id: ID) {
|
||||
return requestClient.get<AuthRecordVO>(`/sis/authRecord/${id}`);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增授权记录
|
||||
* @param data
|
||||
* @returns void
|
||||
*/
|
||||
export function authRecordAdd(data: AuthRecordForm) {
|
||||
return requestClient.postWithMsg<void>('/sis/authRecord', data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新授权记录
|
||||
* @param data
|
||||
* @returns void
|
||||
*/
|
||||
export function authRecordUpdate(data: AuthRecordForm) {
|
||||
return requestClient.putWithMsg<void>('/sis/authRecord', data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除授权记录
|
||||
* @param id id
|
||||
* @returns void
|
||||
*/
|
||||
export function authRecordRemove(id: ID | IDS) {
|
||||
return requestClient.deleteWithMsg<void>(`/sis/authRecord/${id}`);
|
||||
}
|
54
apps/web-antd/src/api/sis/authRecord/model.d.ts
vendored
Normal file
54
apps/web-antd/src/api/sis/authRecord/model.d.ts
vendored
Normal file
@@ -0,0 +1,54 @@
|
||||
import type { PageQuery, BaseEntity } from '#/api/common';
|
||||
|
||||
export interface AuthRecordVO {
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 人像id
|
||||
*/
|
||||
imgId: string | number;
|
||||
|
||||
/**
|
||||
* 门禁id
|
||||
*/
|
||||
acdId: string | number;
|
||||
|
||||
}
|
||||
|
||||
export interface AuthRecordForm extends BaseEntity {
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 人像id
|
||||
*/
|
||||
imgId?: string | number;
|
||||
|
||||
/**
|
||||
* 门禁id
|
||||
*/
|
||||
acdId?: string | number;
|
||||
|
||||
}
|
||||
|
||||
export interface AuthRecordQuery extends PageQuery {
|
||||
/**
|
||||
* 人像id
|
||||
*/
|
||||
imgId?: string | number;
|
||||
|
||||
/**
|
||||
* 门禁id
|
||||
*/
|
||||
acdId?: string | number;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
Reference in New Issue
Block a user