import type { Key } from 'react'; import { request } from 'umi'; type PassOnParam = { chainId: string; auditId: Key | Key[]; type: string; userId: number; }; export const auditPassOn = (o: PassOnParam) => { const { chainId, auditId, type, userId } = o; return request(`/goapi/audit/reassign/batch`, { method: 'POST', data: { chainId, userId, [type === 'uac' ? 'uacAuditId' : 'bpmAuditId']: Array.isArray(auditId) ? auditId : [auditId], }, }); };