
[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[mv] CommonAdjust with mutiple Database
Hi List,
I've 4 database like products.asc, xmas.asc, eastern.asc and others.asc!
All database has two price fields (price and price2).
The price field "price" is for the dealer and "price2" is for all other
user.
I've trouble to get the right price for the dealer and/or to set the
PriceField dynamically!
This
Autoload <<EOR
[perl arg="scratch config"]
if($Scratch->{dealer}) {
$Config->{PriceField} = 'price';
} else {
$Config->{PriceField} = 'price2';
}
[/perl]
EOR
ist not working. And this
CommonAdjust "[if scratch dealer]:price[else]:price2[/else][/if]"
is working with products.asc only and not with all other database.
This
CommonAdjust "[if scratch
dealer]xmas:price[else]xmas:price2[/else][/if]"
is working with xmas.asc only. But
CommonAdjust "[if scratch dealer]:price ;xmas:price[else]price2
;xmas:price2[/else][/if]"
is not working. How can I use CommonAdjust with my all databases?
Or in my nextpage after log in, I've
[if value Preisgruppe == 1]
[perl arg="scratch config"]
$Config->{PriceField} = 'price';
# $Safe{config}{PriceField} = 'price';
$Safe{'scratch'}->{'testp'} = $Config->{PriceField};
$Safe{'scratch'}->{'dealer'} = 1;
return '';
[/perl]
[else]
[perl arg="scratch config"]
$Config->{PriceField} = 'price2';
# $Safe{config}{PriceField} = 'price2';
$Safe{'scratch'}->{'testp'} = $Config->{PriceField};
$Safe{'scratch'}->{'dealer'} = '';
return '';
[/perl]
[/else]
[/if]
and setting PriceField to price or price2 is not working right. The
[scratch testp] has the value "price" or "price2", if a user is a dealer
or not. But with "PriceField no_price" or "PriceField price2" (as a
default) in my catalog.cfg will not be override by the above codes. Why?
I use MV Version 3.14-5!
Any helps, tips and suggestions are very welcome!
Thanks!
Joachim
--
Hans-Joachim Leidinger | Dipl.-Phys.Ing. Entwicklung eCommerce
[Hans-Joachim.leidinger@bpanet.de]
Black Point Arts Internet Solutions GmbH
http://www.bpanet.de
_______________________________________________
Minivend-users mailing list
Minivend-users@interchange.redhat.com
http://interchange.redhat.com/mailman/listinfo/minivend-users