최근 검색
최근 검색 없음

Christoffer Jon Sinnbeck
가입한 날짜: 2021년 4월 15일
·
마지막 활동: 2022년 1월 20일
팔로잉
0
팔로워
0
총 활동 수
2
투표 수
0
가입 플랜
1
활동 개요
배지
문서
게시물
커뮤니티 댓글
문서 댓글
활동 개요
님의 최근 활동 Christoffer Jon Sinnbeck
Christoffer Jon Sinnbeck님이 에 게시물을 만듦
Hi,
I have this piece of code in my ticket sidebar app (this is a simplified example):
client.context().then(context => {
console.log("CONTEXT", context);
this.context = context;
});
client.get("ticket").then(ticket => {
console.log("TICKETDATA", "ID=" + ticket.ticket.id, "SUBJECT=" + ticket.ticket.subject);
this.ticketData = ticket;
})
However, when my app loads/refreshes, this results in the ticket data and context being loaded for all open tickets (open ticket tabs), not just the ticket tab in focus. Is this intended behaviour? I have used the apps framework for some years and never noticed this before. A screenshot from our sandbox:
If it is intended, how do I identify which ticket is in focus, so I can grab the ticket data with client.get("ticket") (or sub-properties, e.g. client.get("ticket.organization.organizationFields")) for just that ticket? In the example above, for #1635. I would have assumed that at least only one context (which includes a ticket ID) was fetched, but I also get all three of those, as can be seen.
Thanks for any input.
Kind regards,
Chris
2022년 1월 20일에 편집됨 · Christoffer Jon Sinnbeck
1
팔로워
7
투표 수
4
댓글