| 
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -4,7 +4,7 @@ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					  <section id="Content" class="p-6 pb-24 max-w-3xl mx-auto"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    <!-- Breadcrumb --> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    <div id="ViewBreadcrumb" class="mb-8"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      <h1 class="text-lg text-center font-light relative px-7" > | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      <h1 class="text-lg text-center font-light relative px-7"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        <!-- Back --> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        <fa | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          icon="chevron-left" | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -31,11 +31,18 @@ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    <div v-if="showOffersDetails" class="ml-4"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      <ul> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        <li v-for="offer in newOffersToUser" :key="offer.id" class="mt-2"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <span>{{ didInfo(offer.offeredByDid, activeDid, allMyDids, allContacts) }}</span> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <span>{{ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            didInfo(offer.offeredByDid, activeDid, allMyDids, allContacts) | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          }}</span> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          offers | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <span v-if="offer.description">{{ offer.description }}</span> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <span v-if="offer.amount">{{ displayAmount(offer.unit, offer.amount) }}</span> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <router-link :to="{ path: '/claim/' + encodeURIComponent(offer.jwtId) }" class="text-blue-500"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <span v-if="offer.amount">{{ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            displayAmount(offer.unit, offer.amount) | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          }}</span> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          <router-link | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            :to="{ path: '/claim/' + encodeURIComponent(offer.jwtId) }" | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            class="text-blue-500" | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          > | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            <fa icon="file-lines" class="pl-2 text-blue-500 cursor-pointer" /> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          </router-link> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        </li> | 
				
			
			
		
	
	
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
				
				 | 
				
					@ -46,7 +53,6 @@ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					<script lang="ts"> | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { Component, Vue } from "vue-facing-decorator"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { Router } from "vue-router"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import GiftedDialog from "@/components/GiftedDialog.vue"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import QuickNav from "@/components/QuickNav.vue"; | 
				
			
			
		
	
	
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
				
				 | 
				
					@ -54,7 +60,12 @@ import EntityIcon from "@/components/EntityIcon.vue"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { NotificationIface } from "@/constants/app"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { accountsDB, db, retrieveSettingsForActiveAccount } from "@/db/index"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { Contact } from "@/db/tables/contacts"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { didInfo,displayAmount, getNewOffersToUser, OfferSummaryRecord } from "@/libs/endorserServer"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					  didInfo, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					  displayAmount, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					  getNewOffersToUser, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					  OfferSummaryRecord, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					} from "@/libs/endorserServer"; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					@Component({ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					  components: { GiftedDialog, QuickNav, EntityIcon }, | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -88,8 +99,12 @@ export default class NewActivityView extends Vue { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      if (allAccounts.length > 0) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        this.allMyDids = allAccounts.map((acc) => acc.did); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      this.newOffersToUser = | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        await getNewOffersToUser(this.axios, this.apiServer, this.activeDid, this.lastAckedOfferToUserJwtId); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      this.newOffersToUser = await getNewOffersToUser( | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        this.axios, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        this.apiServer, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        this.activeDid, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        this.lastAckedOfferToUserJwtId, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      ); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      // eslint-disable-next-line @typescript-eslint/no-explicit-any | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    } catch (err: any) { | 
				
			
			
		
	
	
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
				
				 | 
				
					@ -99,9 +114,7 @@ export default class NewActivityView extends Vue { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          group: "alert", | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          type: "danger", | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          title: "Error", | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          text: | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            err.message || | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            "There was an error retrieving your activity.", | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					          text: err.message || "There was an error retrieving your activity.", | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        }, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        5000, | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					      ); | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
				
				 | 
				
					
  |