| @@ -123,22 +123,22 @@ function SearchBox<T extends string>({ | |||||
| const handleDownload = async () => { | const handleDownload = async () => { | ||||
| try { | try { | ||||
| // Create a request object, which includes the projectId | // Create a request object, which includes the projectId | ||||
| console.log(inputs) | |||||
| const abc = await fetchTeamCombo() | |||||
| // console.log(inputs) | |||||
| // const abc = await fetchTeamCombo() | |||||
| //console.log(abc.records) | //console.log(abc.records) | ||||
| const requestData: LateStartReportRequest = { | |||||
| team: 'Your Team Name', // Example value, adjust as necessary | |||||
| customer: 'Client Name', // Example value, adjust as necessary | |||||
| project: new Date().toISOString() // Current date in ISO format, adjust as necessary | |||||
| }; | |||||
| // const requestData: LateStartReportRequest = { | |||||
| // team: 'Your Team Name', // Example value, adjust as necessary | |||||
| // customer: 'Client Name', // Example value, adjust as necessary | |||||
| // project: new Date().toISOString() // Current date in ISO format, adjust as necessary | |||||
| // }; | |||||
| // Call fetchLateStartReport and wait for the blob | // Call fetchLateStartReport and wait for the blob | ||||
| //const responseBlob = await fetchLateStartReport(requestData); | //const responseBlob = await fetchLateStartReport(requestData); | ||||
| const fileResponse = await fetchLateStartReport(requestData); | |||||
| if (fileResponse) { | |||||
| downloadFile(new Uint8Array(fileResponse.blobValue), fileResponse.filename!!) | |||||
| } | |||||
| // const fileResponse = await fetchLateStartReport(requestData); | |||||
| // if (fileResponse) { | |||||
| // downloadFile(new Uint8Array(fileResponse.blobValue), fileResponse.filename!!) | |||||
| // } | |||||
| // const blob = fileResponse.fileBlob; | // const blob = fileResponse.fileBlob; | ||||
| // // Create a URL from the Blob response | // // Create a URL from the Blob response | ||||