Hi all,
Firstly, sorrry my English, but I'm an hungarian man.
I have a litle problem... The company where I work use the OTRS and now they want to introduce the service catalog. I read the manual and I went afer the Perl, but I don't see answer my question.
My problem is: In the comment field of the service catalog only one line is saved, I cannot insert a line break. I tried the replace() function but it says "CODE(0x560f2f3222d8).
I know that the text field is a comment, but I copied it to the Custom folder and replaced it with textarea so that I can enter multi lines.
However, as I looked into the database, it only loads one line. I tried the html_break, html_line_break commands but haven't effect. IAnd we use postgreSQL.
Regards,
Thank you for your answer!
kkgigiioo
Multiline sercive catalog comment
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: Multiline sercive catalog comment
Please show some code...
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Re: Multiline sercive catalog comment
Okay, I'm trying to copy the essence.
And if [% Translate(Data.Comment) | html_line_break | html %] instead of [% Translate(Data.Comment) | replace('\.',\r\n) | html %], then write down the error code mentioned above
Code: Select all
<div class="Content AutoHeight">
<fieldset class="TableLike FixedLabelSmall">
<label title="[% Translate("Type") | html %]">[% Translate("Type") | html %]: </label>
<div class="Field">
[% Translate(Data.Type) | html %]
</div>
<div class="Clear"></div>
<label>[% Translate("Criticality") | html %]: </label>
<div class="Field">
[% Translate(Data.Criticality) | html %]
</div>
<div class="Clear"></div>
<label title="[% Translate("Comment") | html %]">[% Translate("Comment") | html %]: </label>
<div class="Field">
[% Translate(Data.Comment) | html_line_break | html %]
</div>
<div class="Clear"></div>
</fieldset>
</div>