admin-vue3/src/api/hrm/userperformance/index.ts

46 lines
1.5 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

import request from '@/config/axios'
// 员工绩效 VO
export interface UserPerformanceVO {
id: number // 唯一主键
userId: number // 员工档案ID关联 hrm_user_infor
assessmentMonth: Date // 考核月份格式YYYY-MM
performanceLevel: number // 绩效等级
assessmentScoreTotal: number // 考核得分合计
attendanceScore: number // 考勤得分
performanceAssessmentScore: number // 业绩考核得分
behaviorAssessmentScore: number // 行为考核得分
}
// 员工绩效 API
export const UserPerformanceApi = {
// 查询员工绩效分页
getUserPerformancePage: async (params: any) => {
return await request.get({ url: `/hrm/user-performance/page`, params })
},
// 查询员工绩效详情
getUserPerformance: async (id: number) => {
return await request.get({ url: `/hrm/user-performance/get?id=` + id })
},
// 新增员工绩效
createUserPerformance: async (data: UserPerformanceVO) => {
return await request.post({ url: `/hrm/user-performance/create`, data })
},
// 修改员工绩效
updateUserPerformance: async (data: UserPerformanceVO) => {
return await request.put({ url: `/hrm/user-performance/update`, data })
},
// 删除员工绩效
deleteUserPerformance: async (id: number) => {
return await request.delete({ url: `/hrm/user-performance/delete?id=` + id })
},
// 导出员工绩效 Excel
exportUserPerformance: async (params) => {
return await request.download({ url: `/hrm/user-performance/export-excel`, params })
}
}