[Koha-patches] [PATCH] Replace TMPL_ELSIF with TMPL_ELSE and TMPL_IF in label-manager.tmpl;

Chris Nighswonger chris.nighswonger at liblime.com
Wed Jul 30 15:03:51 CEST 2008


On Mon, Jul 28, 2008 at 2:05 PM, Chris Nighswonger <
chris.nighswonger at liblime.com> wrote:

> On Mon, Jul 28, 2008 at 1:25 PM, Jesse Weaver <jesse.weaver at liblime.com>wrote:
>
>> On Mon, Jul 28, 2008 at 11:18 AM, MJ Ray <mjr at phonecoop.coop> wrote:
>>
>>> "Joshua Ferraro" <jmf at liblime.com> wrote:
>>> > MJ, can you clarify the purpose of this patch? Why are you preferring
>>> > separate ELSE and IF over ELSIF ?
>>>
>>> It doesn't seem to work reliably on one of my Koha 3 systems.
>>> TMPL_ELSIF appears to be a fairly recent HTML::Template::Pro-ism so it
>>> limits portability and there's a big WARNING on perldoc
>>> HTML::Template::SYNTAX, so it seemed like a good idea to remove it.
>>> What's the problem?
>>>
>>> Hope that explains,
>>> --
>>> MJ Ray (slef)
>>>
>>>
>> As far as portability goes, Koha 3.0 depends on a recent version of
>> HTML::Template::Pro anyway. We also use TMPL_EXPRs in a few strategic
>> places, and those are only supported by Template::Pro and Template::Expr. Do
>> you have the most recent version of the module?
>>
>
> TMPL_ELSIF was introduced into H::T::P at my request as it increases the
> readability of the templating code. It was introduced into Koha with this
> commit back in early March:
>
>
> http://git.koha.org/cgi-bin/gitweb.cgi?p=Koha;a=commit;h=710afb6251f7ecd617a71a68e2ab313a61a6e54d
>
> Three days later the first use was introduced with a reminder note:
>
>
> http://git.koha.org/cgi-bin/gitweb.cgi?p=Koha;a=commit;h=6a61c4b6a9d50b7cf735d1bcc83543ea6092cc9d
>
>
I'm wondering that this problem has not manifest itself earlier than this.
As I noted above, TMPL_ELSIF was introduced back in early March and so has
been in place nearly five months now. Was the OS upgraded after the Koha
install?

BTW: TMPL_ELSIF is presently used in at least 55 lines of code.

Kind Regards,

-- 
Chris Nighswonger

LibLime
www.liblime.com
chris.nighswonger at liblime.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/koha-patches/attachments/20080730/ec5ba466/attachment-0002.htm>


More information about the Koha-patches mailing list