import request from '@/utils/request'

/**
 * 异常上报
 * @param {Object} data - { orderId, photos, type, content }
 */
export function uploadAnamaly(data) {
  return request({
    url: '/fulfiller/anamaly/upload',
    method: 'POST',
    data
  })
}

/**
 * 获取订单异常记录列表
 * @param {number} orderId - 订单ID
 */
export function getAnomalyList(orderId) {
  return request({
    url: `/fulfiller/anamaly/listOnOrder?orderId=${orderId}`,
    method: 'GET'
  })
}
