Exportar excel con imagen y ahora guarda las imagenes como .png
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
'use server';
|
||||
import { safeFetchApi } from '@/lib';
|
||||
import { safeFetchApi } from '@/lib/fetch.api';
|
||||
import { loginResponseSchema, UserFormValue } from '../schemas/login';
|
||||
|
||||
type LoginActionSuccess = {
|
||||
@@ -20,9 +20,9 @@ type LoginActionSuccess = {
|
||||
}
|
||||
|
||||
type LoginActionError = {
|
||||
type: 'API_ERROR' | 'VALIDATION_ERROR' | 'UNKNOWN_ERROR'; // **Asegúrate de que el tipo de `type` sea este aquí**
|
||||
message: string;
|
||||
details?: any;
|
||||
type: 'API_ERROR' | 'VALIDATION_ERROR' | 'UNKNOWN_ERROR'; // **Asegúrate de que el tipo de `type` sea este aquí**
|
||||
message: string;
|
||||
details?: any;
|
||||
};
|
||||
|
||||
// Si SignInAction también puede devolver null, asegúralo en su tipo de retorno
|
||||
@@ -37,7 +37,7 @@ export const SignInAction = async (payload: UserFormValue): Promise<LoginActionR
|
||||
);
|
||||
if (error) {
|
||||
return {
|
||||
type: error.type as 'API_ERROR' | 'VALIDATION_ERROR' | 'UNKNOWN_ERROR',
|
||||
type: error.type as 'API_ERROR' | 'VALIDATION_ERROR' | 'UNKNOWN_ERROR',
|
||||
message: error.message,
|
||||
details: error.details
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user