Update cell templates : Gangguan - Daftar.vue
This commit is contained in:
parent
60e0e30685
commit
099b5d867a
@ -4,154 +4,61 @@
|
||||
</Filters>
|
||||
|
||||
<div id="data">
|
||||
<DxDataGrid
|
||||
class="max-h-[calc(100vh-140px)] mb-10"
|
||||
:data-source="data"
|
||||
:show-column-lines="true"
|
||||
:show-row-lines="false"
|
||||
:show-borders="true"
|
||||
:row-alternation-enabled="true"
|
||||
:hover-state-enabled="true"
|
||||
@selection-changed=""
|
||||
:column-width="100"
|
||||
@exporting=""
|
||||
:allow-column-resizing="true"
|
||||
column-resizing-mode="widget"
|
||||
>
|
||||
<DxDataGrid class="max-h-[calc(100vh-140px)] mb-10" :data-source="data" :show-column-lines="true"
|
||||
:show-row-lines="false" :show-borders="true" :row-alternation-enabled="true" :hover-state-enabled="true"
|
||||
@selection-changed="" :column-width="100" @exporting="" :allow-column-resizing="true"
|
||||
column-resizing-mode="widget">
|
||||
<DxSelection mode="single" />
|
||||
<DxPaging :page-size="5" :enabled="true" />
|
||||
<DxPager
|
||||
:visible="true"
|
||||
:allowed-page-sizes="[5, 10, 20]"
|
||||
display-mode="full"
|
||||
:show-page-size-selector="true"
|
||||
:show-info="true"
|
||||
:show-navigation-buttons="true"
|
||||
/>
|
||||
<DxLoadPanel
|
||||
:position="position"
|
||||
:show-indicator="showIndicator"
|
||||
:show-pane="showPane"
|
||||
:shading="shading"
|
||||
v-if="loading"
|
||||
v-model:visible="loading"
|
||||
:enabled="true"
|
||||
/>
|
||||
<DxPager :visible="true" :allowed-page-sizes="[5, 10, 20]" display-mode="full" :show-page-size-selector="true"
|
||||
:show-info="true" :show-navigation-buttons="true" />
|
||||
<DxLoadPanel :position="position" :show-indicator="showIndicator" :show-pane="showPane" :shading="shading"
|
||||
v-if="loading" v-model:visible="loading" :enabled="true" />
|
||||
<DxSearchPanel :visible="true" :highlight-case-sensitive="true" />
|
||||
<DxExport
|
||||
:enabled="true"
|
||||
:formats="['pdf', 'xlsx', 'document']"
|
||||
:allow-export-selected-data="false"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="50"
|
||||
alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1"
|
||||
data-type="number"
|
||||
caption="No"
|
||||
/>
|
||||
<DxExport :enabled="true" :formats="['pdf', 'xlsx', 'document']" :allow-export-selected-data="false" />
|
||||
<DxColumn css-class="custom-table-column" :width="50" alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1" data-type="number" caption="No" />
|
||||
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_laporan"
|
||||
caption="No Laporan"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="nama_pelapor"
|
||||
caption="Nama Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="status_akhir"
|
||||
caption="Status"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_lapor"
|
||||
caption="Tgl Lapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_response"
|
||||
caption="Tgl Response"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_recovery"
|
||||
caption="Tgl Recovery"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_response_time"
|
||||
caption="Durasi Response Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="nama_posko"
|
||||
caption="Sumber Lapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_media"
|
||||
caption="Tgl Media"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="media"
|
||||
caption="Keterangan Media"
|
||||
/>
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_laporan"
|
||||
caption="No Laporan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_pelapor"
|
||||
caption="Nama Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="status_akhir"
|
||||
caption="Status" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_lapor"
|
||||
caption="Tgl Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_response"
|
||||
caption="Tgl Response" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_recovery"
|
||||
caption="Tgl Recovery" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_response_time"
|
||||
caption="Durasi Response Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_posko"
|
||||
caption="Sumber Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_media"
|
||||
caption="Tgl Media" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="keterangan_media"
|
||||
caption="Keterangan Media" cell-template="cellDefault" />
|
||||
|
||||
<template #cellCenter="{ data }">
|
||||
<p class="cursor-pointer">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #cellDefault="{ data }">
|
||||
<p class="text-left cursor-pointer">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #data-waktu="{ data }">
|
||||
<p>
|
||||
@ -166,7 +73,7 @@
|
||||
import Filters from '@/components/Form/Filters.vue'
|
||||
import Type16 from '@/components/Form/FiltersType/Type16.vue'
|
||||
import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { DxDataGrid } from 'devextreme-vue'
|
||||
import {
|
||||
DxColumn,
|
||||
@ -179,6 +86,7 @@ import {
|
||||
} from 'devextreme-vue/data-grid'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries } from '@/utils/graphql'
|
||||
import { dummyData } from '@/utils/dummy'
|
||||
|
||||
const position = { of: '#data' }
|
||||
const showIndicator = ref(true)
|
||||
@ -224,4 +132,7 @@ const filterData = (params: any) => {
|
||||
}
|
||||
|
||||
const filters = ref()
|
||||
onMounted(() => {
|
||||
data.value = dummyData.gangguan.daftar.daftarGangguanBerdasarkanMedia
|
||||
})
|
||||
</script>
|
||||
|
@ -21,49 +21,49 @@
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1" data-type="number"
|
||||
caption="No" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_laporan"
|
||||
caption="No Laporan" cell-template="cellDefault" />
|
||||
caption="No Laporan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="pembuat_laporan"
|
||||
caption="Pembuat Laporan" cell-template="cellLeft" />
|
||||
caption="Pembuat Laporan" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_lapor"
|
||||
caption="Tgl Lapor" cell-template="cellDefault" />
|
||||
caption="Tgl Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_dialihkan"
|
||||
caption="Tgl Dialihkan" cell-template="cellDefault" />
|
||||
caption="Tgl Dialihkan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_response"
|
||||
caption="Tgl Response" cell-template="cellDefault" />
|
||||
caption="Tgl Response" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_recovery"
|
||||
caption="Tgl Recovery" cell-template="cellDefault" />
|
||||
caption="Tgl Recovery" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_response_time"
|
||||
caption="Durasi Response Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko_lama"
|
||||
caption="Posko Asal" cell-template="cellLeft" />
|
||||
caption="Posko Asal" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko_baru"
|
||||
caption="Posko Tujuan" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="status_akhir"
|
||||
caption="Status" cell-template="cellDefault" />
|
||||
caption="Status" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER" cell-template="cellDefault" />
|
||||
caption="IDPEL/NO METER" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_pelapor"
|
||||
caption="Nama Pelapor" cell-template="cellLeft" />
|
||||
caption="Nama Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor" cell-template="cellLeft" />
|
||||
caption="Alamat Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor" cell-template="cellDefault" />
|
||||
caption="No Telp Pelapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="250" alignment="center" data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor" cell-template="cellLeft" />
|
||||
caption="Keterangan Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="media"
|
||||
caption="Sumber Lapor" cell-template="cellDefault" />
|
||||
caption="Sumber Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko_lama"
|
||||
caption="Posko" cell-template="cellLeft" />
|
||||
caption="Posko" cell-template="cellDefault" />
|
||||
|
||||
<template #cellDefault="{ data }">
|
||||
<template #cellCenter="{ data }">
|
||||
<p class="cursor-pointer" @click="showData()">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #cellLeft="{ data }">
|
||||
<template #cellDefault="{ data }">
|
||||
<p class="text-left cursor-pointer" @click="showData()">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
@ -193,7 +193,7 @@ import {
|
||||
DxSelection
|
||||
} from 'devextreme-vue/data-grid'
|
||||
import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { jsPDF } from 'jspdf'
|
||||
import autoTable from 'jspdf-autotable'
|
||||
import { exportDataGrid as exportToExcel } from 'devextreme/excel_exporter'
|
||||
@ -203,6 +203,7 @@ import DetailDialog from '@/components/Dialogs/DetailDialog.vue'
|
||||
import InputText from '@/components/InputText.vue'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries } from '@/utils/graphql'
|
||||
import { dummyData } from '@/utils/dummy'
|
||||
|
||||
const position = { of: '#dataTable' }
|
||||
const showIndicator = ref(true)
|
||||
@ -350,4 +351,7 @@ const onSelectionChanged = ({ selectedRowsData }: any) => {
|
||||
}
|
||||
const showData = () => showDetail.value = true
|
||||
const filters = ref()
|
||||
onMounted(() => {
|
||||
data.value = dummyData.gangguan.daftar.dialihkanKePoskoLain
|
||||
})
|
||||
</script>
|
||||
|
@ -4,154 +4,61 @@
|
||||
</Filters>
|
||||
|
||||
<div id="data">
|
||||
<DxDataGrid
|
||||
class="max-h-[calc(100vh-140px)] mb-10"
|
||||
:data-source="data"
|
||||
:show-column-lines="true"
|
||||
:show-row-lines="false"
|
||||
:show-borders="true"
|
||||
:row-alternation-enabled="true"
|
||||
:hover-state-enabled="true"
|
||||
@selection-changed=""
|
||||
:column-width="100"
|
||||
@exporting=""
|
||||
:allow-column-resizing="true"
|
||||
column-resizing-mode="widget"
|
||||
>
|
||||
<DxDataGrid class="max-h-[calc(100vh-140px)] mb-10" :data-source="data" :show-column-lines="true"
|
||||
:show-row-lines="false" :show-borders="true" :row-alternation-enabled="true" :hover-state-enabled="true"
|
||||
@selection-changed="" :column-width="100" @exporting="" :allow-column-resizing="true"
|
||||
column-resizing-mode="widget">
|
||||
<DxSelection mode="single" />
|
||||
<DxPaging :page-size="5" :enabled="true" />
|
||||
<DxPager
|
||||
:visible="true"
|
||||
:allowed-page-sizes="[5, 10, 20]"
|
||||
display-mode="full"
|
||||
:show-page-size-selector="true"
|
||||
:show-info="true"
|
||||
:show-navigation-buttons="true"
|
||||
/>
|
||||
<DxLoadPanel
|
||||
:position="position"
|
||||
:show-indicator="showIndicator"
|
||||
:show-pane="showPane"
|
||||
:shading="shading"
|
||||
v-if="loading"
|
||||
v-model:visible="loading"
|
||||
:enabled="true"
|
||||
/>
|
||||
<DxPager :visible="true" :allowed-page-sizes="[5, 10, 20]" display-mode="full" :show-page-size-selector="true"
|
||||
:show-info="true" :show-navigation-buttons="true" />
|
||||
<DxLoadPanel :position="position" :show-indicator="showIndicator" :show-pane="showPane" :shading="shading"
|
||||
v-if="loading" v-model:visible="loading" :enabled="true" />
|
||||
<DxSearchPanel :visible="true" :highlight-case-sensitive="true" />
|
||||
<DxExport
|
||||
:enabled="true"
|
||||
:formats="['pdf', 'xlsx', 'document']"
|
||||
:allow-export-selected-data="false"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="50"
|
||||
alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1"
|
||||
data-type="number"
|
||||
caption="No"
|
||||
/>
|
||||
<DxExport :enabled="true" :formats="['pdf', 'xlsx', 'document']" :allow-export-selected-data="false" />
|
||||
<DxColumn css-class="custom-table-column" :width="50" alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1" data-type="number" caption="No" />
|
||||
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_laporan"
|
||||
caption="No Laporan"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_lapor"
|
||||
caption="Tgl Lapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_response"
|
||||
caption="Tgl Response"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_recovery"
|
||||
caption="Tgl Recovery"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_response_time"
|
||||
caption="Durasi Response Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="status_akhir"
|
||||
caption="Status"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="nama_pelapor"
|
||||
caption="Nama Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="media"
|
||||
caption="Sumber Lapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="nama_posko"
|
||||
caption="Posko"
|
||||
/>
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_laporan"
|
||||
caption="No Laporan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_lapor"
|
||||
caption="Tgl Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_response"
|
||||
caption="Tgl Response" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_recovery"
|
||||
caption="Tgl Recovery" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_response_time"
|
||||
caption="Durasi Response Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="status_akhir"
|
||||
caption="Status" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_pelapor"
|
||||
caption="Nama Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="media"
|
||||
caption="Sumber Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko" caption="Posko"
|
||||
cell-template="cellDefault" />
|
||||
|
||||
<template #cellCenter="{ data }">
|
||||
<p class="cursor-pointer">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #cellDefault="{ data }">
|
||||
<p class="text-left cursor-pointer">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #data-waktu="{ data }">
|
||||
<p>
|
||||
@ -166,7 +73,7 @@
|
||||
import Filters from '@/components/Form/Filters.vue'
|
||||
import Type1 from '@/components/Form/FiltersType/Type1.vue'
|
||||
import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { DxDataGrid } from 'devextreme-vue'
|
||||
import {
|
||||
DxColumn,
|
||||
@ -179,6 +86,7 @@ import {
|
||||
} from 'devextreme-vue/data-grid'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries } from '@/utils/graphql'
|
||||
import { dummyData } from '@/utils/dummy'
|
||||
|
||||
const position = { of: '#data' }
|
||||
const showIndicator = ref(true)
|
||||
@ -226,4 +134,7 @@ const filterData = (params: any) => {
|
||||
}
|
||||
|
||||
const filters = ref()
|
||||
onMounted(() => {
|
||||
data.value = dummyData.gangguan.daftar.daftarGangguanDiselesaikanMobileAPKT
|
||||
})
|
||||
</script>
|
||||
|
@ -4,179 +4,63 @@
|
||||
</Filters>
|
||||
|
||||
<div id="data">
|
||||
<DxDataGrid
|
||||
class="max-h-[calc(100vh-140px)] mb-10"
|
||||
:data-source="data"
|
||||
:show-column-lines="true"
|
||||
:show-row-lines="false"
|
||||
:show-borders="true"
|
||||
:row-alternation-enabled="true"
|
||||
:hover-state-enabled="true"
|
||||
@selection-changed="onSelectionChanged"
|
||||
:column-width="100"
|
||||
@exporting=""
|
||||
:allow-column-resizing="true"
|
||||
column-resizing-mode="widget"
|
||||
>
|
||||
<DxDataGrid class="max-h-[calc(100vh-140px)] mb-10" :data-source="data" :show-column-lines="true"
|
||||
:show-row-lines="false" :show-borders="true" :row-alternation-enabled="true" :hover-state-enabled="true"
|
||||
@selection-changed="onSelectionChanged" :column-width="100" @exporting="" :allow-column-resizing="true"
|
||||
column-resizing-mode="widget">
|
||||
<DxSelection mode="single" />
|
||||
<DxPaging :page-size="5" :enabled="true" />
|
||||
<DxPager
|
||||
:visible="true"
|
||||
:allowed-page-sizes="[5, 10, 20]"
|
||||
display-mode="full"
|
||||
:show-page-size-selector="true"
|
||||
:show-info="true"
|
||||
:show-navigation-buttons="true"
|
||||
/>
|
||||
<DxLoadPanel
|
||||
:position="position"
|
||||
:show-indicator="showIndicator"
|
||||
:show-pane="showPane"
|
||||
:shading="shading"
|
||||
v-if="loading"
|
||||
v-model:visible.sync="loading"
|
||||
:enabled="true"
|
||||
/>
|
||||
<DxPager :visible="true" :allowed-page-sizes="[5, 10, 20]" display-mode="full" :show-page-size-selector="true"
|
||||
:show-info="true" :show-navigation-buttons="true" />
|
||||
<DxLoadPanel :position="position" :show-indicator="showIndicator" :show-pane="showPane" :shading="shading"
|
||||
v-if="loading" v-model:visible.sync="loading" :enabled="true" />
|
||||
<DxSearchPanel :visible="true" :highlight-case-sensitive="true" />
|
||||
<DxExport
|
||||
:enabled="true"
|
||||
:formats="['pdf', 'xlsx', 'document']"
|
||||
:allow-export-selected-data="false"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="50"
|
||||
alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1"
|
||||
data-type="number"
|
||||
caption="No"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_laporan"
|
||||
caption="No Laporan"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_lapor"
|
||||
caption="Tgl Lapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_response"
|
||||
caption="Tgl Response"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_recovery"
|
||||
caption="Tgl Recovery"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
alignment="center"
|
||||
data-field="jumlah_lapor"
|
||||
caption="Jml Lapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_response_time"
|
||||
caption="Durasi Response Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="status_akhir"
|
||||
caption="Status"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="nama_pelapor"
|
||||
caption="Nama Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="media"
|
||||
caption="Sumber Lapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="nama_posko"
|
||||
caption="Posko"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxExport :enabled="true" :formats="['pdf', 'xlsx', 'document']" :allow-export-selected-data="false" />
|
||||
<DxColumn css-class="custom-table-column" :width="50" alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1" data-type="number" caption="No" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_laporan"
|
||||
caption="No Laporan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_lapor"
|
||||
caption="Tgl Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_response"
|
||||
caption="Tgl Response" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_recovery"
|
||||
caption="Tgl Recovery" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" alignment="center" data-field="jumlah_lapor" caption="Jml Lapor"
|
||||
cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_response_time"
|
||||
caption="Durasi Response Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="status_akhir"
|
||||
caption="Status" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_pelapor"
|
||||
caption="Nama Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="media"
|
||||
caption="Sumber Lapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko" caption="Posko"
|
||||
cell-template="cellDefault" />
|
||||
|
||||
<template #data="{ data }">
|
||||
<template #cellCenter="{ data }">
|
||||
<p class="cursor-pointer" @click="showData()">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #cellDefault="{ data }">
|
||||
<p class="text-left cursor-pointer" @click="showData()">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #data-waktu="{ data }">
|
||||
<p class="cursor-pointer" @click="showData()">
|
||||
{{ parseInt(data.text) ? formatWaktu(data.text) : '-' }}
|
||||
@ -185,11 +69,7 @@
|
||||
</DxDataGrid>
|
||||
</div>
|
||||
|
||||
<DetailDialog
|
||||
:open="showDetail"
|
||||
title="Daftar Gangguan Melapor Lebih Dari 1 Kali"
|
||||
@on-close="closeDetail"
|
||||
>
|
||||
<DetailDialog :open="showDetail" title="Daftar Gangguan Melapor Lebih Dari 1 Kali" @on-close="closeDetail">
|
||||
<div class="w-full p-4 space-y-2 bg-white rounded-xl">
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">No Laporan:</h3>
|
||||
@ -218,28 +98,18 @@
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Response Time:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
:value="
|
||||
parseInt(dataDetail?.durasi_response_time)
|
||||
? formatWaktu(dataDetail?.durasi_response_time)
|
||||
: '-'
|
||||
"
|
||||
class-name="flex-1"
|
||||
/>
|
||||
<InputText :readonly="true" :value="parseInt(dataDetail?.durasi_response_time)
|
||||
? formatWaktu(dataDetail?.durasi_response_time)
|
||||
: '-'
|
||||
" class-name="flex-1" />
|
||||
</div>
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Recovery Time:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
class-name="flex-1"
|
||||
:value="
|
||||
parseInt(dataDetail?.durasi_recovery_time)
|
||||
? formatWaktu(dataDetail?.durasi_recovery_time)
|
||||
: '-'
|
||||
"
|
||||
/>
|
||||
<InputText :readonly="true" class-name="flex-1" :value="parseInt(dataDetail?.durasi_recovery_time)
|
||||
? formatWaktu(dataDetail?.durasi_recovery_time)
|
||||
: '-'
|
||||
" />
|
||||
</div>
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
@ -279,12 +149,7 @@
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Unit Layanan Pelanggan:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
type="textarea"
|
||||
:value="dataDetail?.nama_posko"
|
||||
class-name="flex-1 h-[56px]"
|
||||
/>
|
||||
<InputText :readonly="true" type="textarea" :value="dataDetail?.nama_posko" class-name="flex-1 h-[56px]" />
|
||||
</div>
|
||||
</div>
|
||||
</DetailDialog>
|
||||
@ -294,7 +159,7 @@
|
||||
import Filters from '@/components/Form/Filters.vue'
|
||||
import Type6 from '@/components/Form/FiltersType/Type6.vue'
|
||||
import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { DxDataGrid } from 'devextreme-vue'
|
||||
import {
|
||||
DxColumn,
|
||||
@ -309,6 +174,7 @@ import DetailDialog from '@/components/Dialogs/DetailDialog.vue'
|
||||
import InputText from '@/components/InputText.vue'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries } from '@/utils/graphql'
|
||||
import { dummyData } from '@/utils/dummy'
|
||||
|
||||
const position = { of: '#data' }
|
||||
const showIndicator = ref(true)
|
||||
@ -366,4 +232,8 @@ const filterData = (params: any) => {
|
||||
console.log(error)
|
||||
})
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
data.value = dummyData.gangguan.daftar.melaporLebihDariSatuKali
|
||||
})
|
||||
</script>
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -4,174 +4,63 @@
|
||||
</Filters>
|
||||
|
||||
<div id="data">
|
||||
<DxDataGrid
|
||||
class="max-h-[calc(100vh-140px)] mb-10"
|
||||
:data-source="data"
|
||||
:show-column-lines="true"
|
||||
:show-row-lines="false"
|
||||
:show-borders="true"
|
||||
:row-alternation-enabled="true"
|
||||
:hover-state-enabled="true"
|
||||
@selection-changed="onSelectionChanged"
|
||||
:column-width="100"
|
||||
@exporting=""
|
||||
:allow-column-resizing="true"
|
||||
column-resizing-mode="widget"
|
||||
>
|
||||
<DxDataGrid class="max-h-[calc(100vh-140px)] mb-10" :data-source="data" :show-column-lines="true"
|
||||
:show-row-lines="false" :show-borders="true" :row-alternation-enabled="true" :hover-state-enabled="true"
|
||||
@selection-changed="onSelectionChanged" :column-width="100" @exporting="" :allow-column-resizing="true"
|
||||
column-resizing-mode="widget">
|
||||
<DxSelection mode="single" />
|
||||
<DxPaging :page-size="5" :enabled="true" />
|
||||
<DxPager
|
||||
:visible="true"
|
||||
:allowed-page-sizes="[5, 10, 20]"
|
||||
display-mode="full"
|
||||
:show-page-size-selector="true"
|
||||
:show-info="true"
|
||||
:show-navigation-buttons="true"
|
||||
/>
|
||||
<DxLoadPanel
|
||||
:position="position"
|
||||
:show-indicator="showIndicator"
|
||||
:show-pane="showPane"
|
||||
:shading="shading"
|
||||
v-if="loading"
|
||||
v-model:visible="loading"
|
||||
:enabled="true"
|
||||
/>
|
||||
<DxPager :visible="true" :allowed-page-sizes="[5, 10, 20]" display-mode="full" :show-page-size-selector="true"
|
||||
:show-info="true" :show-navigation-buttons="true" />
|
||||
<DxLoadPanel :position="position" :show-indicator="showIndicator" :show-pane="showPane" :shading="shading"
|
||||
v-if="loading" v-model:visible="loading" :enabled="true" />
|
||||
<DxSearchPanel :visible="true" :highlight-case-sensitive="true" />
|
||||
<DxExport
|
||||
:enabled="true"
|
||||
:formats="['pdf', 'xlsx', 'document']"
|
||||
:allow-export-selected-data="false"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="50"
|
||||
alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1"
|
||||
data-type="number"
|
||||
caption="No"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxExport :enabled="true" :formats="['pdf', 'xlsx', 'document']" :allow-export-selected-data="false" />
|
||||
<DxColumn css-class="custom-table-column" :width="50" alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1" data-type="number" caption="No"
|
||||
cell-template="cellCenter" />
|
||||
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_laporan"
|
||||
caption="No Laporan"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_lapor"
|
||||
caption="Tgl Lapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_response"
|
||||
caption="Tgl Response"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_recovery"
|
||||
caption="Tgl Recovery"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_response_time"
|
||||
caption="Durasi Response Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="status_akhir"
|
||||
caption="Status"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="referensi_marking"
|
||||
caption="Referensi Marking"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="nama_pelapor"
|
||||
caption="Nama Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="nama_posko"
|
||||
caption="Posko"
|
||||
cell-template="data"
|
||||
/>
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_laporan"
|
||||
caption="No Laporan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_lapor"
|
||||
caption="Tgl Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_response"
|
||||
caption="Tgl Response" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_recovery"
|
||||
caption="Tgl Recovery" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_response_time"
|
||||
caption="Durasi Response Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="status_akhir"
|
||||
caption="Status" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="referensi_marking"
|
||||
caption="Referensi Marking" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_pelapor"
|
||||
caption="Nama Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko" caption="Posko"
|
||||
cell-template="cellDefault" />
|
||||
|
||||
<template #data="{ data }">
|
||||
<template #cellCenter="{ data }">
|
||||
<p class="cursor-pointer" @click="showData()">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #cellDefault="{ data }">
|
||||
<p class="text-left cursor-pointer" @click="showData()">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #data-waktu="{ data }">
|
||||
<p class="cursor-pointer" @click="showData()">
|
||||
{{ parseInt(data.text) ? formatWaktu(data.text) : '-' }}
|
||||
@ -204,28 +93,18 @@
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Response Time:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
:value="
|
||||
parseInt(dataDetail?.durasi_response_time)
|
||||
? formatWaktu(dataDetail?.durasi_response_time)
|
||||
: '-'
|
||||
"
|
||||
class-name="flex-1"
|
||||
/>
|
||||
<InputText :readonly="true" :value="parseInt(dataDetail?.durasi_response_time)
|
||||
? formatWaktu(dataDetail?.durasi_response_time)
|
||||
: '-'
|
||||
" class-name="flex-1" />
|
||||
</div>
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Recovery Time:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
class-name="flex-1"
|
||||
:value="
|
||||
parseInt(dataDetail?.durasi_recovery_time)
|
||||
? formatWaktu(dataDetail?.durasi_recovery_time)
|
||||
: '-'
|
||||
"
|
||||
/>
|
||||
<InputText :readonly="true" class-name="flex-1" :value="parseInt(dataDetail?.durasi_recovery_time)
|
||||
? formatWaktu(dataDetail?.durasi_recovery_time)
|
||||
: '-'
|
||||
" />
|
||||
</div>
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
@ -265,32 +144,17 @@
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Unit Layanan Pelanggan:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
type="textarea"
|
||||
:value="dataDetail?.nama_posko"
|
||||
class-name="flex-1 h-[56px]"
|
||||
/>
|
||||
<InputText :readonly="true" type="textarea" :value="dataDetail?.nama_posko" class-name="flex-1 h-[56px]" />
|
||||
</div>
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Penyebab:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
type="textarea"
|
||||
:value="dataDetail?.penyebab"
|
||||
class-name="flex-1 h-[56px]"
|
||||
/>
|
||||
<InputText :readonly="true" type="textarea" :value="dataDetail?.penyebab" class-name="flex-1 h-[56px]" />
|
||||
</div>
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Tindakan:</h3>
|
||||
<InputText
|
||||
:readonly="true"
|
||||
type="textarea"
|
||||
:value="dataDetail?.tindakan"
|
||||
class-name="flex-1 h-[56px]"
|
||||
/>
|
||||
<InputText :readonly="true" type="textarea" :value="dataDetail?.tindakan" class-name="flex-1 h-[56px]" />
|
||||
</div>
|
||||
</div>
|
||||
</DetailDialog>
|
||||
@ -300,7 +164,7 @@
|
||||
import Filters from '@/components/Form/Filters.vue'
|
||||
import Type7 from '@/components/Form/FiltersType/Type7.vue'
|
||||
import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { DxDataGrid } from 'devextreme-vue'
|
||||
import {
|
||||
DxColumn,
|
||||
@ -315,6 +179,7 @@ import DetailDialog from '@/components/Dialogs/DetailDialog.vue'
|
||||
import InputText from '@/components/InputText.vue'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries } from '@/utils/graphql'
|
||||
import { dummyData } from '@/utils/dummy'
|
||||
|
||||
const position = { of: '#data' }
|
||||
const showIndicator = ref(true)
|
||||
@ -372,4 +237,7 @@ const { onResult, onError, loading, refetch } = useQuery(queries.gangguan.daftar
|
||||
})
|
||||
|
||||
const filters = ref()
|
||||
onMounted(() => {
|
||||
data.value = dummyData.gangguan.daftar.gangguanResponseTime
|
||||
})
|
||||
</script>
|
||||
|
@ -4,154 +4,61 @@
|
||||
</Filters>
|
||||
|
||||
<div id="data">
|
||||
<DxDataGrid
|
||||
class="max-h-[calc(100vh-140px)] mb-10"
|
||||
:data-source="data"
|
||||
:show-column-lines="true"
|
||||
:show-row-lines="false"
|
||||
:show-borders="true"
|
||||
:row-alternation-enabled="true"
|
||||
:hover-state-enabled="true"
|
||||
@selection-changed=""
|
||||
:column-width="100"
|
||||
@exporting=""
|
||||
:allow-column-resizing="true"
|
||||
column-resizing-mode="widget"
|
||||
>
|
||||
<DxDataGrid class="max-h-[calc(100vh-140px)] mb-10" :data-source="data" :show-column-lines="true"
|
||||
:show-row-lines="false" :show-borders="true" :row-alternation-enabled="true" :hover-state-enabled="true"
|
||||
@selection-changed="" :column-width="100" @exporting="" :allow-column-resizing="true"
|
||||
column-resizing-mode="widget">
|
||||
<DxSelection mode="single" />
|
||||
<DxPaging :page-size="5" :enabled="true" />
|
||||
<DxPager
|
||||
:visible="true"
|
||||
:allowed-page-sizes="[5, 10, 20]"
|
||||
display-mode="full"
|
||||
:show-page-size-selector="true"
|
||||
:show-info="true"
|
||||
:show-navigation-buttons="true"
|
||||
/>
|
||||
<DxLoadPanel
|
||||
:position="position"
|
||||
:show-indicator="showIndicator"
|
||||
:show-pane="showPane"
|
||||
:shading="shading"
|
||||
v-if="loading"
|
||||
v-model:visible="loading"
|
||||
:enabled="true"
|
||||
/>
|
||||
<DxPager :visible="true" :allowed-page-sizes="[5, 10, 20]" display-mode="full" :show-page-size-selector="true"
|
||||
:show-info="true" :show-navigation-buttons="true" />
|
||||
<DxLoadPanel :position="position" :show-indicator="showIndicator" :show-pane="showPane" :shading="shading"
|
||||
v-if="loading" v-model:visible="loading" :enabled="true" />
|
||||
<DxSearchPanel :visible="true" :highlight-case-sensitive="true" />
|
||||
<DxExport
|
||||
:enabled="true"
|
||||
:formats="['pdf', 'xlsx', 'document']"
|
||||
:allow-export-selected-data="false"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="50"
|
||||
alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1"
|
||||
data-type="number"
|
||||
caption="No"
|
||||
/>
|
||||
<DxExport :enabled="true" :formats="['pdf', 'xlsx', 'document']" :allow-export-selected-data="false" />
|
||||
<DxColumn css-class="custom-table-column" :width="50" alignment="center"
|
||||
:calculateCellValue="(item: any) => data.findIndex((i) => i == item) + 1" data-type="number" caption="No" />
|
||||
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_laporan"
|
||||
caption="No Laporan"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_lapor"
|
||||
caption="Tgl Lapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_response"
|
||||
caption="Tgl Response"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="waktu_recovery"
|
||||
caption="Tgl Recovery"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_response_time"
|
||||
caption="Durasi Response Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time"
|
||||
cell-template="data-waktu"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="status_akhir"
|
||||
caption="Status"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="nama_pelapor"
|
||||
caption="Nama Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="150"
|
||||
alignment="center"
|
||||
data-field="media"
|
||||
caption="Sumber Lapor"
|
||||
/>
|
||||
<DxColumn
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="nama_posko"
|
||||
caption="Posko"
|
||||
/>
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_laporan"
|
||||
caption="No Laporan" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_lapor"
|
||||
caption="Tgl Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_response"
|
||||
caption="Tgl Response" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="waktu_recovery"
|
||||
caption="Tgl Recovery" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_response_time"
|
||||
caption="Durasi Response Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="durasi_recovery_time"
|
||||
caption="Durasi Recovery Time" cell-template="data-waktu" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="status_akhir"
|
||||
caption="Status" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="idpel_nometer"
|
||||
caption="IDPEL/NO METER" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="nama_pelapor"
|
||||
caption="Nama Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="alamat_pelapor"
|
||||
caption="Alamat Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="no_telp_pelapor"
|
||||
caption="No Telp Pelapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="keterangan_pelapor"
|
||||
caption="Keterangan Pelapor" cell-template="cellDefault" />
|
||||
<DxColumn css-class="custom-table-column" :width="150" alignment="center" data-field="media"
|
||||
caption="Sumber Lapor" cell-template="cellCenter" />
|
||||
<DxColumn css-class="custom-table-column" :width="170" alignment="center" data-field="nama_posko" caption="Posko"
|
||||
cell-template="cellDefault" />
|
||||
|
||||
<template #cellCenter="{ data }">
|
||||
<p class="cursor-pointer">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #cellDefault="{ data }">
|
||||
<p class="text-left cursor-pointer">
|
||||
{{ data.text }}
|
||||
</p>
|
||||
</template>
|
||||
|
||||
<template #data-waktu="{ data }">
|
||||
<p>
|
||||
@ -161,11 +68,12 @@
|
||||
</DxDataGrid>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import Filters from '@/components/Form/Filters.vue'
|
||||
import Type1 from '@/components/Form/FiltersType/Type1.vue'
|
||||
import { formatWaktu } from '@/components/Form/FiltersType/reference'
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { DxDataGrid } from 'devextreme-vue'
|
||||
import {
|
||||
DxColumn,
|
||||
@ -178,6 +86,7 @@ import {
|
||||
} from 'devextreme-vue/data-grid'
|
||||
import { useQuery } from '@vue/apollo-composable'
|
||||
import { queries } from '@/utils/graphql'
|
||||
import { dummyData } from '@/utils/dummy'
|
||||
|
||||
const position = { of: '#data' }
|
||||
const showIndicator = ref(true)
|
||||
@ -221,4 +130,7 @@ const filterData = (params: any) => {
|
||||
}
|
||||
|
||||
const filters = ref()
|
||||
onMounted(() => {
|
||||
data.value = dummyData.gangguan.daftar.daftarGangguanSelesaiTanpaIdPelanggan
|
||||
})
|
||||
</script>
|
||||
|
Loading…
x
Reference in New Issue
Block a user