@ -234,11 +234,9 @@ Raymer * @version 1.0.0 */
: last - viewed - claim - id = "feedLastViewedClaimId"
: last - viewed - claim - id = "feedLastViewedClaimId"
: is - registered = "isRegistered"
: is - registered = "isRegistered"
: active - did = "activeDid"
: active - did = "activeDid"
: confirmer - id - list = "record.confirmerIdList"
: on - image - cache = "cacheImageData"
: on - image - cache = "cacheImageData"
@ load - claim = "onClickLoadClaim"
@ load - claim = "onClickLoadClaim"
@ view - image = "openImageViewer"
@ view - image = "openImageViewer"
@ confirm - claim = "confirmClaim"
/ >
/ >
< / ul >
< / ul >
< / InfiniteScroll >
< / InfiniteScroll >
@ -306,14 +304,12 @@ import {
OnboardPage ,
OnboardPage ,
} from "../libs/util" ;
} from "../libs/util" ;
import { GiveSummaryRecord } from "../interfaces/records" ;
import { GiveSummaryRecord } from "../interfaces/records" ;
import * as serverUtil from "../libs/endorserServer" ;
import { logger } from "../utils/logger" ;
import { logger } from "../utils/logger" ;
import { GiveRecordWithContactInfo } from "../interfaces/give" ;
import { GiveRecordWithContactInfo } from "../interfaces/give" ;
import { PlatformServiceMixin } from "@/utils/PlatformServiceMixin" ;
import { PlatformServiceMixin } from "@/utils/PlatformServiceMixin" ;
import { createNotifyHelpers , TIMEOUTS } from "@/utils/notify" ;
import { createNotifyHelpers , TIMEOUTS } from "@/utils/notify" ;
import {
import {
NOTIFY_CONTACT_LOADING_ISSUE ,
NOTIFY_CONTACT_LOADING_ISSUE ,
NOTIFY_CONFIRMATION_ERROR ,
} from "@/constants/notifications" ;
} from "@/constants/notifications" ;
import * as Package from "../../package.json" ;
import * as Package from "../../package.json" ;
@ -1716,53 +1712,6 @@ export default class HomeView extends Vue {
this . isImageViewerOpen = true ;
this . isImageViewerOpen = true ;
}
}
/ * *
* Handles claim confirmation
*
* @ public
* Called by ActivityListItem component
* @ param record Record to confirm
* /
async confirmClaim ( record : GiveRecordWithContactInfo ) {
this . notify . confirm (
"Do you personally confirm that this is true?" ,
async ( ) => {
const goodClaim = serverUtil . removeSchemaContext (
serverUtil . removeVisibleToDids (
serverUtil . addLastClaimOrHandleAsIdIfMissing (
record . fullClaim ,
record . jwtId ,
record . handleId ,
) ,
) ,
) ;
const confirmationClaim = {
"@context" : "https://schema.org" ,
"@type" : "AgreeAction" ,
object : goodClaim ,
} ;
const result = await serverUtil . createAndSubmitClaim (
confirmationClaim ,
this . activeDid ,
this . apiServer ,
this . axios ,
) ;
if ( result . success ) {
this . notify . confirmationSubmitted ( ) ;
/ / R e f r e s h t h e f e e d t o s h o w u p d a t e d c o n f i r m a t i o n s t a t u s
await this . updateAllFeed ( ) ;
} else {
logger . error ( "Error submitting confirmation:" , result ) ;
this . notify . error ( NOTIFY_CONFIRMATION_ERROR . message , TIMEOUTS . LONG ) ;
}
} ,
) ;
}
private handleQRCodeClick ( ) {
private handleQRCodeClick ( ) {
if ( Capacitor . isNativePlatform ( ) ) {
if ( Capacitor . isNativePlatform ( ) ) {
this . $router . push ( { name : "contact-qr-scan-full" } ) ;
this . $router . push ( { name : "contact-qr-scan-full" } ) ;