-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add contact page and change logo position
Add route for get-wallet-code # Conflicts: # components/PresentationForm.vue
- Loading branch information
Showing
5 changed files
with
99 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
<template> | ||
<div> | ||
<div class="text-xl lg:text-3xl font-bold text-accent m-6 text-center"> | ||
<h1>Ihre Daten</h1> | ||
</div> | ||
<div v-if="errorMessage" class="mx-6 p-4 border-red-400 border rounded text-red-500"> | ||
<p>{{ errorMessage }}</p> | ||
</div> | ||
<div v-else class="mx-6 py-4 border-neutral-400 border rounded"> | ||
<div class="overflow-x-auto"> | ||
<table class="table w-full"> | ||
<tbody> | ||
<tr v-for="item in dataList" :key="item.kind"> | ||
<td>{{ item.kind }}</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script setup lang="ts"> | ||
import axios from "axios"; | ||
import {ref, onMounted} from 'vue'; | ||
import type {TransactionRequest} from "~/models/TransactionRequest"; | ||
const runtimeConfig = useRuntimeConfig() | ||
const baseUrl = runtimeConfig.public.apiUrl | ||
const dataList = ref<{ kind: string }[]>([]); | ||
const errorMessage = ref<string | null>(null); | ||
onMounted(async () => { | ||
const sessionStore = useSessionStore(); | ||
const presentationId = sessionStore.presentationId | ||
const route = useRoute() | ||
const responseCode = route.query.response_code | ||
const nonce = route.query.nonce | ||
if (responseCode && presentationId) { | ||
try { | ||
const response = await axios.get<TransactionRequest>( | ||
`${baseUrl}/ui/presentations` | ||
); | ||
const presentationResponse = response.data; | ||
if (nonce !== presentationResponse.nonce) { | ||
errorMessage.value = 'Nonce ist falsch'; | ||
return; | ||
} | ||
const regex = /^\$\['[^']+'\]/; | ||
dataList.value = presentationResponse.presentation_definition.input_descriptors[0].constraints.fields.map(field => ({ | ||
kind: field.path[0].replace(regex, '') | ||
})); | ||
sessionStore.$reset(); | ||
} catch (error) { | ||
errorMessage.value = 'Fehler beim Abrufen der Daten'; | ||
} | ||
} else { | ||
errorMessage.value = 'Fehler beim Abrufen der Daten'; | ||
} | ||
}); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<template> | ||
<div class="text-center p-2"> | ||
<h1 class="text-accent text-3xl font-bold p-2">TICE GmbH </h1> | ||
<p> | ||
Alexandrinenstraße 4 | ||
<br> | ||
10969 | ||
<br> | ||
Berlin | ||
</p> | ||
<br> | ||
<h2 class="text-accent text-xl font-semibold p-2">Kontakt</h2> | ||
<p> | ||
Telefon: +493062939267 | ||
<br> | ||
E-Mail: [email protected] | ||
</p> | ||
</div> | ||
</template> |