[interchange-cvs] interchange - heins modified
lib/Vend/Interpolate.pm
interchange-cvs at icdevgroup.org
interchange-cvs at icdevgroup.org
Mon May 30 12:22:21 EDT 2005
User: heins
Date: 2005-05-30 16:22:21 GMT
Modified: lib/Vend Interpolate.pm
Log:
* Allow levies to mark themselves as inclusive.
* Don't pay attention to whitespace in the return of ITL exclude_if
and include_if members.
Revision Changes Path
2.248 +11 -4 interchange/lib/Vend/Interpolate.pm
rev 2.248, prev_rev 2.247
Index: Interpolate.pm
===================================================================
RCS file: /var/cvs/interchange/lib/Vend/Interpolate.pm,v
retrieving revision 2.247
retrieving revision 2.248
diff -u -r2.247 -r2.248
--- Interpolate.pm 29 May 2005 15:30:19 -0000 2.247
+++ Interpolate.pm 30 May 2005 16:22:21 -0000 2.248
@@ -1,6 +1,6 @@
# Vend::Interpolate - Interpret Interchange tags
#
-# $Id: Interpolate.pm,v 2.247 2005/05/29 15:30:19 mheins Exp $
+# $Id: Interpolate.pm,v 2.248 2005/05/30 16:22:21 mheins Exp $
#
# Copyright (C) 2002-2005 Interchange Development Group
# Copyright (C) 1996-2002 Red Hat, Inc.
@@ -28,7 +28,7 @@
require Exporter;
@ISA = qw(Exporter);
-$VERSION = substr(q$Revision: 2.247 $, 10);
+$VERSION = substr(q$Revision: 2.248 $, 10);
@EXPORT = qw (
@@ -5721,7 +5721,10 @@
next unless $::Values->{$if};
}
elsif($if =~ /__[A-Z]\w+__|[[a-zA-Z]/) {
- next unless interpolate_html($if);
+ my $val = interpolate_html($if);
+ $val =~ s/^\s+//;
+ $val =~ s/^s+$//;
+ next unless $val;
}
else {
next unless tag_calc($if);
@@ -5732,7 +5735,10 @@
next if $::Values->{$if};
}
elsif($if =~ /__[A-Z]\w+__|[[a-zA-Z]/) {
- next if interpolate_html($if);
+ my $val = interpolate_html($if);
+ $val =~ s/^\s+//;
+ $val =~ s/^s+$//;
+ next if $val;
}
else {
next if tag_calc($if);
@@ -5813,6 +5819,7 @@
cost => round_to_frac_digits($cost),
currency => currency($cost),
group => $group,
+ inclusive => $l->{inclusive},
label => $l->{label} || $desc,
part_number => $l->{part_number},
description => $desc,
More information about the interchange-cvs
mailing list