import request from '@/utils/request'

// 查询列表
export function listTeam(query) {
    return request({
        url: '/bracelet/team/list',
        method: 'get',
        params: query
    })
}

// 查询人员
export function getPersonList(data) {
    return request({
        url: '/bracelet/team/getPersonList',
        method: 'post',
        data: data
    })
}

// 添加
export function addTeam(data) {
    return request({
        url: '/bracelet/team/addTeam',
        method: 'post',
        data: data
    })
}

// 详情
export function getTeamInfo(data) {
    return request({
        url: '/bracelet/team/getTeamInfo',
        method: 'post',
        data: data
    })
}

// 修改
export function editTeam(data) {
    return request({
        url: '/bracelet/team/editTeam',
        method: 'post',
        data: data
    })
}

// 删除
export function delTeam(data) {
    return request({
        url: '/bracelet/team/delTeam',
        method: 'post',
        data: data
    })
}

// 解散
export function dissolutionTeam(data) {
    return request({
        url: '/bracelet/team/dissolutionTeam',
        method: 'post',
        data: data
    })
}

// 导出
export function exportTeam(query) {
    return request({
        url: '/bracelet/export/exportTeam',
        method: 'get',
        responseType: 'blob',
        params: query
    })
}

// 查询班组成员列表
export function getWorkPersonList(query) {
    return request({
        url: '/bracelet/team/getWorkPersonList',
        method: 'get',
        params: query
    })
}