You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello iam new in react native and i want to log some purchases on fireabase analytics dashboard. Iam usin your awesome library to implement firebase in my react native app. I am using this code piece to log event on firebase but i cannot see the items.
` const ticketItems = new Array<FirebaseAnalyticsTypes.Item>()
if (reservationResponse?.tickets != undefined) {
for (const ticket of reservationResponse?.tickets) {
const _ticket = {} as FirebaseAnalyticsTypes.Item
_ticket.item_id = ticket.id.toString()
_ticket.price = (ticket.price === null || ticket.price === undefined) ? 0 : ticket.price?.value
_ticket.item_name = event.title.substring(0, 100)
_ticket.quantity = 1
ticketItems.push(_ticket)
}
const purchaseEventParams = {} as FirebaseAnalyticsTypes.PurchaseEventParameters
purchaseEventParams.currency = zoneConfig.currency.code
purchaseEventParams.value = reservationResponse.payment.total.value
purchaseEventParams.items = ticketItems
purchaseEventParams.transaction_id = reservationResponse.payment.config.transactionIdentifier
await analytics().logPurchase(purchaseEventParams)
.then(() => {
// LOG([`sended to firebase purchase with params : `, purchaseEventParams])
})
.catch((err) => {
LOG([`something went wrong whne log purchasement on firebase`])
})
}`
but i can not see items on dashboard. Here is an image taken from firebase console that explain the situation
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello iam new in react native and i want to log some purchases on fireabase analytics dashboard. Iam usin your awesome library to implement firebase in my react native app. I am using this code piece to log event on firebase but i cannot see the items.
` const ticketItems = new Array<FirebaseAnalyticsTypes.Item>()
Beta Was this translation helpful? Give feedback.
All reactions