You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2019-10-29 14:25:59

alexkenon
Member
From: Russia
Registered: 2019-07-17
Posts: 18

New comment on the request - color

Hello. Question. When the user receives a letter that a new comment on the request has been received, it would be desirable that the most recent comment in the request is colored red. So that when a notification letter came to the mail, it was immediately visible to the last comment, which will be colored red. Where is it set up?

Offline

#2 2019-10-29 15:32:02

LaDenrée
HELPER
Registered: 2012-11-19
Posts: 4,796

Re: New comment on the request - color

setup>notification>notification Template>[my template]>translations> change code

if "comment" means followup
then use

##FOREACH last followups##
<font  color="red">##followup.description##</font>
##ENDFOREACHfollowups##


Trouver la panne avant de réparer...
*GLPI 9.1.6+fusion9.1+1.1+behaviours1.5.0+reports+fields+appliances+pdf+badges+formcreator2.5.2 PHP7.0 Mariadb10
*GLPI 9.4.4(behaviours2.2.1+fusioninventoty 9.4+1.1+applicatifs2.5.0+fields 1.9.1)hebergé sur serveur mutualisé.

Offline

#3 2019-10-29 17:09:58

alexkenon
Member
From: Russia
Registered: 2019-07-17
Posts: 18

Re: New comment on the request - color

LaDenrée wrote:

setup>notification>notification Template>[my template]>translations> change code

if "comment" means followup
then use

##FOREACH last followups##
<font  color="red">##followup.description##</font>
##ENDFOREACHfollowups##



Thanks for the help. Yes, that's what I meant (last followup). BUT! There is already a line in the "tickets" code:

##FOREACHfollowups##

[##followup.date##] ##lang.followup.isprivate## : ##followup.isprivate##
##lang.followup.author## ##followup.author##
##lang.followup.description## ##followup.description##
##lang.followup.date## ##followup.date##
##lang.followup.requesttype## ##followup.requesttype##

##ENDFOREACHfollowups##

I just need to paint this line red (##followup.description##)?

But then all comments will be red and I only need the last one.

Is it possible?

Last edited by alexkenon (2019-10-29 17:10:06)

Offline

#4 2019-10-29 17:15:38

LaDenrée
HELPER
Registered: 2012-11-19
Posts: 4,796

Re: New comment on the request - color

do you really need all the followups in notification ?

if yes then

##FOREACH last followups##
[##followup.date##] ##lang.followup.isprivate## : ##followup.isprivate##
##lang.followup.author## ##followup.author##
<font  color="red">##lang.followup.description## ##followup.description##</font>
##lang.followup.date## ##followup.date##
##lang.followup.requesttype## ##followup.requesttype##
##ENDFOREACHfollowups##

##FOREACHfollowups##
[##followup.date##] ##lang.followup.isprivate## : ##followup.isprivate##
##lang.followup.author## ##followup.author##
##lang.followup.description## ##followup.description##
##lang.followup.date## ##followup.date##
##lang.followup.requesttype## ##followup.requesttype##
##ENDFOREACHfollowups##

last followup will be printed twice :  once red and the other time, like the other followups


Trouver la panne avant de réparer...
*GLPI 9.1.6+fusion9.1+1.1+behaviours1.5.0+reports+fields+appliances+pdf+badges+formcreator2.5.2 PHP7.0 Mariadb10
*GLPI 9.4.4(behaviours2.2.1+fusioninventoty 9.4+1.1+applicatifs2.5.0+fields 1.9.1)hebergé sur serveur mutualisé.

Offline

#5 2019-11-07 15:29:03

alexkenon
Member
From: Russia
Registered: 2019-07-17
Posts: 18

Re: New comment on the request - color

LaDenrée wrote:

do you really need all the followups in notification ?

if yes then

##FOREACH last followups##
[##followup.date##] ##lang.followup.isprivate## : ##followup.isprivate##
##lang.followup.author## ##followup.author##
<font  color="red">##lang.followup.description## ##followup.description##</font>
##lang.followup.date## ##followup.date##
##lang.followup.requesttype## ##followup.requesttype##
##ENDFOREACHfollowups##

##FOREACHfollowups##
[##followup.date##] ##lang.followup.isprivate## : ##followup.isprivate##
##lang.followup.author## ##followup.author##
##lang.followup.description## ##followup.description##
##lang.followup.date## ##followup.date##
##lang.followup.requesttype## ##followup.requesttype##
##ENDFOREACHfollowups##

last followup will be printed twice :  once red and the other time, like the other followups

Thanks!

Last edited by alexkenon (2019-11-07 15:29:18)

Offline

Board footer

Powered by FluxBB