Revert "TP-66615 | Imperonsation check added" (#823)
This commit is contained in:
Submodule RN-UI-LIB updated: 76786d25a3...f8795144b2
@@ -48,7 +48,7 @@ export const getSelfieDocument =
|
||||
.then((res) => {
|
||||
const { documents, agencyName, agencyCode } = res.data;
|
||||
if (res.data?.documents?.[0]) {
|
||||
const { originalDocumentUri, optimizedDocumentUri, approvalStatus, comment, referenceId } =
|
||||
const { originalDocumentUri, optimizedDocumentUri, approvalStatus, comment } =
|
||||
documents?.[0] || {};
|
||||
dispatch(
|
||||
setOriginalImageDetails({
|
||||
@@ -58,7 +58,6 @@ export const getSelfieDocument =
|
||||
agencyCode: agencyCode || '',
|
||||
optimizedImageUri: optimizedDocumentUri || '',
|
||||
comment: comment || '',
|
||||
documentRefId: referenceId || ''
|
||||
})
|
||||
);
|
||||
|
||||
@@ -73,7 +72,6 @@ export const getSelfieDocument =
|
||||
agencyCode: agencyCode || '',
|
||||
comment: '',
|
||||
approvalStatus: ImageApprovalStatus.NOT_INITIATED,
|
||||
documentRefId: ''
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
@@ -223,7 +223,7 @@ const BlockerScreen = (props: IBlockerScreen) => {
|
||||
});
|
||||
return <BlockerScreenApps blacklistedAppsInstalled={blacklistedAppsInstalled} />;
|
||||
}
|
||||
if (IdCardBlockStatus[approvalStatus as keyof typeof IdCardBlockStatus] && isFieldAgent && !GLOBAL.IS_IMPERSONATED) {
|
||||
if (IdCardBlockStatus[approvalStatus as keyof typeof IdCardBlockStatus] && isFieldAgent) {
|
||||
return (
|
||||
<>
|
||||
<FullScreenLoader loading={isLoading} />
|
||||
|
||||
@@ -29,7 +29,6 @@ const initialState = {
|
||||
optimizedImageUri: '',
|
||||
showApprovedModal: false,
|
||||
isLoading: false,
|
||||
documentRefId: ''
|
||||
};
|
||||
|
||||
export const profileSlice = createSlice({
|
||||
@@ -47,7 +46,6 @@ export const profileSlice = createSlice({
|
||||
agencyName,
|
||||
agencyCode,
|
||||
comment,
|
||||
documentRefId
|
||||
} = action.payload;
|
||||
state.originalImageUri = originalImageUri;
|
||||
state.approvalStatus = approvalStatus;
|
||||
@@ -55,7 +53,6 @@ export const profileSlice = createSlice({
|
||||
state.agencyCode = agencyCode;
|
||||
state.optimizedImageUri = optimizedImageUri;
|
||||
state.comment = comment;
|
||||
state.documentRefId = documentRefId;
|
||||
},
|
||||
setIsUploadingImage: (state, action) => {
|
||||
state.isUploadingImage = action.payload;
|
||||
|
||||
@@ -38,15 +38,13 @@ const Profile: React.FC = () => {
|
||||
const supportLink = useAppSelector((state) => state.config.data?.supportLink);
|
||||
const isTeamLead = useAppSelector((state) => state.user.isTeamLead);
|
||||
const referenceId = useAppSelector((state) => state.user.user?.referenceId);
|
||||
const documentRefId = useAppSelector((state) => state.profile?.documentRefId);
|
||||
|
||||
const showAttendanceBanner = useAppSelector(
|
||||
(state) => state.user?.agentAttendance?.showAttendanceBanner
|
||||
);
|
||||
const originalImageUri = useAppSelector((state) => state.profile?.originalImageUri);
|
||||
|
||||
const cacheDirectory = RNFS.CachesDirectoryPath;
|
||||
const cacheFilePath = `${cacheDirectory}/${documentRefId}_${name}.jpg`;
|
||||
const cacheFilePath = `${cacheDirectory}/${phoneNumber}_${name}.jpg`;
|
||||
|
||||
useFocusEffect(
|
||||
React.useCallback(() => {
|
||||
@@ -110,7 +108,7 @@ const Profile: React.FC = () => {
|
||||
/>
|
||||
<CachedImage
|
||||
highQualityUri={originalImageUri}
|
||||
cacheFileKey={`${documentRefId}_${name}`}
|
||||
cacheFileKey={`${phoneNumber}_${name}`}
|
||||
preCache={true}
|
||||
/>
|
||||
<ScrollView
|
||||
|
||||
Reference in New Issue
Block a user