Refactor code in reference.ts

This commit is contained in:
Dede Fuji Abdul 2024-02-29 17:40:46 +07:00
parent ceccc31e95
commit 725c8ad561

View File

@ -1,7 +1,5 @@
import { usePostsStore } from '@/stores/posts'
import { useRegionStore } from '@/stores/region'
import { useUlpStore } from '@/stores/ulp'
import { useUp3Store } from '@/stores/up3'
import { getUid, getUp3, getPosko, getUlp, getRegional, getUidRegional } from '@/utils/network'
import { ref } from 'vue'
interface Item {
@ -132,7 +130,7 @@ const fetchRegional = async () => {
const res = await getRegional()
itemsRegional.value = res.data.map((item: any) => ({
id: item.id,
name: item.nama.toUpperCase()
name: String(item.nama).toUpperCase()
}))
} catch (error) {
console.error('Error fetching data:', error)