You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
60 lines
1.6 KiB
60 lines
1.6 KiB
import request from '@/config/axios'
|
|
|
|
export interface PostVO {
|
|
id?: number
|
|
name: string
|
|
code: string
|
|
sort: number
|
|
status: number
|
|
remark: string
|
|
createTime?: Date
|
|
}
|
|
|
|
// 查询岗位列表
|
|
export const getPostPage = async (params: PageParam) => {
|
|
return await request.get({ url: '/system/post/page', params })
|
|
}
|
|
|
|
// 获取岗位精简信息列表
|
|
export const getSimplePostList = async (): Promise<PostVO[]> => {
|
|
return await request.get({ url: '/system/post/list-all-simple' })
|
|
}
|
|
|
|
// 查询岗位详情
|
|
export const getPost = async (id: number) => {
|
|
return await request.get({ url: '/system/post/get?id=' + id })
|
|
}
|
|
|
|
// 新增岗位
|
|
export const createPost = async (data: PostVO) => {
|
|
return await request.post({ url: '/system/post/create', data })
|
|
}
|
|
|
|
// 修改岗位
|
|
export const updatePost = async (data: PostVO) => {
|
|
return await request.put({ url: '/system/post/update', data })
|
|
}
|
|
|
|
// 删除岗位
|
|
export const deletePost = async (id: number) => {
|
|
return await request.delete({ url: '/system/post/delete?id=' + id })
|
|
}
|
|
|
|
// 导出岗位
|
|
export const exportPost = async (params) => {
|
|
return await request.download({ url: '/system/post/export', params })
|
|
}
|
|
|
|
// 库位树状图
|
|
export const getPostAreaTreeList = async () => {
|
|
return await request.get({ url: '/wms/warehouse/treeLocation' })
|
|
}
|
|
// 根据id获取已选择节点
|
|
export const getByPostId = async (id) => {
|
|
return await request.get({ url: '/system/post-location/getByPostId?postId=' + id })
|
|
}
|
|
//提交选择的节点
|
|
export const updatePostLocation = async (data) => {
|
|
return await request.post({ url: '/system/post-location/updatePostLocation',data})
|
|
}
|
|
|
|
|