import request from '@/utils/request'

// 查询交易项目列表
export function listProject(query) {
  return request({
    url: '/system/project/list',
    method: 'get',
    params: query
  })
}

// 查询交易项目详细
export function getProject(transactionProjectId) {
  return request({
    url: '/system/project/' + transactionProjectId,
    method: 'get'
  })
}

// 新增交易项目
export function addProject(data) {
  return request({
    url: '/system/project',
    method: 'post',
    data: data
  })
}

// 修改交易项目
export function updateProject(data) {
  return request({
    url: '/system/project',
    method: 'put',
    data: data
  })
}

// 删除交易项目
export function delProject(transactionProjectId) {
  return request({
    url: '/system/project/' + transactionProjectId,
    method: 'delete'
  })
}

// 导出交易项目
export function exportProject(query) {
  return request({
    url: '/system/project/export',
    method: 'get',
    params: query
  })
}