Index: openacs-4/packages/ecommerce/tcl/ecommerce-procs-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-procs-oracle.xql,v diff -u -r1.3 -r1.4 --- openacs-4/packages/ecommerce/tcl/ecommerce-procs-oracle.xql 15 Jul 2001 20:47:21 -0000 1.3 +++ openacs-4/packages/ecommerce/tcl/ecommerce-procs-oracle.xql 24 Nov 2001 03:52:22 -0000 1.4 @@ -33,7 +33,7 @@ select c.one_line_summary, c.rating, c.user_comment, - to_char(c.last_modified,'Day Month DD, YYYY') last_modified_pretty, + to_char(c.last_modified,'Day Month DD, YYYY') as last_modified_pretty, u.email, u.user_id from ec_product_comments c, Index: openacs-4/packages/ecommerce/tcl/ecommerce-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-procs-postgresql.xql,v diff -u -r1.6 -r1.7 --- openacs-4/packages/ecommerce/tcl/ecommerce-procs-postgresql.xql 16 Jul 2001 20:07:06 -0000 1.6 +++ openacs-4/packages/ecommerce/tcl/ecommerce-procs-postgresql.xql 24 Nov 2001 03:52:22 -0000 1.7 @@ -33,7 +33,7 @@ select c.one_line_summary, c.rating, c.user_comment, - to_char(c.last_modified,'Day Month DD, YYYY') last_modified_pretty, + to_char(c.last_modified,'Day Month DD, YYYY') as last_modified_pretty, u.email, u.user_id from ec_product_comments c, 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.5 -r1.6 --- openacs-4/packages/ecommerce/tcl/ecommerce-procs.tcl 22 Oct 2001 08:02:10 -0000 1.5 +++ openacs-4/packages/ecommerce/tcl/ecommerce-procs.tcl 24 Nov 2001 03:52:22 -0000 1.6 @@ -610,7 +610,7 @@ select c.one_line_summary, c.rating, c.user_comment, - to_char(c.last_modified,'Day Month DD, YYYY') last_modified_pretty, + to_char(c.last_modified,'Day Month DD, YYYY') as last_modified_pretty, u.email, u.user_id from ec_product_comments c, @@ -748,7 +748,7 @@ set current_location [lindex $current_location 1] foreach step {Welcome Address Verify Shipping Payment Confirm} { set category_descriptions Checkout: - ns_log debug ec_navbar $current_location ::: $step + ns_log debug "ec_navbar $current_location ::: $step" if {[string equal -nocase $current_location $step]} { lappend linked_category_list "$step" } else { @@ -1481,7 +1481,7 @@ } elseif {[string compare $_ec_cookie_requirement "cookies_are_not_required"] == 0} { # For this page continue - ns_log debug ec_create_session "cookies are off but that's okay, they aren't required" + ns_log debug "ec_create_session cookies are off but that's okay, they aren't required" } elseif {[string compare $_ec_cookie_requirement "shopping_cart_required"] == 0} { Index: openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs-postgresql.xql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs-postgresql.xql 18 Jul 2001 23:46:14 -0000 1.4 +++ openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs-postgresql.xql 24 Nov 2001 03:50:55 -0000 1.5 @@ -1,246 +1,222 @@ - postgresql7.1 + postgresql7.1 - - - + + select order_id, ec_order_cost(order_id) as total_order_price from ec_orders where order_state = 'confirmed' and (current_timestamp - confirmed_date) > timespan_days(1/96::float) + + - - - - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - - - - - - + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + + + + select g.gift_certificate_id, t.transaction_id from ec_gift_certificates g, ec_financial_transactions t where g.gift_certificate_id=t.gift_certificate_id and g.gift_certificate_state = 'confirmed' and (current_timestamp - g.issue_date) > timespan_days(1/96::float) + + - - - - - - - - update ec_financial_transactions - set authorized_date=current_timestamp, - to_be_captured_p='t' - where transaction_id = :transaction_id - - - - - - - - - update ec_gift_certificates - set authorized_date = current_timestamp, - gift_certificate_state = :cc_result - where gift_certificate_id = :gift_certificate_id - - - - - - - + + + update ec_financial_transactions + set authorized_date=current_timestamp, + to_be_captured_p='t' + where transaction_id = :transaction_id + + + + + + update ec_gift_certificates + set authorized_date = current_timestamp, + gift_certificate_state = :cc_result + where gift_certificate_id = :gift_certificate_id + + + + + update ec_orders set order_state='expired', expired_date=current_timestamp where order_state='in_basket' and current_timestamp-in_basket_date > timespan_days([util_memoize {ad_parameter -package_id [ec_id] CartDuration ecommerce} [ec_cache_refresh]]::float) - - - - - - + + + + + update ec_items set item_state='expired', expired_date=current_timestamp where item_state='in_basket' and order_id in (select order_id from ec_orders where order_state='expired') - - + + + + + + select transaction_id, order_id from ec_financial_transactions + where to_be_captured_p='t' + and current_timestamp-to_be_captured_date > timespan_days(1/48::float) + and authorized_date is null + and failed_p='f' + + + + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, 'invalid input to ec_creditcard_authorization in ec_unauthorized_transactions', :order_id) + + - - - - - select transaction_id, order_id from ec_financial_transactions - where to_be_captured_p='t' - and current_timestamp-to_be_captured_date > timespan_days(1/48::float) - and authorized_date is null - and failed_p='f' - - - - - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, 'invalid input to ec_creditcard_authorization in ec_unauthorized_transactions', :order_id) - - - - - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - - - - - + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + + + + update ec_financial_transactions set authorized_date=current_timestamp where transaction_id=:transaction_id - - + + - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - + + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + - - - + + + update ec_financial_transactions set marked_date=current_timestamp where transaction_id=:transaction_id - - + + - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - - - - - + + + update ec_financial_transactions set refunded_date=current_timestamp where transaction_id=:transaction_id + + + + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + + + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + + + + update ec_financial_transactions set settled_date=current_timestamp where transaction_id=:transaction_id - - + + - - - + + + select case when marked_date + '2 days'::interval < now() then 1 else 0 end from ec_financial_transactions where transaction_id=:transaction_id - - + + + + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - - - - - - - select transaction_id, order_id from ec_financial_transactions - where transaction_type='refund' - and current_timestamp - inserted_date > timespan_days(1/48::float) - and refunded_date is null - and failed_p='f' - - - - - - - + + + select transaction_id, order_id from ec_financial_transactions + where transaction_type='refund' + and current_timestamp - inserted_date > timespan_days(1/48::float) + and refunded_date is null + and failed_p='f' + + + + + update ec_financial_transactions set refunded_date=current_timestamp where transaction_id=:transaction_id - - - - - - - - insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - - - - - + + + + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + + + + update ec_financial_transactions set refunded_date=current_timestamp where transaction_id=:transaction_id - - - - - - + + + + + update ec_financial_transactions set refund_settled_date=current_timestamp where transaction_id=:transaction_id - - - - - - + + + + + select case when refunded_date + '2 days'::interval < now() then 1 else 0 end from ec_financial_transactions where transaction_id=:transaction_id - - + + - - - + + insert into ec_problems_log - (problem_id, problem_date, problem_details, order_id) - values - (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) - - - + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + - + + + insert into ec_problems_log + (problem_id, problem_date, problem_details, order_id) + values + (ec_problem_id_sequence.nextval, current_timestamp, :problem_details, :order_id) + + + Index: openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.tcl 24 Oct 2001 03:12:31 -0000 1.4 +++ openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.tcl 24 Nov 2001 03:50:55 -0000 1.5 @@ -209,6 +209,7 @@ select avs_code from ec_cybercash_log where transaction_id = :transaction_id + and avs_code != '' and txn_attempted_time = (select MAX(txn_attempted_time) from ec_cybercash_log log2 where log2.transaction_id = :transaction_id) Index: openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.xql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.xql 18 Jul 2001 23:46:14 -0000 1.2 +++ openacs-4/packages/ecommerce/tcl/ecommerce-scheduled-procs.xql 24 Nov 2001 03:50:55 -0000 1.3 @@ -76,6 +76,7 @@ select avs_code from ec_cybercash_log where transaction_id = :transaction_id + and avs_code != '' and txn_attempted_time = (select MAX(txn_attempted_time) from ec_cybercash_log log2 where log2.transaction_id = :transaction_id)