33 lines
742 B
JavaScript
33 lines
742 B
JavaScript
import { baseRequest } from '@/utils/request'
|
||
|
||
const request = (url, ...arg) => baseRequest(`/base/employee/` + url, ...arg)
|
||
|
||
/**
|
||
* 员工Api接口管理器
|
||
*
|
||
* @author Luck
|
||
* @date 2024/07/23 17:31
|
||
**/
|
||
export default {
|
||
// 获取员工分页
|
||
employeePage(data) {
|
||
return request('page', data, 'get')
|
||
},
|
||
// 提交员工表单 edit为true时为编辑,默认为新增
|
||
employeeSubmitForm(data, edit = false) {
|
||
return request(edit ? 'edit' : 'add', data)
|
||
},
|
||
// 删除员工
|
||
employeeDelete(data) {
|
||
return request('delete', data)
|
||
},
|
||
// 获取员工详情
|
||
employeeDetail(data) {
|
||
return request('detail', data, 'get')
|
||
},
|
||
// 添加员工基本信息
|
||
employeeAddShort(data) {
|
||
return request('addShort', data, 'post')
|
||
}
|
||
}
|