import request from '@/utils/request'

// 更新
export function materialUpdate(query) {
  return request({
    url: '/work/material/update',
    method: 'get',
    params: query
  })
}

// 更新
export function stepSubmit(query) {
  return request({
    url: '/work/step/submit',
    method: 'get',
    params: query
  })
}

// 更新
export function materialCheckFlag(query) {
  return request({
    url: '/work/material/checkFlag',
    method: 'get',
    params: query
  })
}

// 更新
export function materialNextStepFlag(query) {
  return request({
    url: '/work/material/nextStepFlag',
    method: 'get',
    params: query
  })
}

// 更新
export function stepUpdate(query) {
  return request({
    url: '/work/step/update',
    method: 'get',
    params: query
  })
}

// 更新
export function stepNext(query) {
  return request({
    url: '/work/step/next',
    method: 'get',
    params: query
  })
}
// 更新
export function materialNext(query) {
  return request({
    url: '/work/material/next',
    method: 'get',
    params: query
  })
}
// 更新
export function materialStart(query) {
  return request({
    url: '/work/material/start',
    method: 'get',
    params: query
  })
}
// 更新
export function stepCheck(batchId) {
  return request({
    url: '/work/step/check/'+batchId,
    method: 'get'
  })
}
// 更新
export function stepFinish(batchId) {
  return request({
    url: '/work/step/finish/'+batchId,
    method: 'get'
  })
}

// 更新
export function listMaterial(query) {
  return request({
    url: '/work/material/list',
    method: 'get',
    params: query
  })
}

// 更新
export function stepProcess(query) {
  return request({
    url: '/work/step/process',
    method: 'get',
    params: query
  })
}

// 更新
export function stepPLC(query) {
  return request({
    url: '/work/step/plc',
    method: 'get',
    params: query
  })
}



// 新增用户
export function materialFinalData(data) {
  return request({
    url: '/work/material/finalData',
    method: 'post',
    data: data
  })
}

// 复位
export function materialReset(query) {
  return request({
    url: '/work/step/updateNextState',
    method: 'get',
    params: query
  })
}