-
Posts
90 -
Joined
-
Last visited
-
Days Won
16
Content Type
Forums
Store
Downloads
Events
Posts posted by danialbulloch
-
-
We have a couple of clients with employees that don't have company emails. For those clients, the ticket is assigned to the primary contact, instead of the user. Which means that we can't get Smileback feedback from the end user, only the primary contact. For those clients I made the follow widget which can be embedded on a webpage to give feed back. Just drop your smileback survey code into the "emailcode" variable and put it on your website. Usage: https://url?ticketnumber. E.G. https://fake.com/feedback/?123456.
<div id="survey"></div> <script> var emailcode = ` Replace This with your survey snippet! ` var badticketnumber = ` Sorry, the ticket number provided is incorrect. ` //edit the next two variables with a reasonable range for your tickets. var ticketidmax = 9999999 var ticketidmin = 99999 //this grabs everything after the ? on a url, and converts it to a number. Doesn't need to be edited. var ticketid = parseInt(window.location.search.substr(1)) //this makes sure the result of the after ? is a number, and is in the acceptable range. if (typeof ticketid === "number" && ticketid > ticketidmin && ticketid < ticketidmax) { var surveydiv = document.getElementById('survey') //this replaces the [srnumber] tags with the actual ticket number surveydiv.innerHTML = emailcode.replace(/\[srnumber]/g,ticketid) } else { //this will display an error message if a ticket number isn't right(ish) var surveydiv = document.getElementById('survey') surveydiv.innerHTML = badticketnumber } </script>
- 1
Consuming Manage Rest API with PowerBI
in General Discussion
Posted
I just wrote a blog post you can find here. I don't have comments on my blog, so I figured I'd start a thread here for people to discuss. I haven't integrated it with CWA yet, but CWA should work almost the same. As should most API's that page up the data.