| | |
| | | responseType: 'blob' |
| | | }) |
| | | } |
| | | export function DownloadSubscriptions (data) { |
| | | export function ExportSubscriptionsExcel (data) { |
| | | // let params = '' |
| | | // for (const key in data) { |
| | | // console.log(key + ':' + data[key]) |
| | | // params = params + (data[key] ? `&${key}=${data[key]}` : '') |
| | | // } |
| | | // console.log(params) |
| | | return request({ |
| | | url: '/AutoDesk/download/subscriptions/' + data.taskId, |
| | | url: '/AutoDesk/subscriptions/ExportExcel?AutoRenewingContractText=' + (data.AutoRenewingContractText === 'Auto-RenewingContract' ? data.AutoRenewingContractText : '') + |
| | | (data.EndCustomerStateProvince |
| | | ? '&EndCustomerStateProvince=' + encodeURIComponent(data.EndCustomerStateProvince) : '') + |
| | | (data.ProductLine |
| | | ? '&ProductLine=' + encodeURIComponent(data.ProductLine) : '') + |
| | | (data.Term |
| | | ? '&Term=' + data.Term : '') + |
| | | (data.StartContractEndDate |
| | | ? '&StartContractEndDate=' + data.StartContractEndDate : '') + |
| | | (data.EndContractEndDate |
| | | ? '&EndContractEndDate=' + data.EndContractEndDate : ''), |
| | | method: 'get', |
| | | responseType: 'blob' |
| | | }) |