import request from '@/sheep/request'; const InvoiceApi = { // 获得发票抬头列表 getInvoicesHeadList: (params) => { return request({ url: `/trade/invoice-header/list`, method: 'GET', params, custom: { showLoading: true, }, }); }, // 获得当前用户发票列表 getInvoicesList: (params) => { return request({ url: `/trade/invoice/page`, method: 'GET', params, custom: { showLoading: true, }, }); }, // 获得发票抬头详情 getInvoicesheadDetail: (params) => { return request({ url: `/trade/invoice-header/get?id=${params}`, method: 'GET', params, custom: { showLoading: false, }, }); }, // 创建发票抬头 createInvoicehead: (data) => { return request({ url: `/trade/invoice-header/create`, method: 'POST', data, custom: { showLoading: true, }, }); }, // 修改发票抬头 updateInvoicehead: (data) => { return request({ url: `/trade/invoice-header/update`, method: 'PUT', data, custom: { showLoading: true, }, }); }, // 删除发票抬头 deleteInvoicehead: (data) => { return request({ url: `/trade/invoice-header/delete?id=${data}`, method: 'DELETE', data, custom: { showLoading: false, }, }); }, // 创建新发票 createInvoicenew: (data) => { return request({ url: `/trade/invoice/create`, method: 'POST', data, custom: { showLoading: false, }, }); }, } export default InvoiceApi;