upd: login tanpa otp

Deskripsi:
- struktur db
- update api
- update api version app

No Issues
This commit is contained in:
2025-09-02 14:38:32 +08:00
parent a533f3b085
commit dfa7b571f1
3 changed files with 18 additions and 16 deletions

View File

@@ -7,7 +7,7 @@ export async function POST(req: NextRequest) {
const { phone }: ILogin = await req.json();
const user = await prisma.user.findUnique({
where: { phone, isActive: true },
select: { id: true, phone: true },
select: { id: true, phone: true, isWithoutOTP: true },
});
if (!user) {
@@ -21,6 +21,7 @@ export async function POST(req: NextRequest) {
success: true,
message: "Sukses",
phone: user.phone,
isWithoutOTP: user.isWithoutOTP,
id: user.id,
});