This commit is contained in:
1 parent
f43fbef5db
commit
21abd01593
11 files changed
+450
-104
No files matched your search
@@ -692,6 +692,34 @@ export const wecomCheckinSession = (code: string, state: string) =>
|
||||
export const wecomCheckinPage = (token: string) =>
|
||||
post<{ success: boolean; data: WecomCheckinPageData }>(`${base}/wecom/checkin-page`, { token })
|
||||
|
||||
// 工号扫码签到(2026-11-25 调整:可信域名未就绪期间的免登替代主流程)。
|
||||
// page-anon:匿名落地页数据(工号非空时附带名单/重复标记);by-employee:
|
||||
// 规则校验 + 工号反查档案 + 自动登录,响应内嵌 /auth/login 同构会话。
|
||||
export const wecomCheckinPageAnon = (token: string, employeeNo = '') =>
|
||||
post<{ success: boolean; data: WecomCheckinPageData }>(`${base}/wecom/checkin-page-anon`, {
|
||||
token,
|
||||
employee_no: employeeNo || undefined,
|
||||
})
|
||||
|
||||
export interface WecomCheckinByEmployeeData extends WecomCheckinPageData {
|
||||
token?: string
|
||||
refresh_token?: string
|
||||
user?: Record<string, any>
|
||||
active_tenant?: { id: number | string; name?: string; created_at?: string; updated_at?: string } | null
|
||||
memberships?: Array<{ tenant_id: number; tenant_name?: string; role: string }>
|
||||
record?: TrainingSignRecord | null
|
||||
}
|
||||
|
||||
export const wecomCheckinByEmployee = (payload: {
|
||||
token: string
|
||||
employee_no: string
|
||||
nonce: string
|
||||
lat?: number
|
||||
lng?: number
|
||||
client_ts?: number
|
||||
}) =>
|
||||
post<{ success: boolean; data: WecomCheckinByEmployeeData }>(`${base}/wecom/checkin-by-employee`, payload)
|
||||
|
||||
export const checkin = (
|
||||
token: string,
|
||||
lat = 0,
|
||||
|
||||
Reference in new issue
Block a user