Date Calculations
Last modified by Vincent Massol on 2026/08/05 17:14
| Perform date calculations in Velocity |
| Type | |
| Category | |
| Developed by | |
| Rating | |
| License | GNU Lesser General Public License 2.1 |
Table of contents
Description
Substract 30 days to the current date:
{{velocity}}
#set ($calendar = $datetool.systemCalendar)
#set ($discard = $calendar.add(5, -30))
#set ($dateBefore30Days = $calendar.time)
$dateBefore30Days
{{/velocity}}