mirror of
https://github.com/mosip/inji-wallet.git
synced 2026-01-09 13:38:01 -05:00
fix(INJI-262):pinned VC's audit logs are missing
This commit is contained in:
@@ -8,6 +8,7 @@ import { ActorRefFrom } from 'xstate';
|
||||
import { vcItemMachine } from '../../../machines/vcItem';
|
||||
import { useKebabPopUp } from '../../../components/KebabPopUpController';
|
||||
import { Theme } from '../../../components/ui/styleUtils';
|
||||
import { isVcKeyMatch } from '../../../shared/constants';
|
||||
|
||||
export const HistoryTab: React.FC<HistoryTabProps> = (props) => {
|
||||
const { t } = useTranslation('HistoryTab');
|
||||
@@ -30,7 +31,8 @@ export const HistoryTab: React.FC<HistoryTabProps> = (props) => {
|
||||
onDismiss={controller.DISMISS}>
|
||||
<Column fill>
|
||||
{controller.activities.map((activity) => {
|
||||
if (activity._vcKey.split(':')[3] == props.vcKey.split(':')[3]) {
|
||||
const vcKeyMatch = isVcKeyMatch(activity._vcKey, props.vcKey);
|
||||
if (vcKeyMatch) {
|
||||
return (
|
||||
<ActivityLogText
|
||||
key={`${activity.timestamp}-${activity._vcKey}`}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import { Platform } from 'react-native';
|
||||
import { VC } from '../types/vc';
|
||||
import {
|
||||
MIMOTO_HOST,
|
||||
@@ -21,6 +22,11 @@ export const VC_ITEM_STORE_KEY = (vc: Partial<VC>) =>
|
||||
export const VC_ITEM_STORE_KEY_REGEX =
|
||||
'^vc:(UIN|VID):[0-9]+:[a-z0-9-]+:[true|false]+$';
|
||||
|
||||
//To compare the vckey with requestId, when the vc is pinned
|
||||
export const isVcKeyMatch = (vckey: string, CompareVckey: string) => {
|
||||
return vckey.split(':')[3] === CompareVckey.split(':')[3];
|
||||
};
|
||||
|
||||
export let individualId = '';
|
||||
|
||||
export const GET_INDIVIDUAL_ID = (ind_Id: string) => {
|
||||
@@ -47,3 +53,7 @@ export const APP_ID_DICTIONARY = [
|
||||
'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'J', 'K', 'L',
|
||||
'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y',
|
||||
];
|
||||
|
||||
export function isIOS(): boolean {
|
||||
return Platform.OS === 'ios';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user