parameter::set_value (public)

 parameter::set_value [ -package_id package_id ] -parameter parameter \
    -value value

Defined in packages/acs-tcl/tcl/parameter-procs.tcl

Set the value of a package instance parameter.

Switches:
-package_id (optional)
what package to set the parameter in. Defaults to [ad_conn package_id]
-parameter (required)
which parameter's value to set
-value (required)
what value to set said parameter to

Partial Call Graph (max 5 caller/called nodes):
%3 test_auth_email_on_password_change auth_email_on_password_change (test acs-authentication) parameter::set_value parameter::set_value test_auth_email_on_password_change->parameter::set_value test_auth_password_change auth_password_change (test acs-authentication) test_auth_password_change->parameter::set_value test_auth_use_email_for_login_p auth_use_email_for_login_p (test acs-authentication) test_auth_use_email_for_login_p->parameter::set_value test_locale__test_system_package_setting locale__test_system_package_setting (test acs-lang) test_locale__test_system_package_setting->parameter::set_value test_parameter__check_procs parameter__check_procs (test acs-tcl) test_parameter__check_procs->parameter::set_value acs::clusterwide acs::clusterwide parameter::set_value->acs::clusterwide ad_parameter_cache ad_parameter_cache (public) parameter::set_value->ad_parameter_cache ad_requested_object_id ad_requested_object_id (private) parameter::set_value->ad_requested_object_id db_exec_plsql db_exec_plsql (public) parameter::set_value->db_exec_plsql acs_admin::check_expired_certificates acs_admin::check_expired_certificates (private) acs_admin::check_expired_certificates->parameter::set_value acs_admin::require_site_wide_package acs_admin::require_site_wide_package (public) acs_admin::require_site_wide_package->parameter::set_value acs_privacy::privacy_control_set acs_privacy::privacy_control_set (public, deprecated) acs_privacy::privacy_control_set->parameter::set_value bug_tracker::install_parameters_setup bug_tracker::install_parameters_setup (public) bug_tracker::install_parameters_setup->parameter::set_value cookieconsent::after-upgrade cookieconsent::after-upgrade (private) cookieconsent::after-upgrade->parameter::set_value

Testcases:
auth_password_change, auth_use_email_for_login_p, auth_email_on_password_change, locale__test_system_package_setting, password_recovery_page, subsite_api, parameter__check_procs
Source code:
    if {$package_id eq ""} {
        set package_id [ad_requested_object_id]
    }

    #
    # We have two different definitions of set_parameter_value/3 with
    # differently typed arguments.  Polyphorism is not supported
    # yet. We should define set_value/4, or mirror the names we have
    # here (set_value vs. set_global_value). For the time being, we
    # keep the .xql-files for "db_exec_plsql" around, maybe some other
    # use cases hint a different approach.
    #
    db_exec_plsql set_parameter_value {}

    #::acs::dc call apm set_value  #    -package_id $package_id  #    -parameter_name $parameter  #    -attr_value $value

    try {
        acs::clusterwide callback subsite::parameter_changed  -package_id $package_id  -parameter $parameter  -value $value
    } on error {errorMsg} {
        #
        # Check if error happened during startup. The callbacks might
        # not be loaded yet.
        #
        if {[ns_ictl epoch] == 0} {
            ns_log notice "callback subsite::parameter_changed failed during startup: $errorMsg"
        } else {
            # The error did not happen during startup, so rethrow the
            # error.
            error $errorMsg $::errorInfo
        }
    }
    ad_parameter_cache -delete $package_id $parameter
Generic XQL file:
packages/acs-tcl/tcl/parameter-procs.xql

PostgreSQL XQL file:
<fullquery name="parameter::set_value.set_parameter_value">
    <querytext>
            select apm__set_value(
                :package_id::integer,
                :parameter,
                :value
            );
        </querytext>
</fullquery>
packages/acs-tcl/tcl/parameter-procs-postgresql.xql

Oracle XQL file:
<fullquery name="parameter::set_value.set_parameter_value">
    <querytext>
            begin
                apm.set_value(
                    package_id => :package_id,
                    parameter_name => :parameter,
                    attr_value => :value
                );
            end;
        </querytext>
</fullquery>
packages/acs-tcl/tcl/parameter-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: