fix: nama_regu -> nama_petugas in pencarianData
This commit is contained in:
parent
7a70812b2e
commit
581801e098
@ -363,6 +363,7 @@ import InputText from '@/components/InputText.vue'
|
||||
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'
|
||||
import { readDataJson } from '@/utils/storage'
|
||||
|
||||
const data = ref<any[]>([])
|
||||
const dataSelected = ref<any>()
|
||||
@ -434,6 +435,8 @@ const reportMeta = ref({
|
||||
})
|
||||
|
||||
onMounted(() => {
|
||||
// console.log(readDataJson('filterPresets'))
|
||||
|
||||
if (import.meta.env.DEV) {
|
||||
data.value = [
|
||||
{
|
||||
|
@ -131,7 +131,7 @@
|
||||
css-class="custom-table-column"
|
||||
:width="170"
|
||||
alignment="center"
|
||||
data-field="nama_regu"
|
||||
data-field="nama_petugas"
|
||||
caption="Petugas"
|
||||
cell-template="formatText"
|
||||
/>
|
||||
@ -223,7 +223,7 @@
|
||||
|
||||
<div class="flex flex-row items-center justify-between w-full">
|
||||
<h3 class="text-sm font-medium w-[170px] text-gray-800">Petugas:</h3>
|
||||
<InputText :readonly="true" :value="dataSelected?.nama_regu" class-name="flex-1" />
|
||||
<InputText :readonly="true" :value="dataSelected?.nama_petugas" class-name="flex-1" />
|
||||
</div>
|
||||
</div>
|
||||
</DetailDialog>
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { ref, computed } from 'vue'
|
||||
import { defineStore } from 'pinia'
|
||||
import { dispatchNotification } from '@/components/Notification'
|
||||
import { readData, removeData, writeData } from '@/utils/storage'
|
||||
import { readData, removeData, writeData, writeDataJson } from '@/utils/storage'
|
||||
import router from '@/router'
|
||||
|
||||
export const useAuthStore = defineStore('auth', () => {
|
||||
@ -12,6 +12,12 @@ export const useAuthStore = defineStore('auth', () => {
|
||||
const password = ref('')
|
||||
const isLoading = ref(false)
|
||||
const isLoggedIn = computed(() => token.value !== '')
|
||||
const filterPresets = {
|
||||
uid: {
|
||||
id: 2,
|
||||
name: 'DISTRIBUSI JAKARTA RAYA'
|
||||
}
|
||||
}
|
||||
|
||||
// define your actions
|
||||
const login = () => {
|
||||
@ -28,6 +34,8 @@ export const useAuthStore = defineStore('auth', () => {
|
||||
if (username.value == 'demo' && password.value == 'demo') {
|
||||
// store token in localStorage
|
||||
writeData('token', 'secret-token')
|
||||
writeDataJson('filterPresets', filterPresets)
|
||||
|
||||
dispatchNotification({
|
||||
title: 'Berhasil',
|
||||
content: 'Login berhasil, selamat datang kembali!',
|
||||
@ -46,7 +54,10 @@ export const useAuthStore = defineStore('auth', () => {
|
||||
}
|
||||
}
|
||||
|
||||
const logout = () => removeData('token')
|
||||
const logout = () => {
|
||||
removeData('token')
|
||||
removeData('filterPresets')
|
||||
}
|
||||
|
||||
return {
|
||||
token,
|
||||
|
Loading…
x
Reference in New Issue
Block a user