[ic] Necessity of delete $Vend::Session->{mv_order_number} in
Dispatch.pm?
Kevin Old
interchange-users@icdevgroup.org
Mon Mar 31 17:02:01 2003
On Mon, 2003-03-31 at 06:09, John Young wrote:
> Mike Heins replied to my questions about Session->{mv_order_number}:
>
> > It was intended that the order number be set in a profile. There *is*
> > a defect, however, in that the setting of $Values->{mv_order_number}
> > is set in the temporary values of the route. While you can fix this
> > by calling [data session mv_order_number], it might be better to make
> > it work a bit more transparently.
> >
> > Perhaps this would be effective:
> >
> > --- /r/Order.pm Sat Mar 29 15:19:20 2003
> > +++ /rt/Order.pm Sat Mar 29 17:06:30 2003
> > @@ -1583,6 +1583,12 @@
> > }
> > }
> >
> > + if($Vend::Session->{mv_order_number}) {
> > + $value_save->{mv_order_number} =
> > + $::Values->{mv_order_number} =
> > + $Vend::Session->{mv_order_number};
> > + }
> > +
> > $Vend::Interpolate::Values = $::Values = { %$value_save };
> > $::Values->{mv_current_route} = $c;
> > my $pre_encrypted;
> >
> > That does appear to do it, and I have made that patch. I don't see
> > how it can hurt anything if you never set $Session->{mv_order_number}.
> >
> > Thanks for shedding new light on this.
>
>
> No, thank you for replying and committing a fix so quickly. It's
> not the first time you've done that when I posted a question, and
> I really appreciate it.
>
> Your fix above works perfectly. I also moved my custom order number
> usertag call from checkout.html into the order profile referenced
> in checkout.html (according to my understanding of your earlier
> hints). That seems to work well, too. Yet another nice little
> example of Interchange's extensibility.
>
> Thanks, again, Mike!
>
> John Young
>
> _______________________________________________
> interchange-users mailing list
> interchange-users@icdevgroup.org
> http://www.icdevgroup.org/mailman/listinfo/interchange-users
Mike,
I copied over the modified Order.pm and altered the line that assigns
the Order Description line to the hash it sends to the processor, in
iTransact.pm and I can't get the mv_order_number to print....any ideas?
<snip>
sub itransact {
my ($opt, $amount) = @_;
::logDebug("All options: " . ::uneval($opt));
my $user = $opt->{id} || charge_param('id');
#my $company = $opt->{company} || "$::Variable->{COMPANY} Order
$opt->{id}";
my $company = $opt->{company} || "$::Variable->{COMPANY} Order
$Vend::Session->{mv_order_id}";
<snip>
Also, $opt->{company} is null.
Thanks for any help,
Kevin
--
Kevin Old <kold@carolina.rr.com>