Fixed Invoicing Problem and some other Changes
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
<script setup>
|
||||
const route = useRoute()
|
||||
const dataStore = useDataStore()
|
||||
const supabase = useSupabaseClient()
|
||||
|
||||
const type = route.params.type
|
||||
|
||||
@@ -19,7 +20,17 @@ const setupPage = async () => {
|
||||
item.value = await useSupabaseSelectSingle(type, route.params.id, dataType.supabaseSelectWithInformation || "*")
|
||||
} else if(mode.value === "edit") {
|
||||
//Load Data for Edit
|
||||
item.value = await useSupabaseSelectSingle(type, route.params.id)
|
||||
const data = JSON.stringify((await supabase.from(type).select().eq("id", route.params.id).single()).data)
|
||||
//await useSupabaseSelectSingle(type, route.params.id)
|
||||
console.log(JSON.parse(data))
|
||||
item.value = data
|
||||
|
||||
console.log(item.value)
|
||||
} else if(mode.value === "create") {
|
||||
//Load Data for Create
|
||||
item.value = JSON.stringify({})
|
||||
|
||||
console.log(item.value)
|
||||
} else if(mode.value === "list") {
|
||||
//Load Data for List
|
||||
items.value = await useSupabaseSelect(type, dataType.supabaseSelectWithInformation || "*", dataType.supabaseSortColumn)
|
||||
|
||||
Reference in New Issue
Block a user