Replace mysql2 with prisma

also I updated packages,
and properly typed api input
a lot of time was spent, I don't remeber what really I did x3
but everything was related to replacing mysql2 with prisma
This commit is contained in:
Wroclaw 2023-11-08 05:35:48 +01:00
parent be1e3909b6
commit eebf25198d
39 changed files with 1081 additions and 1292 deletions

View file

@ -1,8 +1,10 @@
<script setup lang="ts">
import { type order as orderType } from '~/utils/types/database';
import type { useFetch } from '#imports';
type Order = Awaited<ReturnType<typeof useFetch<void, any, "/api/orders/:id", "get">>>["data"]["value"];
const props = defineProps<{
order?: orderType
order?: Order | undefined
}>();
</script>
@ -24,7 +26,7 @@ const props = defineProps<{
</thead>
<tbody>
<tr v-for="i in props.order.work" :key="i.id">
<td>{{ i.is_fulfilled }}</td>
<td>{{ i.fulfilled }}</td>
<td>
{{ i.offer.name }}
</td>