import createAxios from '@/utils/request'

import {ADVANCE_BOOT} from '@/utils/constantRequest'


/**
 * 根据用户id查询所有生产线
 */
export const querySgProductLineByUserId = (data: any) => {
    return createAxios({
        url: ADVANCE_BOOT + '/sgProductLine/querySgProductLineByUserId?userId='+data,
        method: 'GET',
    })
}



/**
 * 新增生产线
 */
export const addSgProductLine = (data: any) => {
    return createAxios({
        url: ADVANCE_BOOT + '/sgProductLine/add',
        method: 'POST',
        data: data
    })
}


/**
 * 更新生产线
 */
export const updateSgProductLine = (data: any) => {
    return createAxios({
        url: ADVANCE_BOOT + '/sgProductLine/update',
        method: 'POST',
        data: data
    })
}


/**
 * 删除生产线
 */
export const deleteSgProductLine = (data: any) => {
    let ids = [data]
    return createAxios({
        url: ADVANCE_BOOT + '/sgProductLine/delete',
        method: 'POST',
        data: ids
    })
}
