From cf6da809621b4ebe8c9acedb035b689e7e1b60b1 Mon Sep 17 00:00:00 2001 From: Rafi Zadanly Date: Wed, 25 Oct 2023 17:27:32 +0700 Subject: Update register page --- src-migrate/common/types/auth.ts | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) (limited to 'src-migrate/common/types') diff --git a/src-migrate/common/types/auth.ts b/src-migrate/common/types/auth.ts index 63fac6e0..3d9ffee4 100644 --- a/src-migrate/common/types/auth.ts +++ b/src-migrate/common/types/auth.ts @@ -22,11 +22,32 @@ export type RegisterProps = { email: string; password: string; company: string; + phone: string; +}; + +export type RegisterResApiProps = { + register: boolean; + reason: 'EMAIL_USED' | null; +}; + +type ActivationResProps = { + activation: boolean; + user: AuthProps | null; +}; + +export type ActivationTokenProps = { + token: string; +}; + +export type ActivationTokenResApiProps = ActivationResProps & { + reason: 'INVALID_TOKEN' | null; +}; + +export type ActivationOtpProps = { + email: string; + otp: string; }; -export type RegisterApiProps = OdooApiProps & { - result: { - register: boolean; - reason?: 'EMAIL_USED'; - }; +export type ActivationOtpResApiProps = ActivationResProps & { + reason: 'INVALID_OTP' | null; }; -- cgit v1.2.3