* Re: [ic] Inventory for options

Jeff Fearn interchange-users@interchange.redhat.com
Tue Nov 27 22:54:00 2001


I changed:
    mv_order_item=[item-code]
    mv_sku=[sql-code]
to
    mv_order_item=[sql-code]
    mv_sku=[item-code]

and got much better results. Now the matrix option code is displayed as the 
sku in the cart, and in the reciept print pages. However the parent sku is 
used in the email, checkout and order admin pages. Also there seems to be no 
decrementing of inventory. Originally I had none in the parent, it basically 
being a phantom. I added some to check if it was being lowered, it was not.

Also the quantity does not get passed to the cart for the matrix options, 
but does for the parent.

Jeff.

>IC 4.8.2-1, RedHat 7.1
>
>If I do the below code, I get the list correctly, however if I click on one
>of the subtype buy links, no item is added to the order. I get the 
>following
>error logged:
>
>Attempt to order missing product code: 00004-Brisbane-25Dec2001
>
>Main Item sku is 00004, followed by location and date for each subtype.
>
>In Order.pm, add_items(), mv_sku is used to replace $items[0], I believe
>this is the area the problem is in. Have been bashing my head a bit trying
>to fix this, any help is much appreciated.
>
>How does IC keep track of orders of subtypes? Or do I need to add that?
>
>Thanks, Jeff.
>
>--------------------------------------------------------------------
>
>re:
>http://interchange.redhat.com/archive/interchange-users/2001/msg07428.html
>
>Sure, but it isn't in the standard flypage. Try this:
>
>      [if-item-data options o_matrix]
>	[query
>	    list=1
>	    sql="
>		  SELECT code FROM options
>		  WHERE sku = '[item-code]'
>		  AND   o_matrix = 1
>	    "]
>	<tr>
><td>[sql-data options description]</td>
><td>-- [if-sql-data inventory quantity > 0]
>			    [page
>				    href=order
>				    form="
>					    mv_order_item=[item-code]
>					    mv_sku=[sql-code]
>				    "]ORDER NOW</A>
>[else]
>			    OUT OF STOCK
>		      [/else]
>		      [/if-sql-data]
>	    </td>
></tr>
>[/query]
>      [/if-item-data]
>
>
>
>
>_________________________________________________________________
>Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp
>
>_______________________________________________
>interchange-users mailing list
>interchange-users@interchange.redhat.com
>http://interchange.redhat.com/mailman/listinfo/interchange-users


_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp