최근 검색
최근 검색 없음

Benessa Dumol
가입한 날짜: 2022년 6월 23일
·
마지막 활동: 2023년 7월 26일
팔로잉
0
팔로워
1
총 활동 수
50
투표 수
4
플랜 수
13
활동 개요
배지
문서
게시물
커뮤니티 댓글
문서 댓글
활동 개요
님의 최근 활동 Benessa Dumol
Benessa Dumol님이 에 댓글을 입력함
Hi Christopher Kennedy, thank you for your response.
To answer your questions, it's a custom API that fetches the data of the Ivanti incident from Ivanti (third-party provider) and yes, I am seeing the response from calling the API endpoint. The API endpoint is called on the load of the ticket/app so the data are already in the div even before the modal is called.
Below are parts of the codes that are used for the modal:
1. Function to populate div with the data from the API response (on load of the ticket/app)
//
// Show Ivanti incident Task/s
//
function showIvantiIncidentTasks(data, ivantiIncidentId) {
// Retrieve Ivanti incident task/s details
var tasks;
if (data.tasks !== null ) {
tasks = Object.values(data.tasks);
}
console.log(" Ivanti Incident tasks OK");
// Display Ivanti incident task/s
var source = $('#view-ivanti-incident-tasks').html();
var template = Handlebars.compile(source);
var newHTML = template({tasks});
$('#tasks-' + ivantiIncidentId).append(newHTML);
}
2. The div that contains the data
3. The button that is used to call the modal
View Tasks
4. The function that is called by the button
//
// Display Ivanti Incident Tasks
//
function viewTasks(incidentId) {
convertDateTime();
var html = $("#tasks-" + incidentId).html();
client.invoke('instances.create', {
location: 'modal',
url: 'assets/modal.html',
size: { // optional
width: '80vw',
height: '70vh'
}
}).then(function(modalContext) {
// The modal is on the screen now!
var modalClient = client.instance(modalContext['instances.create'][0].instanceGuid);
client.on('modalReady', function setHtml(){
modalClient.trigger('drawData', html);
client.off("modalReady", setHtml);
});
modalClient.on('modal.close', function() {
// The modal has been closed.
console.log('The modal has been closed');
});
});
};
5. Below are the contents of modal.html
Technology Incident Zendesk App
Let me know if you need anything to better understand my issue. Looking forward to your reply.
Thank you,
Benessa
댓글 보기 · 2023년 7월 18일에 편집됨 · Benessa Dumol
0
팔로워
0
투표 수
0
댓글
Benessa Dumol님이 에 게시물을 만듦
Hi all,
Currently, I have a working modal that is triggered by a button using the onclick event. There are three (3) buttons that trigger the modal but each of them contains different data. The contents of the modal are from the divs which were populated using Handlebars from a JSON response when calling the API endpoint. The divs are using unique IDs.
While doing some tests, I noticed that when two (2) Zendesk tickets are open simultaneously, the Modal is no longer populated on the second ticket that was opened but it is still working on the first ticket that was opened. When I tried refreshing the page, the Modal works fine on the ticket that is active but no longers works on the ticket that is inactive.
Kindly check this Loom video to understand better what I meant.
Looking forward to your reply.
Thank you,
Benessa
2023년 7월 13일에 편집됨 · Benessa Dumol
0
팔로워
4
투표 수
5
댓글
Benessa Dumol님이 에 댓글을 입력함
Hi Ahmed Zaid,
No worries. I was able to solve it using CSS instead.
Thank you for your help.
Benessa
댓글 보기 · 2023년 4월 03일에 게시됨 · Benessa Dumol
0
팔로워
0
투표 수
0
댓글
Benessa Dumol님이 에 댓글을 입력함
Hello Ahmed Zaid, do you have other input to my question above?
I've looked for ways to fix this issue but was not successful.
Looking forward to any response.
Thank you,
Benessa
댓글 보기 · 2023년 2월 27일에 게시됨 · Benessa Dumol
0
팔로워
0
투표 수
0
댓글
Benessa Dumol님이 에 댓글을 입력함
Hi Ahmed Zaid,
Thank you for responding to my query.
Yes, I am creating a new instance using this script
client.invoke('instances.create', {
location: 'modal',
url: 'assets/modal.html',
size: { // optional
width: '80vw',
height: '70vh'
}
}).then(function(modalContext) {
// The modal is on the screen now!
var modalClient = client.instance(modalContext['instances.create'][0].instanceGuid);
client.on('modalReady', function setHtml(){
modalClient.trigger('drawData', html);
client.off("modalReady", setHtml);
});
modalClient.on('modal.close', function() {
// The modal has been closed.
console.log('The modal has been closed');
});
});
Let me know if you want to see my whole code.
Thank you,
Benessa
댓글 보기 · 2023년 2월 02일에 게시됨 · Benessa Dumol
0
팔로워
0
투표 수
0
댓글
Benessa Dumol님이 에 게시물을 만듦
Hello,
I am currently using the Modal to display all the emails from a 3rd party that I retrieve using an API call. I have added a filter to display the Incoming and Outgoing emails using this method.
I want all the emails to be displayed when the pop-up modal is opened so I added an onload function on the body of the modal.html
All emails are showing up on the 1st instance when the pop-up modal was opened
but it will not show once the pop-up modal was opened again after it was closed the 1st time. I have 3 buttons that when clicked will open the modal so I am not sure if this is causing the issue.
I have attached screenshots of my modal.html and modal.js.
Let me know if you would like to see my code. Looking forward to any response.
Thank you,
Benessa
2023년 1월 31일에 게시됨 · Benessa Dumol
0
팔로워
2
투표 수
3
댓글
Benessa Dumol님이 에 댓글을 입력함
Hi CJ Johnson,
May I ask what solution did you implement to solve this issue?
Unfortunately, I am still having this issue and wasn't able to use any zcli command
Looking forward to your response.
Thank you,
Benessa
댓글 보기 · 2022년 12월 15일에 게시됨 · Benessa Dumol
0
팔로워
0
투표 수
0
댓글
Benessa Dumol님이 에 댓글을 입력함
댓글 보기 · 2022년 10월 28일에 게시됨 · Benessa Dumol
0
팔로워
0
투표 수
0
댓글
Benessa Dumol님이 에 게시물을 만듦
Hello,
I am having an " Uncaught Error: [ZAF SDK] Could not find client for instance " on my modal. I used the Zendesk modal API to create the modal.
The error occurs after I open the modal the 2nd time.
I also need to close the modal over and over again so that the content will show up.
Please check this Loom video to understand better what I meant.
Looking forward to your reply.
Thank you,
Benessa
2022년 10월 26일에 게시됨 · Benessa Dumol
0
팔로워
2
투표 수
0
댓글
Benessa Dumol님이 에 게시물을 만듦
Hello,
I am having an " Uncaught Error: [ZAF SDK] Could not find client for instance " on my modal. I used the Zendesk modal API to create the modal.
The error occurs after I open the modal the 2nd time.
I also need to close the modal over and over again so that the content will show up.
Please check this Loom video to understand better what I meant.
Looking forward to your reply.
Thank you,
Benessa
2022년 10월 26일에 편집됨 · Benessa Dumol
0
팔로워
5
투표 수
6
댓글