MiniVend Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Using product fields in usertag



How do i access fields besides price/code in my usertags?  $item->{code}
works in the example below but $item->{defweight} does not ... defweight
is a field in products.asc

UserTag price-mod Routine <<EOR
sub {
     my $s = $Vend::Interpolate::s;
     my $item = $Vend::Interpolate::item;
     my $adj=0;
     # Do whatever you want to price here

     if ( $item->{code} eq "01-001" ) {
         return $Global::Variable->{SVALUE} * $item->{defweight};
# $item->{defweight}  is what it doesnt like.  I thought i could do it
the same as
# $item->{code}works but this expression evaluates to 0.  How do i
access fields
# besides price/code in my usertags?
     }
     return $adj;
}
EOR



Search for: Match: Format: Sort by: