fix: loading in daftar gangguan dialihkan ke posko lain
This commit is contained in:
27
src/components/Dialogs/BufferDialog.vue
Normal file
27
src/components/Dialogs/BufferDialog.vue
Normal file
@ -0,0 +1,27 @@
|
||||
<template>
|
||||
<div
|
||||
class="bg-black text-white flex justify-center items-center absolute top-0 bottom-0 right-0 left-0 z-50 opacity-50"
|
||||
>
|
||||
<svg
|
||||
class="animate-spin h-10 w-10 text-white"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
fill="none"
|
||||
viewBox="0 0 24 24"
|
||||
>
|
||||
<circle
|
||||
class="opacity-25"
|
||||
cx="12"
|
||||
cy="12"
|
||||
r="10"
|
||||
stroke="currentColor"
|
||||
stroke-width="4"
|
||||
></circle>
|
||||
<path
|
||||
class="opacity-75"
|
||||
fill="currentColor"
|
||||
d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
|
||||
></path>
|
||||
</svg>
|
||||
<span class="ml-3 font-bold text-xl">Loading...</span>
|
||||
</div>
|
||||
</template>
|
@ -33,7 +33,7 @@
|
||||
/>
|
||||
<DxSelection mode="single" />
|
||||
<!-- <DxScrolling column-rendering-mode="virtual" mode="virtual" row-rendering-mode="virtual" /> -->
|
||||
<DxLoadPanel
|
||||
<!-- <DxLoadPanel
|
||||
shading-color="rgba(0,0,0,0.4)"
|
||||
:position="position"
|
||||
:show-indicator="showIndicator"
|
||||
@ -42,7 +42,7 @@
|
||||
v-if="loading"
|
||||
v-model:visible="loading"
|
||||
:enabled="true"
|
||||
/>
|
||||
/> -->
|
||||
<DxSearchPanel :visible="true" :highlight-case-sensitive="true" />
|
||||
<DxExport
|
||||
:enabled="true"
|
||||
@ -340,6 +340,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</DetailDialog>
|
||||
|
||||
<BufferDialog v-if="loading" />
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
@ -359,9 +361,9 @@ import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import DetailDialog from '@/components/Dialogs/DetailDialog.vue'
|
||||
import InputText from '@/components/InputText.vue'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries, requestGraphQl } from '@/utils/api/api.graphql'
|
||||
import { exportToPDF, exportToXLSX, exportToDOCX } from '@/report/Gangguan/Daftar/DGangguan_DKPL'
|
||||
import BufferDialog from '@/components/Dialogs/BufferDialog.vue'
|
||||
|
||||
const position = { of: '#dataTable' }
|
||||
const showIndicator = ref(true)
|
||||
@ -373,6 +375,10 @@ const dialogDetail = ref(false)
|
||||
const loading = ref(false)
|
||||
const closeDialog = () => (dialogDetail.value = false)
|
||||
|
||||
const bufferTest = () => {
|
||||
console.log('Buffer Test')
|
||||
}
|
||||
|
||||
const resetData = () => {
|
||||
data.value = []
|
||||
}
|
||||
@ -556,7 +562,7 @@ const onExporting = (e: any) => {
|
||||
if (e.format === 'pdf') {
|
||||
exportToPDF(reportMeta, data)
|
||||
} else if (e.format === 'xlsx') {
|
||||
exportToXLSX(reportMeta, data, e)
|
||||
exportToXLSX(reportMeta, e)
|
||||
} else {
|
||||
exportToDOCX(reportMeta, data)
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<main
|
||||
class="flex flex-col justify-between flex-1 px-4 overflow-y-auto bg-white lg:mr-3 sm:px-3 lg:px-6 rounded-t-2xl lg:rounded-t-3xl no-scroll-bar"
|
||||
class="flex flex-col justify-between flex-1 px-4 overflow-y-auto bg-white lg:mr-3 sm:px-3 lg:px-6 rounded-t-2xl lg:rounded-t-3xl no-scroll-bar relative"
|
||||
>
|
||||
<div v-if="route.path !== '/home'" class="mt-4 lg:mt-6 max-w-7xl">
|
||||
<h1 class="text-lg font-semibold md:text-xl text-dark">{{ pageTitle }}</h1>
|
||||
@ -12,8 +12,8 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { computed } from 'vue';
|
||||
import { useRoute } from 'vue-router';
|
||||
import { computed } from 'vue'
|
||||
import { useRoute } from 'vue-router'
|
||||
|
||||
// Dapatkan objek route dari vue-router
|
||||
const route = useRoute()
|
||||
|
Reference in New Issue
Block a user