diff --git a/src/components/Verification/ProofRequestPopup.tsx b/src/components/Verification/ProofRequestPopup.tsx index 170225a95..b7b2d03dd 100644 --- a/src/components/Verification/ProofRequestPopup.tsx +++ b/src/components/Verification/ProofRequestPopup.tsx @@ -189,7 +189,7 @@ const ProofRequest = (props: IProofRrquestDetails) => {

Verified Details

- {!props.userData ? ( + {props.verifyLoading ? (
@@ -206,16 +206,17 @@ const ProofRequest = (props: IProofRrquestDetails) => { )}
- +
diff --git a/src/components/Verification/VerificationCredentialList.tsx b/src/components/Verification/VerificationCredentialList.tsx index 14f30bd0a..29cca4dca 100644 --- a/src/components/Verification/VerificationCredentialList.tsx +++ b/src/components/Verification/VerificationCredentialList.tsx @@ -52,6 +52,7 @@ const VerificationCredentialList = () => { const [listAPIParameter, setListAPIParameter] = useState(initialPageState); const [totalItem, setTotalItem] = useState(0); + const [verifyLoading, setVerifyLoading]= useState(true) const [pageInfo, setPageInfo] = useState({ totalItem: '', nextPage: '', @@ -60,14 +61,17 @@ const VerificationCredentialList = () => { const getProofPresentationData = async (proofId: string) => { try { + setVerifyLoading(true) const orgId = await getFromLocalStorage(storageKeys.ORG_ID); const response = await getVerifiedProofDetails(proofId, orgId); const { data } = response as AxiosResponse; if (data?.statusCode === apiStatusCodes?.API_STATUS_SUCCESS) { setUserData(data?.data); + setVerifyLoading(false) } else { setErrMsg(response as string); + setVerifyLoading(false) } } catch (error) { throw error; @@ -102,8 +106,6 @@ const VerificationCredentialList = () => { const { data } = response as AxiosResponse; if (data?.statusCode === apiStatusCodes.API_STATUS_SUCCESS) { const { totalItems, nextPage, lastPage } = data.data; - console.log('data.data', data.data); - setPageInfo({ totalItem: totalItems, nextPage: nextPage, @@ -435,11 +437,12 @@ const VerificationCredentialList = () => { {userData && ( openProofRequestModel(false, '', '')} + closeModal={() => {openProofRequestModel(false, '', '')}} onSucess={requestProof} requestId={requestId} userData={userData} view={view} + verifyLoading={verifyLoading} /> )} diff --git a/src/components/Verification/interface.ts b/src/components/Verification/interface.ts index a49940da6..7bb0d1ea1 100644 --- a/src/components/Verification/interface.ts +++ b/src/components/Verification/interface.ts @@ -38,6 +38,7 @@ export interface SchemaDetails { } export interface IProofRrquestDetails { + verifyLoading: boolean; openModal: boolean; closeModal: (flag: boolean, id: string, state: boolean) => void; onSucess: (verifyPresentationId: string) => void;