Index: openacs-4/packages/ecommerce/tcl/ec-style-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/Attic/ec-style-procs.tcl,v
diff -u -r1.3 -r1.4
--- openacs-4/packages/ecommerce/tcl/ec-style-procs.tcl 31 Jan 2002 06:41:59 -0000 1.3
+++ openacs-4/packages/ecommerce/tcl/ec-style-procs.tcl 31 Jan 2002 22:43:54 -0000 1.4
@@ -29,7 +29,7 @@
}
ad_proc ec_style_template_root_internal {} { returns template root } {
- set templateroot [util_memoize {ad_parameter -package_id [ec_id] TemplateRoot "style"} [ec_cache_refresh]]
+ set templateroot [ad_parameter -package_id [ec_id] TemplateRoot "style"]
if {[empty_string_p $templateroot]} {
return [ec_url_concat [ec_pageroot] templates]
}
@@ -104,17 +104,17 @@
# set defaults
set user_preferred_language ""
set user_preferred_plain_fancy ""
- set site_default_language [util_memoize {ad_parameter -package_id [ec_id] LanguageSiteDefault style} [ec_cache_refresh]]
- set site_default_plain_fancy [util_memoize {ad_parameter -package_id [ec_id] PlainFancySiteDefault style} [ec_cache_refresh]]
+ set site_default_language [ad_parameter -package_id [ec_id] LanguageSiteDefault style]
+ set site_default_plain_fancy [ad_parameter -package_id [ec_id] PlainFancySiteDefault style]
# let's figure out first whether or not this is a logged-in person
set user_id [ad_get_user_id]
if { $user_id == 0 } {
# not logged in, maybe cookied though
- if [util_memoize {ad_parameter -package_id [ec_id] LanguageCookieP style} [ec_cache_refresh]] {
+ if [ad_parameter -package_id [ec_id] LanguageCookieP style] {
# let's at least look for a cookie
set user_preferred_language [ec_style_language_from_cookie]
}
- if [util_memoize {ad_parameter -package_id [ec_id] PlainFancyCookieP style} [ec_cache_refresh]] {
+ if [ad_parameter -package_id [ec_id] PlainFancyCookieP style] {
set user_preferred_plain_fancy [ec_style_plain_fancy_from_cookie]
}
} else {
Index: openacs-4/packages/ecommerce/tcl/ecommerce-credit-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-credit-procs.tcl,v
diff -u -r1.2 -r1.3
--- openacs-4/packages/ecommerce/tcl/ecommerce-credit-procs.tcl 18 Jul 2001 18:19:01 -0000 1.2
+++ openacs-4/packages/ecommerce/tcl/ecommerce-credit-procs.tcl 31 Jan 2002 22:43:54 -0000 1.3
@@ -63,7 +63,7 @@
return "authorized_plus_avs"
}
- set currency [util_memoize {ad_parameter -package_id [ec_id] Currency ecommerce} [ec_cache_refresh]]
+ set currency [ad_parameter -package_id [ec_id] Currency ecommerce]
# The above decode, "youth", gives a 1 is the order is younger than 95% of
# a day old and a 0 otherwise. It is used to determine whether the
@@ -230,7 +230,7 @@
ns_log Notice "Eve debug 3"
set cc_args [ns_set new]
- set currency [util_memoize {ad_parameter -package_id [ec_id] Currency ecommerce} [ec_cache_refresh]]
+ set currency [ad_parameter -package_id [ec_id] Currency ecommerce]
ns_set put $cc_args "amount" "$currency $transaction_amount"
ns_set put $cc_args "order-id" "$transaction_id"
@@ -307,7 +307,7 @@
set cc_args [ns_set new]
- ns_set put $cc_args "amount" "[util_memoize {ad_parameter -package_id [ec_id] Currency ecommerce} [ec_cache_refresh]] $transaction_amount"
+ ns_set put $cc_args "amount" "[ad_parameter -package_id [ec_id] Currency ecommerce] $transaction_amount"
ns_set put $cc_args "order-id" "$transaction_id"
ns_set put $cc_args "card-number" "$creditcard_number"
ns_set put $cc_args "card-exp" "$creditcard_expire"
@@ -387,7 +387,7 @@
# variables are slightly renamed to stick with legal tcl variable
# names and our own naming conventions.
- set currency [util_memoize {ad_parameter -package_id [ec_id] Currency ecommerce} [ec_cache_refresh]]
+ set currency [ad_parameter -package_id [ec_id] Currency ecommerce]
if { [ns_set get $cc_args "amount"] != "" } {
# This is to take care of cases where the tax table has output an
@@ -543,7 +543,7 @@
ns_set put $ttcc_output "batch_id" [ec_get_from_quasi_form $relevant_cc_data batch-id]
set long_amount [ec_get_from_quasi_form $relevant_cc_data amount]
regsub -all {[^0-9\.]} $long_amount "" numeric_amount
- # regexp {^[util_memoize {ad_parameter -package_id [ec_id] Currency ecommerce} [ec_cache_refresh]] (.*)} $long_amount garbage numeric_amount
+ # regexp {^[ad_parameter -package_id [ec_id] Currency ecommerce] (.*)} $long_amount garbage numeric_amount
if { [info exists numeric_amount] } {
ns_set put $ttcc_output "amount" $numeric_amount
} else {
Index: openacs-4/packages/ecommerce/tcl/ecommerce-customer-service-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-customer-service-procs.tcl,v
diff -u -r1.3 -r1.4
--- openacs-4/packages/ecommerce/tcl/ecommerce-customer-service-procs.tcl 22 Jul 2001 06:13:37 -0000 1.3
+++ openacs-4/packages/ecommerce/tcl/ecommerce-customer-service-procs.tcl 31 Jan 2002 22:43:54 -0000 1.4
@@ -11,22 +11,22 @@
}
ad_proc ec_customer_service_email_address { {user_identification_id ""} {issue_id ""}} { returns the customer server email address } {
- return [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]
+ return [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]
}
ad_proc ec_customer_service_signature {-html:boolean} {
if $html_p {
- return "Customer Service
-[util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]
+ return "[ad_parameter -package_id [ec_id] CustomerServiceEmailDescription ecommerce]
+[ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]
[ec_insecure_location][ec_url]
"
} else {
- return "Customer Service
-[util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]
+ return "[ad_parameter -package_id [ec_id] CustomerServiceEmailDescription ecommerce]
+[ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]
[ec_insecure_location][ec_url]
"
+ }
}
-}
ad_proc ec_customer_service_simple_issue { customer_service_rep interaction_originator interaction_type interaction_headers order_id issue_type_list action_details {user_id ""} {user_identification_id ""} {begin_new_transaction_p "f"} {gift_certificate_id ""} } {
Creates an issue, interaction, and action and closes the issue.
Index: openacs-4/packages/ecommerce/tcl/ecommerce-email-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-email-procs.tcl,v
diff -u -r1.3 -r1.4
--- openacs-4/packages/ecommerce/tcl/ecommerce-email-procs.tcl 29 Jan 2002 00:11:46 -0000 1.3
+++ openacs-4/packages/ecommerce/tcl/ecommerce-email-procs.tcl 31 Jan 2002 22:43:54 -0000 1.4
@@ -23,7 +23,7 @@
ns_set merge $extra_headers $additional_headers
}
- set from "\"[util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailDescription ecommerce} [ec_cache_refresh]]\" <$reply_to>"
+ set from "\"[ad_parameter -package_id [ec_id] CustomerServiceEmailDescription ecommerce]\" <$reply_to>"
qmail $email_to $from $email_subject $email_body $extra_headers
}
@@ -78,7 +78,7 @@
db_transaction {
# create a customer service issue/interaction/action
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" $order_id $issue_type_list $email_body $user_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" $order_id $issue_type_list $email_body $user_id]
set user_identification_id [lindex $user_identification_and_issue_id 0]
set issue_id [lindex $user_identification_and_issue_id 1]
@@ -161,7 +161,7 @@
db_transaction {
# create a customer service issue/interaction/action
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" $order_id $issue_type_list $email_body $user_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" $order_id $issue_type_list $email_body $user_id]
set user_identification_id [lindex $user_identification_and_issue_id 0]
set issue_id [lindex $user_identification_and_issue_id 1]
@@ -245,7 +245,7 @@
db_transaction {
# create a customer service issue/interaction/action
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" $order_id $issue_type_list $email_body $user_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" $order_id $issue_type_list $email_body $user_id]
set user_identification_id [lindex $user_identification_and_issue_id 0]
set issue_id [lindex $user_identification_and_issue_id 1]
@@ -303,7 +303,7 @@
db_transaction {
# create a customer service issue/interaction/action
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" "" $issue_type_list $email_body $user_id "" "f" $gift_certificate_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" "" $issue_type_list $email_body $user_id "" "f" $gift_certificate_id]
set user_identification_id [lindex $user_identification_and_issue_id 0]
set issue_id [lindex $user_identification_and_issue_id 1]
@@ -375,7 +375,7 @@
db_transaction {
# create a customer service issue/interaction/action
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" "" $issue_type_list $email_body $user_id "" "f" $gift_certificate_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" "" $issue_type_list $email_body $user_id "" "f" $gift_certificate_id]
set user_identification_id [lindex $user_identification_and_issue_id 0]
set issue_id [lindex $user_identification_and_issue_id 1]
@@ -454,7 +454,7 @@
# create a customer service issue/interaction/action
if { ![empty_string_p $user_id] } {
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" "" $issue_type_list $email_body $user_id "" "f" $gift_certificate_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" "" $issue_type_list $email_body $user_id "" "f" $gift_certificate_id]
set user_identification_id [lindex $user_identification_and_issue_id 0]
} else {
# check if the recipient is an unregistered user of the system
@@ -473,7 +473,7 @@
}
- set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [util_memoize {ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce} [ec_cache_refresh]]\nSubject: $email_subject" "" $issue_type_list $email_body "" $user_identification_id "f" $gift_certificate_id]
+ set user_identification_and_issue_id [ec_customer_service_simple_issue "" "automatic" "email" "To: $email\nFrom: [ad_parameter -package_id [ec_id] CustomerServiceEmailAddress ecommerce]\nSubject: $email_subject" "" $issue_type_list $email_body "" $user_identification_id "f" $gift_certificate_id]
}
set issue_id [lindex $user_identification_and_issue_id 1]
Index: openacs-4/packages/ecommerce/tcl/ecommerce-money-computations-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-money-computations-procs.tcl,v
diff -u -r1.2 -r1.3
--- openacs-4/packages/ecommerce/tcl/ecommerce-money-computations-procs.tcl 18 Jul 2001 18:19:01 -0000 1.2
+++ openacs-4/packages/ecommerce/tcl/ecommerce-money-computations-procs.tcl 31 Jan 2002 22:43:54 -0000 1.3
@@ -27,7 +27,7 @@
set lowest_price_name "Our Price"
}
- if { [util_memoize {ad_parameter -package_id [ec_id] UserClassApproveP ecommerce} [ec_cache_refresh]] } {
+ if { [ad_parameter -package_id [ec_id] UserClassApproveP ecommerce] } {
set additional_user_class_restriction "and m.user_class_approved_p = 't'"
} else {
set additional_user_class_restriction "and (m.user_class_approved_p is null or m.user_class_approved_p='t')"
@@ -44,7 +44,7 @@
set lowest_price $price
# only include the user_class_name in the name of the price if
# the user is allowed to see what user classes they're in
- if { [util_memoize {ad_parameter -package_id [ec_id] UserClassUserViewP ecommerce} [ec_cache_refresh]] == 1 } {
+ if { [ad_parameter -package_id [ec_id] UserClassUserViewP ecommerce] == 1 } {
set lowest_price_name "$user_class_name Price"
} else {
set lowest_price_name "Special Price"
@@ -147,7 +147,7 @@
set lowest_price $price
# only include the user_class_name in the name of the price if
# the user is allowed to see what user classes they're in
- if { [util_memoize {ad_parameter -package_id [ec_id] UserClassUserViewP ecommerce} [ec_cache_refresh]] == 1 } {
+ if { [ad_parameter -package_id [ec_id] UserClassUserViewP ecommerce] == 1 } {
set lowest_price_name "$user_class_name Price"
} else {
set lowest_price_name "Special Price"
Index: openacs-4/packages/ecommerce/tcl/ecommerce-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-procs.tcl,v
diff -u -r1.8 -r1.9
--- openacs-4/packages/ecommerce/tcl/ecommerce-procs.tcl 31 Jan 2002 06:41:59 -0000 1.8
+++ openacs-4/packages/ecommerce/tcl/ecommerce-procs.tcl 31 Jan 2002 22:43:54 -0000 1.9
@@ -29,7 +29,7 @@
}
ad_proc -private ec_system_name_mem {} {} {
- return [util_memoize {ad_parameter -package_id [ec_id] SystemName "" Store} [ec_cache_refresh]]
+ return [ad_parameter -package_id [ec_id] SystemName "" Store]
}
ad_proc ec_header_image {} {
@@ -43,7 +43,7 @@
}
ad_proc -private ec_header_image_mem {} {} {
- return [util_memoize {ad_parameter -package_id [ec_id] HeaderAttributes "" "size=+2 face='arial' color=990000"} [ec_cache_refresh]]
+ return [ad_parameter -package_id [ec_id] HeaderAttributes "" "size=+2 face='arial' color=990000"]
}
ad_proc ec_system_owner {} {
@@ -53,7 +53,7 @@
}
ad_proc -private ec_system_owner_mem {} {} {
- set so [util_memoize {ad_parameter -package_id [ec_id] SystemOwner "" ""} [ec_cache_refresh]]
+ set so [ad_parameter -package_id [ec_id] SystemOwner "" ""]
if {[string equal "" $so]} {
return [ad_system_owner]
} else {
@@ -202,7 +202,7 @@
ad_proc -private ec_product_directory_mem {} {
} {
- return [util_memoize {ad_parameter -package_id [ec_id] ProductDataDirectory "" product/} [ec_cache_refresh]]
+ return [ad_parameter -package_id [ec_id] ProductDataDirectory "" product/]
}
# current_location can be "Shopping Cart", "Your Account", "Home", or
@@ -222,7 +222,7 @@
if { [string compare $current_location "Your Account"] == 0 } {
append to_return "Your Account"
} else {
- append to_return "Your Account"
+ append to_return "Your Account"
}
append to_return " | "
if { [string compare $current_location Home] == 0 } {
@@ -247,7 +247,7 @@
# For administrators
ad_proc ec_shipping_cost_summary { base_shipping_cost default_shipping_per_item weight_shipping_cost add_exp_base_shipping_cost add_exp_amount_per_item add_exp_amount_by_weight } { returns cost summary } {
- set currency [util_memoize {ad_parameter -package_id [ec_id] Currency ecommerce} [ec_cache_refresh]]
+ set currency [ad_parameter -package_id [ec_id] Currency ecommerce]
if { ([empty_string_p $base_shipping_cost] || $base_shipping_cost == 0) && ([empty_string_p $default_shipping_per_item] || $default_shipping_per_item == 0) && ([empty_string_p $weight_shipping_cost] || $weight_shipping_cost == 0) && ([empty_string_p $add_exp_base_shipping_cost] || $add_exp_base_shipping_cost == 0) && ([empty_string_p $add_exp_amount_per_item] || $add_exp_amount_per_item == 0) && ([empty_string_p $add_exp_amount_by_weight] || $add_exp_amount_by_weight == 0) } {
return "The customers are not charged for shipping beyond what is specified for each product individually."
@@ -264,7 +264,7 @@
} elseif { [empty_string_p $weight_shipping_cost] || $weight_shipping_cost == 0 } {
append shipping_summary "the per-item cost is [ec_pretty_price $default_shipping_per_item $currency], unless the \"Shipping Price\" has been set for that product (or \"Shipping Price - Additional\", if more than one of the same product is ordered). "
} else {
- append shipping_summary "the per-item-cost is equal to [ec_pretty_price $weight_shipping_cost $currency] times its weight in [util_memoize {ad_parameter -package_id [ec_id] WeightUnits ecommerce} [ec_cache_refresh]], unless the \"Shipping Price\" has been set for that product (or \"Shipping Price - Additional\", if more than one of the same product is ordered). "
+ append shipping_summary "the per-item-cost is equal to [ec_pretty_price $weight_shipping_cost $currency] times its weight in [ad_parameter -package_id [ec_id] WeightUnits ecommerce], unless the \"Shipping Price\" has been set for that product (or \"Shipping Price - Additional\", if more than one of the same product is ordered). "
}
if { ([empty_string_p $add_exp_base_shipping_cost] || $add_exp_base_shipping_cost == 0) && ([empty_string_p $add_exp_amount_per_item] || $add_exp_amount_per_item == 0) && ([empty_string_p $add_exp_amount_by_weight] || $add_exp_amount_by_weight == 0) } {
@@ -277,7 +277,7 @@
append express_part_of_shipping_summary "An additional amount of [ec_pretty_price $add_exp_amount_per_item $currency] is added for each item, on top of the amount charged for Regular Shipping. "
}
if { ![empty_string_p $add_exp_amount_by_weight] && $add_exp_amount_by_weight != 0 } {
- append express_part_of_shipping_summary "An additional amount of [ec_pretty_price $add_exp_amount_by_weight $currency] times the weight in [util_memoize {ad_parameter -package_id [ec_id] WeightUnits ecommerce} [ec_cache_refresh]] of each item is added, on top of the amount charged for Regular Shipping. "
+ append express_part_of_shipping_summary "An additional amount of [ec_pretty_price $add_exp_amount_by_weight $currency] times the weight in [ad_parameter -package_id [ec_id] WeightUnits ecommerce] of each item is added, on top of the amount charged for Regular Shipping. "
}
}
@@ -574,14 +574,14 @@
# this won't show anything if ProductCommentsAllowP=0
ad_proc ec_customer_comments { product_id {comments_sort_by ""} {prev_page_url ""} {prev_args_list ""} } { returns customer comments } {
- if { [util_memoize {ad_parameter -package_id [ec_id] ProductCommentsAllowP ecommerce} [ec_cache_refresh]] == 0 } {
+ if { [ad_parameter -package_id [ec_id] ProductCommentsAllowP ecommerce] == 0 } {
return ""
}
set end_of_comment_query ""
set sort_blurb ""
- if { [util_memoize {ad_parameter -package_id [ec_id] ProductCommentsNeedApprovalP ecommerce} [ec_cache_refresh]] == 1 } {
+ if { [ad_parameter -package_id [ec_id] ProductCommentsNeedApprovalP ecommerce] == 1 } {
append end_of_comment_query "and c.approved_p = 't'"
} else {
append end_of_comment_query "and (c.approved_p = 't' or c.approved_p is null)\n"
@@ -627,7 +627,7 @@
select avg(rating) from ec_product_comments where product_id = :product_id and approved_p = 't'
}]]
Number of reviews: [db_string n_reviews_select "
- select count(*) from ec_product_comments where product_id = :product_id and (approved_p='t' [ec_decode [util_memoize {ad_parameter -package_id [ec_id] ProductCommentsNeedApprovalP ecommerce} [ec_cache_refresh]] "0" "or approved_p is null" ""])
+ select count(*) from ec_product_comments where product_id = :product_id and (approved_p='t' [ec_decode [ad_parameter -package_id [ec_id] ProductCommentsNeedApprovalP ecommerce] "0" "or approved_p is null" ""])
"] ($sort_blurb)
@@ -715,7 +715,7 @@ from ec_products where product_id = :product_id "] - if { [util_memoize {ad_parameter -package_id [ec_id] AllowPreOrdersP ecommerce} [ec_cache_refresh]] } { + if { [ad_parameter -package_id [ec_id] AllowPreOrdersP ecommerce] } { set r "