]> git.koha-community.org Git - koha.git/commit
Bug 17975: TT syntax for notices - Prove that HOLD_SLIP is compatible
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Mon, 16 Jan 2017 16:33:39 +0000 (17:33 +0100)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 15 Jun 2017 18:56:00 +0000 (15:56 -0300)
commitb28d25e9cd2939460c4b4043bafd7013e7248515
treee9b945caf1e2561099544437f311fd0a3aa75b04
parenta740e773c6bfeb2b42945f16047b1f5dfba67af4
Bug 17975: TT syntax for notices - Prove that HOLD_SLIP is compatible

Here we need to test <<today>>.
We already pass a value, but it was wrong. We must pass a string, not a
DateTime object, otherwise the KohaDates plugin will not display the
hours part if we need it.

Test plan:
Define a HOLD_SLIP notice template to match your need.
Do not forget to use
  [% today | $KohaDates %]
or
  [% today | $KohaDates with_hours => 1 %]
To access data from the reserves table, use the 'hold' variable

Tested both patches together with several date formats, works as expected.
Signed-off-by: Marc VĂ©ron <veron@veron.ch>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
C4/Letters.pm
t/db_dependent/Letters/TemplateToolkit.t