
import request from '@/assets/js/utils/request'
/*
 * =======================订单管理==============================
 * */
// 获取订单所有字典信息
export function queryProcurementOrderInitInfo() {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/queryProcurementOrderInitInfo',
    method: 'post'
  })
}
// 采购员订单列表
export function listProcurementOrderPages(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/listProcurementOrderPages',
    method: 'post',
    data
  })
}
// 订单详情
export function queryProcurementOrderInfo(orderId) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/queryProcurementOrderInfo?orderId=' + orderId,
    method: 'get'
  })
}
// 采购员订单物资列表
export function listProcurementOrderProductPages(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrderProduct/listProcurementOrderProductPages',
    method: 'post',
    data
  })
}
// 保存或提交订单信息
export function updateOrSubmitProcurementOrderInfo(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/updateOrSubmitProcurementOrderInfo',
    method: 'post',
    data
  })
}
// 部门经理订单审核列表
export function listProcurementOrderAuditPages(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/listProcurementOrderAuditPages',
    method: 'post',
    data
  })
}
// 获取审核意见信息列表
export function queryProcurementOrderAudit(orderId) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrderAudit/queryProcurementOrderAudit?orderId=' + orderId,
    method: 'get'
  })
}
// 部门经理审核通过或不通过
export function auditProcurementOrderInfo(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/auditProcurementOrderInfo',
    method: 'post',
    data
  })
}
// 代理订单审核列表
export function listAgentProcurementOrderPages(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/listAgentProcurementOrderPages',
    method: 'post',
    data
  })
}
// 供应商订单列表
export function listSupplierProcurementOrderPages(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/listSupplierProcurementOrderPages',
    method: 'post',
    data
  })
}
// 供应商确认订单
export function supplierReceivingOrders(orderId) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/supplierReceivingOrders?orderId=' + orderId,
    method: 'get'
  })
}
// 订单作废
export function abolishOrders(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/abolishOrders',
    method: 'post',
    data
  })
}
// 释放或退回行项目
export function releaseProcurementOrderProduct(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrderProduct/releaseProcurementOrderProduct',
    method: 'post',
    data
  })
}

// 获取关联订单
export function listCommonSupplierProcurementOrderPages(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/listCommonSupplierProcurementOrderPages',
    method: 'post',
    data
  })
}

// 提交释放或者退回行项目
export function submitReleaseProcurementOrderProduct(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrderProduct/submitReleaseProcurementOrderProduct',
    method: 'post',
    data
  })
}

// 反馈人---获取可以提意见的订单
export function getPageOrderInfoAllByRole(data) {
  return request({
    url: '/bidprocurement/procurement-contract/procurementOrder/getPageOrderInfoAllByRole',
    method: 'post',
    data
  })
}
