Index: openacs-4/packages/xotcl-core/xotcl-core.info =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xotcl-core/xotcl-core.info,v diff -u -N -r1.92.2.8 -r1.92.2.9 --- openacs-4/packages/xotcl-core/xotcl-core.info 2 Feb 2016 14:56:44 -0000 1.92.2.8 +++ openacs-4/packages/xotcl-core/xotcl-core.info 13 Feb 2016 15:34:55 -0000 1.92.2.9 @@ -10,10 +10,10 @@ t xotcl - + Gustaf Neumann XOTcl library functionality (e.g. thread handling, online documentation, Generic Form and List Classes) - 2015-10-04 + 2016-02-13 WU Vienna <pre> This component contains some core functionality for OpenACS @@ -48,10 +48,10 @@ BSD-Style 2 - + - + Index: openacs-4/packages/xotcl-core/tcl/05-db-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xotcl-core/tcl/05-db-procs.tcl,v diff -u -N -r1.103.2.6 -r1.103.2.7 --- openacs-4/packages/xotcl-core/tcl/05-db-procs.tcl 23 Dec 2015 18:14:33 -0000 1.103.2.6 +++ openacs-4/packages/xotcl-core/tcl/05-db-procs.tcl 13 Feb 2016 15:34:55 -0000 1.103.2.7 @@ -511,29 +511,11 @@ } # - # The view-insert operation is an operation inserting into a view as eg. in + # The default insert-view operation (different in postgres and oracle) # - # insert into xowiki_form_pagei (...) values (...) - # - # Depending on the version of the CR and the driver, we need - # different calls to the driver. The default operation is "dml", but - # in the DB-postgres combo, we need 0or1row. - # Provide the appropriate db_* call for the view update. Earlier - # versions up to 5.3.0d1 used db_dml, newer versions (since around - # july 2006) have to use 0or1row, when the patch for deadlocks - # and duplicate items was applied... - # - apm_version_get -package_key acs-content-repository -array info - array get info - if {[apm_version_names_compare $info(version_name) 5.3.0d1] >= 1} { - ::xo::db::DB-postgresql instproc insert-view-operation {} { return 0or1row } - } - array unset info - - # the default insert-view operation ::xo::db::Driver instproc insert-view-operation {} { return dml } + ::xo::db::DB-postgresql instproc insert-view-operation {} { return 0or1row } - # # DB driver functions, optimized for PostgreSQL # Index: openacs-4/packages/xotcl-core/tcl/cr-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xotcl-core/tcl/cr-procs.tcl,v diff -u -N -r1.54.2.10 -r1.54.2.11 --- openacs-4/packages/xotcl-core/tcl/cr-procs.tcl 9 Feb 2016 13:20:41 -0000 1.54.2.10 +++ openacs-4/packages/xotcl-core/tcl/cr-procs.tcl 13 Feb 2016 15:34:55 -0000 1.54.2.11 @@ -976,26 +976,6 @@ return $item_id } - if {[apm_version_names_compare [ad_acs_version] 5.2] > -1} { - ns_log notice "--OpenACS Version 5.2 or newer [ad_acs_version]" - CrItem set content_item__new_args { - -name $name -parent_id $parent_id -creation_user $creation_user \ - -creation_ip $creation_ip \ - -item_subtype "content_item" -content_type $object_type \ - -description $description -mime_type $mime_type -nls_language $nls_language \ - -is_live f -storage_type $storage_type -package_id $package_id - } - } else { - ns_log notice "--OpenACS Version 5.1 or older [ad_acs_version]" - CrItem set content_item__new_args { - -name $name -parent_id $parent_id -creation_user $creation_user \ - -creation_ip $creation_ip \ - -item_subtype "content_item" -content_type $object_type \ - -description $description -mime_type $mime_type -nls_language $nls_language \ - -is_live f -storage_type $storage_type - } - } - CrItem ad_instproc set_live_revision {-revision_id:required {-publish_status "ready"}} { @param revision_id @param publish_status one of 'live', 'ready' or 'production' @@ -1078,9 +1058,14 @@ set title [expr {[my exists __title_prefix] ? "[my set __title_prefix] ($name)" : $name}] } - #my msg --[subst [[self class] set content_item__new_args]] - set item_id [eval ::xo::db::sql::content_item new \ - [[self class] set content_item__new_args]] + + set item_id [::xo::db::sql::content_item new \ + -name $name -parent_id $parent_id -creation_user $creation_user \ + -creation_ip $creation_ip \ + -item_subtype "content_item" -content_type $object_type \ + -description $description -mime_type $mime_type -nls_language $nls_language \ + -is_live f -storage_type $storage_type -package_id $package_id -with_child_rels f] + if {$storage_type eq "file"} { set text [cr_create_content_file $item_id $revision_id $import_file] }