{"id":138,"date":"2011-05-14T18:06:39","date_gmt":"2011-05-14T17:06:39","guid":{"rendered":"http:\/\/tempdetheux.food.blog\/2011\/05\/14\/zendesk-auto-fill-a-widget-with-data-from-ticket-view\/"},"modified":"2019-07-19T17:02:05","modified_gmt":"2019-07-19T15:02:05","slug":"zendesk-auto-fill-a-widget-with-data-from-ticket-view","status":"publish","type":"post","link":"https:\/\/arnaud.detheux.org\/blog\/zendesk-auto-fill-a-widget-with-data-from-ticket-view\/","title":{"rendered":"Zendesk: auto-fill a widget with data from ticket view"},"content":{"rendered":"<div id=\"bsf_rt_marker\"><\/div><p>As we deliver our own VoIP service, we also have our own Support Tool internally. This is great in terms of responsiveness or for the data our Support Teams need to have since they can simply ask our developers to add that.<\/p>\n<p>However, it means logging into a different tool than Zendesk to resolve a ticket which is time consuming. I therefore created a simple widget which allows a Support Agent to check a customer\u2019s profile in only one click from Zendesk\u2019s ticket view:<\/p>\n<figure><img decoding=\"async\" data-width=\"1024\" data-height=\"402\" src=\"https:\/\/cdn-images-1.medium.com\/max\/800\/0*40kXF5i1wlEwRwoG.png\"><\/figure>\n<p>The widget simply fetches the phone number of the customer from the <em>custom<\/em> ticket field (you just need to know its ID via Manage&gt; Ticket Fields) and replicates on page load to the widget\u2019s search box. It\u2019s all done with 3 lines of code, jQuery and using the&nbsp;.val() function&nbsp;\ud83d\ude42<br \/>\nCode<\/p>\n<pre>\n$j('#ID_OF_YOUR_WIDGET_INPUT_BOX').val($j('#ticket_fields_NUMBER').val());\n<\/pre>\n<p>The source is on <a href=\"https:\/\/github.com\/AdeTheux\/Zendesk-widgets\/blob\/master\/zendesk_widget_autofill.js\" target=\"_blank\" rel=\"noopener noreferrer\">GitHub<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>As we deliver our own VoIP service, we also have our own Support Tool internally. This is great in terms of responsiveness or for the data our Support Teams need to have since they can simply ask our developers to add that. However, it means logging into a different tool than Zendesk to resolve a&hellip;<\/p>\n<p class=\"read-more\"><a class=\"readmore-btn\" href=\"https:\/\/arnaud.detheux.org\/blog\/zendesk-auto-fill-a-widget-with-data-from-ticket-view\/\">Read More<span class=\"screen-reader-text\">  Read More<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":"","jetpack_post_was_ever_published":false},"categories":[7],"tags":[63,20,30,38,39,49,57],"class_list":["post-138","post","type-post","status-publish","format-standard","hentry","category-customer-experience","tag-archive","tag-customer-support","tag-hack","tag-javascript","tag-jquery","tag-plugin","tag-zendesk"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/posts\/138","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/comments?post=138"}],"version-history":[{"count":2,"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/posts\/138\/revisions"}],"predecessor-version":[{"id":454,"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/posts\/138\/revisions\/454"}],"wp:attachment":[{"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/media?parent=138"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/categories?post=138"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/arnaud.detheux.org\/blog\/wp-json\/wp\/v2\/tags?post=138"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}