Index: openacs-4/contrib/packages/classified-ads/tcl/classified-ads-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/classified-ads/tcl/classified-ads-procs.tcl,v
diff -u -r1.5 -r1.6
--- openacs-4/contrib/packages/classified-ads/tcl/classified-ads-procs.tcl 23 Jul 2003 22:39:16 -0000 1.5
+++ openacs-4/contrib/packages/classified-ads/tcl/classified-ads-procs.tcl 24 Jul 2003 20:20:10 -0000 1.6
@@ -331,7 +331,7 @@
if {[template::element::exists $form_id $item_id_element]} {
set item_id [template::element::get_value $form_id $item_id_element]
} else {
- ad_return_complaint 1 "
passed in item id not found"
+ ad_return_error "Passed item_id not found" " Passed in item id not found."
ad_script_abort
}
@@ -359,6 +359,10 @@
set name "$content_type -- $item_id"
set title [template::element::get_value $form_id $title_column]
+ #
+ # RBM: FIXME? This doesn't look like what should be done to me.
+ #
+
if {[empty_string_p $title]} {
# make sure there is always a title
set title $name
@@ -373,6 +377,7 @@
# do everything in a transaction
db_transaction {
+ #
# DEDS: FIXME - this only supports one table
# fix it so that it can span multiple tables
@@ -387,6 +392,7 @@
# Get the type specific attributes
set type_specific_attr_list [get_attributes -content_type $content_type -storage "type_specific"]
+ ns_log notice "RBM: type_specific = $type_specific_attr_list"
if {[llength $type_specific_attr_list]} {
#
@@ -403,7 +409,11 @@
set table_name [ns_set get $one_attribute table_name]
set datatype [ns_set get $one_attribute datatype]
+ ns_log notice "RBM: column = $column_name, table = $table_name, datatype = $datatype"
+
if {[template::element::exists $form_id $column_name]} {
+ ns_log notice "RBM: Exists in the form"
+
lappend name_list $column_name
lappend value_list ":$column_name"
lappend update_list "$column_name = :$column_name"
@@ -428,13 +438,15 @@
# update the type specific data
+ ns_log notice "RBM: plsql_query: $plsql_query"
db_dml update_data {} -bind $type_specific_bind_vars
ns_set free $type_specific_bind_vars
}
# get the generic attributes
set generic_attr_list [get_attributes -content_type $content_type -storage "generic"]
+ ns_log notice "RBM: generic = $generic_attr_list"
if {[llength $generic_attr_list]} {
foreach one_attribute $generic_attr_list {