mirror of
https://github.com/IT4Change/gradido.git
synced 2026-02-06 01:46:07 +00:00
next try for disbursementJwt mapping
This commit is contained in:
parent
4b901dc1dc
commit
28bd35ca2a
@ -191,7 +191,14 @@ export class TransactionLinkResolver {
|
||||
throw new LogError('Invalid JWT payload', payload)
|
||||
}
|
||||
if (payload.tokentype === DisbursementJwtPayloadType.REDEEM_ACTIVATION_TYPE) {
|
||||
const disburseJwtPayload: DisbursementJwtPayloadType = payload
|
||||
const disburseJwtPayload = new DisbursementJwtPayloadType(
|
||||
payload.sendercommunityuuid as string,
|
||||
payload.sendergradidoid as string,
|
||||
payload.sendername as string,
|
||||
payload.redeemcode as string,
|
||||
payload.amount as string,
|
||||
payload.memo as string,
|
||||
)
|
||||
logger.debug(
|
||||
'TransactionLinkResolver.queryTransactionLink... disburseJwtPayload=',
|
||||
disburseJwtPayload,
|
||||
|
||||
@ -102,6 +102,7 @@ const validLink = computed(() => {
|
||||
})
|
||||
|
||||
const itemType = computed(() => {
|
||||
console.log('TransactionLink.itemType... referrer=', referrer.value, meta.referrer)
|
||||
if (linkData.value.deletedAt) {
|
||||
console.log('TransactionLink.itemType... TEXT_DELETED')
|
||||
return 'TEXT_DELETED'
|
||||
@ -133,7 +134,7 @@ const itemType = computed(() => {
|
||||
})
|
||||
|
||||
const itemTypeExt = computed(() => {
|
||||
console.log('TransactionLink.itemTypeExt... itemType=', itemType)
|
||||
console.log('TransactionLink.itemTypeExt... itemType=', itemType.value)
|
||||
if (itemType.value.startsWith('TEXT')) {
|
||||
return 'TEXT'
|
||||
}
|
||||
@ -141,7 +142,7 @@ const itemTypeExt = computed(() => {
|
||||
})
|
||||
|
||||
watch(itemType, (newItemType) => {
|
||||
console.log('TransactionLink.watch... itemType=', itemType)
|
||||
console.log('TransactionLink.watch... itemType=', itemType.value)
|
||||
updateRedeemedBoxText(newItemType)
|
||||
})
|
||||
|
||||
@ -179,17 +180,20 @@ onMounted(() => {
|
||||
|
||||
onResult(() => {
|
||||
console.log('TransactionLink.onResult... result=', result)
|
||||
console.log('TransactionLink.onResult... referrer=', referrer.value, meta.referrer)
|
||||
if (!result || !result.value) return
|
||||
setTransactionLinkInformation()
|
||||
})
|
||||
|
||||
onError(() => {
|
||||
console.log('TransactionLink.onError... error=', error)
|
||||
console.log('TransactionLink.onError... referrer=', referrer.value, meta.referrer)
|
||||
toastError(t('gdd_per_link.redeemlink-error'))
|
||||
})
|
||||
|
||||
function setTransactionLinkInformation() {
|
||||
console.log('TransactionLink.setTransactionLinkInformation... result=', result)
|
||||
console.log('TransactionLink.setTransactionLinkInformation... referrer=', referrer.value, meta.referrer)
|
||||
const { queryTransactionLink } = result.value
|
||||
console.log(
|
||||
'TransactionLink.setTransactionLinkInformation... queryTransactionLink=',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user