Page 1 of 1
Keep formating while editing received ticket
Posted: Mon Aug 29, 2016 1:48 pm
by stevenf
Hello,
I know this will sound like a very strange question, but is it possible to retain formating of ticket while editing it. Now, when I try to edit ticket, formating dissapears as in all text is transfromed in one paragraf. In source there is inside p tags but in edtior there is no new line.
Also, this dosen't happens while writing response, only when try to edit received ticket.
Hesk version 2.6.7.
Mods for Hesk 2.6.3
Re: Keep formating while editing received ticket
Posted: Mon Aug 29, 2016 2:39 pm
by mkoch227
In edit_post.php, find (should be around line 495):
Code: Select all
<?php if ($modsForHesk_settings['rich_text_for_tickets']): ?>
change to
Save, upload, and test. I haven't had a chance to test this yet so let me know how it goes

Re: Keep formating while editing received ticket
Posted: Tue Aug 30, 2016 9:31 am
by stevenf
Unfortunately, it didn't help cause after saving changes, there is no more row spacing no matter how much I add them.
Re: Keep formating while editing received ticket
Posted: Tue Aug 30, 2016 3:30 pm
by mkoch227
Found another line that needed to be changed. In edit_post, find at
line 483:
Code: Select all
$html = $modsForHesk_settings['rich_text_for_tickets'] ? 1 : 0;
change to
Re: Keep formating while editing received ticket
Posted: Wed Aug 31, 2016 6:45 am
by stevenf
It worked on first received ticked, but on second received reply same thing happens.
Re: Keep formating while editing received ticket
Posted: Fri Sep 02, 2016 12:06 pm
by mkoch227
Sorry for the delay. I finally had a chance to look at this page in a bit more detail, and I think I worked all the kinks out of it. The issue with the page, as originally thought, was that the flag to use the HTML editor was using the helpdesk's setting, and not the "html" property of the ticket itself. However, after fixing that, the page still looked at the original ticket message's "html" property, even if you were editing a reply. Therefore, if you changed HTML settings between replies, or if customers can't use rich text, etc, this would cause issues.
Anyhoo, try replacing your edit_post.php file with this one:
https://gitlab.com/mike-koch/Mods-for-H ... t_post.php and see what happens. If you still have issues, please send me a PM with (1) your helpdesk URL, (2) login credentials so I can view the ticket with issues,and (3) read-only database access so I can see certain fields pertaining to tickets/replies.
Re: Keep formating while editing received ticket
Posted: Mon Sep 05, 2016 12:44 pm
by stevenf
Thank you for reply. I will try this.
Also just to ask, is there anywhere option to set up default font of 12px in ticket response?
Re: Keep formating while editing received ticket
Posted: Mon Sep 05, 2016 6:09 pm
by mkoch227
stevenf wrote:Also just to ask, is there anywhere option to set up default font of 12px in ticket response?
I'm not sure exactly what you mean. Do you mean the actual text editor? If so, you'll need to modify the content.css file in inc/tiny_mce/3.5.11/themes/advanced/skins/default. Find:
Code: Select all
body, td, pre {
color: #000;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10px;
margin: 8px;
}
Then change font-size to the size you want.
This does not change the font size when viewing the response after it is submitted. I plan on making the editor font size and actual display font size consistent so the user will actually see how the response will look.
Re: Keep formating while editing received ticket
Posted: Tue Sep 06, 2016 8:57 am
by stevenf
Thank you for reply. That file worked for editing received ticket without HTML editor so no formating will be lost.