Commerce Server General - Re: Pipeline problem with diferent pricing for different customer

This is Interesting: Free IT Magazines  
Home > Archive > Commerce Server General > March 2005 > Re: Pipeline problem with diferent pricing for different customer





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Re: Pipeline problem with diferent pricing for different customer
bobby

2005-03-25, 8:46 pm

Dear Ravi:
Just one last question. I changed the scriptor to this:


on error resume next
if orderform.items.[shopper_type] = 1 AND orderform.items.[discount] = 2
then

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price] * .8
next

else

if orderform.items.[shopper_type] = 1 AND orderform.items.[discount] = 3
then

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price] * .75
next

else

if orderform.items.[shopper_type] = 1 AND orderform.items.[discount] = 4
then

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price] * .4
next

else

if orderform.items.[shopper_type] = 2 AND orderform.items.[discount] = 2
then

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price] * .72
next

else

if orderform.items.[shopper_type] = 2 AND orderform.items.[discount] = 3
then

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price] * .6
next

else

if orderform.items.[shopper_type] = 2 AND orderform.items.[discount] = 4
then

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price] * .15
next

else

for each item in orderform.items
item.[_product_list_price] = item.[_product_list_price]
next

end if
end if
end if
end if
end if
end if


the idea was to discount item in the basket based on the category and so
called
orderform.items.[discount]
the problem rises when we are using for each loop. In the order I get each
item seperatly with different orderform.items.[discount] and
orderform.items.[shopper_type] but when I use the for each loop it appliys
the first items discout to all the items. Do you have any suggestion for
this.
Then again I appreciate the help.
Thanks
Bobby
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com