[interchange-cvs] interchange - docelic modified 2 files
interchange-cvs at icdevgroup.org
interchange-cvs at icdevgroup.org
Mon Feb 18 14:21:21 EST 2008
User: docelic
Date: 2008-02-18 19:21:21 GMT
Modified: . WHATSNEW-5.5
Modified: lib/Vend Form.pm
Log:
* Allow box-based option templates to access VALUE in addition to LABEL,
so the following is possible:
<img src="/images/{VALUE}.gif"> {LABEL}
Revision Changes Path
1.94 +5 -0 interchange/WHATSNEW-5.5
rev 1.94, prev_rev 1.93
Index: WHATSNEW-5.5
===================================================================
RCS file: /var/cvs/interchange/WHATSNEW-5.5,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -r1.93 -r1.94
--- WHATSNEW-5.5 15 Feb 2008 23:50:51 -0000 1.93
+++ WHATSNEW-5.5 18 Feb 2008 19:21:21 -0000 1.94
@@ -12,6 +12,11 @@
Core
----
+* Allow box-based widgets access to VALUE from option template (in addition
+ to LABEL). With VALUE added, the following template becomes possible:
+
+ option_template => "<img src='/images/{VALUE}.gif'> {LABEL}"
+
* Fixed the MinQuantityField and MaxQuantityField enforcement code so that
it takes the entire cart into account when SeparateItems is in use.
2.74 +3 -3 interchange/lib/Vend/Form.pm
rev 2.74, prev_rev 2.73
Index: Form.pm
===================================================================
RCS file: /var/cvs/interchange/lib/Vend/Form.pm,v
retrieving revision 2.73
retrieving revision 2.74
diff -u -r2.73 -r2.74
--- Form.pm 2 Dec 2007 15:45:04 -0000 2.73
+++ Form.pm 18 Feb 2008 19:21:21 -0000 2.74
@@ -1,6 +1,6 @@
# Vend::Form - Generate Form widgets
#
-# $Id: Form.pm,v 2.73 2007/12/02 15:45:04 mheins Exp $
+# $Id: Form.pm,v 2.74 2008/02/18 19:21:21 docelic Exp $
#
# Copyright (C) 2002-2007 Interchange Development Group
# Copyright (C) 1996-2002 Red Hat, Inc.
@@ -39,7 +39,7 @@
require Exporter;
@ISA = qw(Exporter);
-$VERSION = substr(q$Revision: 2.73 $, 10);
+$VERSION = substr(q$Revision: 2.74 $, 10);
@EXPORT = qw (
display
@@ -969,7 +969,7 @@
$opt->{selected} = '' if defined $opt->{value};
my $extra;
- my $attr = { label => $label };
+ my $attr = { label => $label, value => $value };
if(my $p = $price->{$value}) {
$attr->{negative} = $p < 0 ? 1 : 0;
$attr->{price_noformat} = $p;
More information about the interchange-cvs
mailing list