Hello Dave,
Thanks for the reply !
here the sequence :
Call from the page dotlrn/admin/club-new.tcl
and
dotlrn_community::new (in packages/dotlrn/tcl/community-procs.tcl)
...
set community_id [package_instantiate_object -extra_vars $extra_vars $object_type]
(with no package_name set !)
if {[empty_string_p $community_key]} {
set community_key [dotlrn_community::generate_key -name $pretty_name]
}
check_community_key_valid_p -complain_if_invalid -community_key $community_key -parent_community_id $parent_community_id
set package_id [dotlrn::get_package_id]
set dotlrn_package_id $package_id
# Set up extra vars
if {[empty_string_p $extra_vars]} {
set extra_vars [ns_set create]
}
ns_set put $extra_vars parent_community_id $parent_community_id
ns_set put $extra_vars community_type $community_type
ns_set put $extra_vars community_key $community_key
ns_set put $extra_vars pretty_name $pretty_name
ns_set put $extra_vars pretty_plural $pretty_name
ns_set put $extra_vars description $description
ns_set put $extra_vars context_id $dotlrn_package_id
db_transaction {
set user_id [ad_conn user_id]
set community_id [package_instantiate_object -extra_vars $extra_vars $object_type]
....
package_instantiate_object (in packages/acs-subsite/tcl/package-procs.tcl)
and since there is no package_name then he do the query ....
...
if {$variable_prefix ne ""} {
append variable_prefix "."
}
# Select out the package name if it wasn't passed in
if { $package_name eq "" } {
if { ![db_0or1row package_select {
select t.package_name
from acs_object_types t
where t.object_type = :object_type
}] } {
error "Object type \"$object_type\" does not exist"
}
}
....
I've check with the head code and it's the same.
Denis