erp-platform/ui/src/proxy/account/models.ts

20 lines
484 B
TypeScript
Raw Normal View History

2025-05-06 06:45:49 +00:00
import { ExtensibleObject } from '..'
import { SignInResponse } from '../../@types/auth'
2025-05-06 06:45:49 +00:00
export interface ProfileDto extends ExtensibleObject {
email: string
phoneNumber: string
name: string
surname: string
}
export interface UpdateProfileDto {
name: string
surname: string
avatar?: File
}
export const isLoginSuccess = (data: unknown): data is SignInResponse => {
return typeof data === 'object' && data !== null && 'access_token' in data && !!data.access_token
}