upd: api update

This commit is contained in:
2025-12-15 12:17:59 +08:00
parent dcd072034c
commit 3baba059ab

View File

@@ -791,6 +791,7 @@ const PelayananRoute = new Elysia({
jenis: item.jenis,
}
})
console.log(hasil, item)
if (hasil && hasil.id) {
const upd = await prisma.syaratDokumenPelayanan.upsert({
@@ -808,16 +809,8 @@ const PelayananRoute = new Elysia({
}
})
} else {
const newData = await prisma.syaratDokumenPelayanan.create({
data: {
value: item.value,
jenis: item.jenis,
idPengajuanLayanan: pengajuan.id,
idCategory: pengajuan.idCategory,
}
})
return { success: false, message: 'dokumen tidak dapat diupload' }
}
}
}