export default defineEventHandler(async (event) => { const user =event.context.sessions?event.context.sessions.user.id: event.context.params?.user const service = event.context.params?.service if (!user) { throw new Error("User not found") } if (!service) { throw new Error("Service not found") } console.log("user:",user) console.log("service:",service)
<UTable :columns="columns" :rows="services" class="card rounded-md w-1/2"> <template #actions-data="{ row }"> <UButton color="gray" variant="ghost" icon="i-heroicons-trash-20-solid" /> <UButton color="gray" variant="ghost" icon="i-heroicons-pencil-square-20-solid" /> </template> </UTable>