import request from '@/utils/request'

// 查询流程历史单列表
export function listHis(query) {
  return request({
    url: '/assets/his/list',
    method: 'get',
    params: query
  })
}

// 查询流程历史单详细
export function getHis(instanceId) {
  return request({
    url: '/assets/his/' + instanceId,
    method: 'get'
  })
}

// 新增流程历史单
export function addHis(data) {
  return request({
    url: '/assets/his',
    method: 'post',
    data: data
  })
}

// 修改流程历史单
export function updateHis(data) {
  return request({
    url: '/assets/his',
    method: 'put',
    data: data
  })
}

// 删除流程历史单
export function delHis(instanceId) {
  return request({
    url: '/assets/his/' + instanceId,
    method: 'delete'
  })
}

// 导出流程历史单
export function exportHis(query) {
  return request({
    url: '/assets/his/export',
    method: 'get',
    params: query
  })
}