/*
 * @Author: 闪电 14538483+lightning0215@user.noreply.gitee.com
 * @Date: 2024-09-03 19:32:02
 * @LastEditors: 闪电 14538483+lightning0215@user.noreply.gitee.com
 * @LastEditTime: 2025-05-15 10:53:32
 * @FilePath: /base-callcenter-web/src/api/main/system/system.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import request from '@/utils/request'

// 列表
export function getPageListData(url, queryInfo) {
    // console.log(url, 'getPageListData')
    return request({
        url,
        method: 'get',
        params: queryInfo
    })
}
// 删除
export function deletePageData(url, data = {}) {
    return request({
        url,
        method: 'delete',
        data,
    })
}

// 添加
export function createPageData(url, newData) {
    return request({
        url,
        method: 'post',
        data: newData
    })
}
// 修改
export function editPageData(url, editData) {
    return request({
        url,
        method: 'put',
        data: editData
    })
}
// 详细
export function getPageDetail(url) {
    return request({
        url,
        method: 'get'
    })
}

export function getPageHandle(url, query) {
    return request({
        url,
        method: 'get',
        params: query
    })
}
// 查询岗位详细
export function getPost(postId) {
    return request({
        url: '/system/post/' + postId,
        method: 'get'
    })
}