Change the Order of Ticket Replies

  • 22 October 2013
  • 36 replies
  • 362 views

The default view of the ticket replies is in chronological order. When you have more than two or three exchanges in a conversation, scrolling down to see the latest reply, every single time, gets aggravating. When this Freshplug is installed, the order of ticket replies can be reversed so that the latest reply is displayed first and the first response is displayed last.


Instructions


1. Download the zip file.

2. Unzip and open the .txt file

3. Copy the code from the file

4. Go to Admin->Integration->Freshplugs in you dashboard and click the new Freshplug button

5. Give a Name and Description to this plug for future reference

6. Select the text box “Show this widget in ticket view page”

7. Copy the code from the .txt file here and click the button "create and enable"

change_the_order_of_ticket_replies_main_screenshot_13102.pngthumbnail_13102.png

This topic has been closed for comments

36 replies

The code still works and is easy to use if your account supports Freshplugs ( the older option for extending Freshdesk - the current is the Freshdesk SDK ). In fact this is the code I am using:

 



<style type="text/css">

.conversation_thread {

border: 0;

}



#show_more {

padding: 0 10px 40px;

}



.conversation_thread.redactor {

margin-bottom: -30px;

margin-top: -30px;

}

</style>

<div id="reverse_ticket_replies_order"></div>

<script type="text/javascript">

if (jQuery("body").hasClass("ticket_details")) {

var reorderNotes = function() {

var id_value;

if (jQuery("#all_notes").length) {

id_value = "all_notes";

changeOrder(id_value);

} else {

id_value = "all_activities";

changeOrder(id_value);

}

};

var changeOrder = function(id) {

var ID = [];

jQuery("#" + id).find(".conversation").each(function() {

ID.push(jQuery(this).attr("data-timestamp"));

});

ID = ID.sort().reverse();

jQuery(ID).each(function(i, item) {

jQuery("#" + id).append(jQuery("[data-timestamp=" + item + "]"));

});

};

if (TICKET_DETAILS_DATA != null && TICKET_DETAILS_DATA.scroll_to_last) {

TICKET_DETAILS_DATA.scroll_to_last = false;

}

jQuery("#reverse_ticket_replies_order").closest(".widget").removeClass("widget");

jQuery(document).on("ticket_view_loaded", function(event, data) {

jQuery(".redactor").insertAfter("#original_request");

});

jQuery(document).on("note_created note_updated activities_toggle ticket_view_loaded ticket_show_more sidebar_loaded", function(event, data) {

reorderNotes();

jQuery("#all_notes").after(jQuery("#show_more"));

});

setTimeout(function() {

reorderNotes();

jQuery("#all_notes").after(jQuery("#show_more"));

}, 2000);

}

;

</script>


 



 





Thanos,






Thank you very much for your help. We are VERY new to FD. Just converted from ZD. Still learning the system. Don't think we have FreshPlugs as an option in our ADMIN section. I guess I will try to figure out another way.

Maybe the new MINT interface will have a way to do it? We will see!






Thanks again for your help.



Reason says that such code can be ported to the Freshdesk SDK but I have never done that so I don't know how easy that would be. Actually I'd like to hear from anyone with experience in porting Freshplugs to the SDK.

 



Badge +3


Hold on tight guys, your prayers have been heard - we've created an app for exactly this purpose. It's submitted to Freshdesk's marketplace and is currently in revision. Hopefully it will pass without problems and be available very soon. Stay tuned!  :)





Marcus,






Happy to beta test if needed. Thank you very much for your hard work.



Badge +3

@Chis: Thanks. We got some small feedback from the guys as Freshdesk's Marketplace Team and need to update some descriptions and screenshots, but other than that everything is ready to go. Hopefully it's released within a few days. I'll post an update here as soon as we'll get a green light.



Hello there. I'm very interested on trying this app. Good to know than i'm not the only one thinking that this option should be available at the system config. Any update about when this app will be released?. Thanks.



Badge +3


I'm really happy to announce that our app is finally released on the Marketplace! There was a long backlog at the review team, but they have now approved the app.






The app is free of charge and I hope it solves your needs and that your agents will like it! We will be happy to get your feedback.






Look here for more info:



https://apps.freshdesk.com/reversed_sort_order/





Thank you Marcus, we've been waiting on this for so long, as soon as we try it we'll send you more feedback. Have a nice day.



Hi will this custom app work in Freshdesk "Mint" gui?


Regards

Niklas





Badge +3

@Niklas.forsmarker: The current version of the app doesn't work in Mint, but we are assessing the possibilities to make this happen. Freshworks have with Mint changed the framework for how apps can work with and effect the content in the Tickets detail view, so we are not yet sure it will be possible to make the app run in Mint. I'll post an update in this thread as soon as I have some more info.