Content Selection Framework - Easy Cart Question

This is Interesting: Free IT Magazines  
Home > Archive > Content Selection Framework > February 2004 > Easy Cart Question





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 Easy Cart Question
Randy Jeppesen

2004-02-07, 9:38 am

On my Basket.aspx page I display the items in my cart. I run the basket
through a pipeline to modify some values and to add catalog info to the line
items (QueryCatalogInfo). I am able to get the _product_<property name>
from the line items without an issue. After the cart has been run through
the pipeline, I save it. For each line item that is displayed on my
basket.aspx there is a button that pops a "detailed view" of the product. I
am attempting to access the same information from my cart as before on my
detailedview.aspx pop up page. But for some reason I am not able to get the
_product_<property name> values out of the saved cart. In order to do it I
have to re-run the basket through the pipeline again ( re-QueryCatalogInfo).
What am I missing? I want to understand why the _product_<property name>
values are not saved when I do a cart.save. I am trying to optimize this
application to the best of my ability. Any help or suggestions are
appreciated.

-Randy


Erik Mavrinac [MSFT]

2004-02-07, 9:39 am

Easy to describe, requires some work on your part. The Commerce Dictionary objects in which orders are stored do not save to the database any keys
starting with an underscore, including the _product_... keys. If you want to be able to see the contents of underscore keys after saving your completed order
to the database, you could:

(a) Run a pipeline after reloading the order that executes QueryCatalogInfo to recreate these values. This may not be the best option because you catalog
information may change over time, whereas you want to show the user the values at the time the order was placed.

(b) Add or modify a Scriptor script to the checkout pipeline to copy underscored keys to non-underscore keys, e.g. _product_weight => my_product_weight .
This increases the size of your database rows containing the information, but preserves a snapshot of the information at the time the completed order was
created. Note that Scriptor is pretty slow and not very scalable, but relatively easy to set up and script for.

(c) Like (b) but do the copies in site code. Not good since it means copying code everywhere or having to import a common subroutine.

(d) Like (b) but do the copies within your own custom pipeline component. Best for scalability and component code reuse, more difficult than Scriptor.

I hope this helps...

Erik


--------------------
From: "Randy Jeppesen" <randywalker75@hotmail.com>
Subject: Easy Cart Question
Date: Wed, 28 Jan 2004 15:10:20 -0500

On my Basket.aspx page I display the items in my cart. I run the basket
through a pipeline to modify some values and to add catalog info to the line
items (QueryCatalogInfo). I am able to get the _product_<property name>
from the line items without an issue. After the cart has been run through
the pipeline, I save it. For each line item that is displayed on my
basket.aspx there is a button that pops a "detailed view" of the product. I
am attempting to access the same information from my cart as before on my
detailedview.aspx pop up page. But for some reason I am not able to get the
_product_<property name> values out of the saved cart. In order to do it I
have to re-run the basket through the pipeline again ( re-QueryCatalogInfo).
What am I missing? I want to understand why the _product_<property name>
values are not saved when I do a cart.save. I am trying to optimize this
application to the best of my ability. Any help or suggestions are
appreciated.

-Randy





--

This posting is provided "AS IS" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm

Note: For the benefit of the community-at-large, all responses to this message are best directed to the newsgroup/thread from which they originated.
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com