Hi,
i create a link to an external system by using (for example) [% Data.Created | uri %]
This creates a date in format "yyyy-MM-dd HH:mm:ss". Now, in the external system there has been a change and they only accept "yyyy-MM-dd HH:mm" (without the seconds!).
Is there any way i can tell OTRS how to format the output of "Data.Created"? Or can i build an alternate way, for example by stacking "Day.Created" "month.created" "year.created" "hour.created" "minute.created"?
Thank you!
Modify a field when generating a url
Moderator: crythias
Modify a field when generating a url
OTRS 5.0.24 (with ITSM Modules) and Znuny 6.4.4 in staging
-
- Administrator
- Posts: 3976
- Joined: 18 Dec 2007, 12:23
- Znuny Version: Znuny and Znuny LTS
- Real Name: Roy Kaldung
- Company: Znuny
- Contact:
Re: Modify a field when generating a url
Hi,
Without checking, I would try to use trunce (http://template-toolkit.org/docs/manual/Filters.html) from before URI.
- Roy
Without checking, I would try to use trunce (http://template-toolkit.org/docs/manual/Filters.html) from before URI.
Code: Select all
[% Data.Created | truncate(16, '') |uri %]
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Re: Modify a field when generating a url
Perfect, thank you!
OTRS 5.0.24 (with ITSM Modules) and Znuny 6.4.4 in staging