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

46 lines
1.4 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 UserWorkInfoVO {
id: number // 唯一主键
userId: number // 员工档案ID关联hrm_user_infor
companyName: string // 单位名称
deptName: string // 部门名称
postName: string // 职位名称
startDate: Date // 开始日期
endDate: Date // 离职日期
monthlySalary: number // 待遇(元/月)
}
// 工作经历信息 API
export const UserWorkInfoApi = {
// 查询工作经历信息分页
getUserWorkInfoPage: async (params: any) => {
return await request.get({ url: `/hrm/user-work-info/page`, params })
},
// 查询工作经历信息详情
getUserWorkInfo: async (id: number) => {
return await request.get({ url: `/hrm/user-work-info/get?id=` + id })
},
// 新增工作经历信息
createUserWorkInfo: async (data: UserWorkInfoVO) => {
return await request.post({ url: `/hrm/user-work-info/create`, data })
},
// 修改工作经历信息
updateUserWorkInfo: async (data: UserWorkInfoVO) => {
return await request.put({ url: `/hrm/user-work-info/update`, data })
},
// 删除工作经历信息
deleteUserWorkInfo: async (id: number) => {
return await request.delete({ url: `/hrm/user-work-info/delete?id=` + id })
},
// 导出工作经历信息 Excel
exportUserWorkInfo: async (params) => {
return await request.download({ url: `/hrm/user-work-info/export-excel`, params })
}
}