Index: openacs-4/packages/dotlrn-ecommerce/www/admin/index.adp
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-ecommerce/www/admin/index.adp,v
diff -u -r1.22 -r1.23
--- openacs-4/packages/dotlrn-ecommerce/www/admin/index.adp 18 Aug 2005 03:35:41 -0000 1.22
+++ openacs-4/packages/dotlrn-ecommerce/www/admin/index.adp 18 Aug 2005 18:39:54 -0000 1.23
@@ -5,7 +5,9 @@
Course Registration
-- #dotlrn-ecommerce.Shopping_Cart#
+
+
- #dotlrn-ecommerce.Shopping_Cart#
+
- #dotlrn-ecommerce.Process_Registration#
- #dotlrn-ecommerce.Course_Quick_Jump#
Index: openacs-4/packages/dotlrn-ecommerce/www/admin/index.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-ecommerce/www/admin/index.tcl,v
diff -u -r1.11 -r1.12
--- openacs-4/packages/dotlrn-ecommerce/www/admin/index.tcl 18 Aug 2005 03:35:41 -0000 1.11
+++ openacs-4/packages/dotlrn-ecommerce/www/admin/index.tcl 18 Aug 2005 18:39:54 -0000 1.12
@@ -129,3 +129,18 @@
set package_locale [lang::system::locale]
set enable_applications_p [parameter::get -package_id [ad_conn package_id] -parameter EnableCourseApplicationsP -default 1]
+
+# Determine if we should show the shopping cart link
+set user_session_id [ec_get_user_session_id]
+if { [llength [set purchaser [db_list transactions {
+ select deo.patron_id
+ from ec_orders o, ec_items i, dotlrn_ecommerce_orders deo
+ where o.order_id = i.order_id
+ and i.item_id = deo.item_id
+ and o.order_state = 'in_basket'
+ and o.user_session_id = :user_session_id
+ group by deo.patron_id
+}]]] == 1 } {
+ set user_id [lindex $purchaser 0]
+ set shopping_cart_url [export_vars -base ../ecommerce/shopping-cart { user_id }]
+}
\ No newline at end of file