diff --git a/src/components/Pages/Gangguan/Rekap/RGangguan_ALL.vue b/src/components/Pages/Gangguan/Rekap/RGangguan_ALL.vue index 731e7b6..9fd6480 100755 --- a/src/components/Pages/Gangguan/Rekap/RGangguan_ALL.vue +++ b/src/components/Pages/Gangguan/Rekap/RGangguan_ALL.vue @@ -1084,7 +1084,7 @@ import DetailDialog from '@/components/Dialogs/DetailDialog.vue' import InputText from '@/components/InputText.vue' import { apolloClient } from '@/utils/api/api.graphql' import { provideApolloClient } from '@vue/apollo-composable' -import { exportToPDF } from '@/report/Gangguan/Rekap/RGangguan_ALL' +import { exportToPDF, exportToXLSX } from '@/report/Gangguan/Rekap/RGangguan_ALL' const client = apolloClient() provideApolloClient(client) @@ -1322,21 +1322,9 @@ const showDetail = () => { const onExporting = (e: any) => { if (e.format === 'pdf') { exportToPDF(reportMeta.value, data.value) + } else if (e.format === 'xlsx') { + exportToXLSX(reportMeta.value, e) } else { - const workbook = new Workbook() - const worksheet = workbook.addWorksheet('Employees') - - exportToExcel({ - component: e.component, - worksheet, - autoFilterEnabled: true - }).then(() => { - workbook.xlsx.writeBuffer().then((buffer: any) => { - saveAs(new Blob([buffer], { type: 'application/octet-stream' }), 'DataGrid.xlsx') - }) - }) - - e.cancel = true } } diff --git a/src/components/Pages/Gangguan/Rekap/RGangguan_CTTM.vue b/src/components/Pages/Gangguan/Rekap/RGangguan_CTTM.vue index 05f6191..6b076e2 100755 --- a/src/components/Pages/Gangguan/Rekap/RGangguan_CTTM.vue +++ b/src/components/Pages/Gangguan/Rekap/RGangguan_CTTM.vue @@ -1,7 +1,14 @@