acs_user::delete (public)

 acs_user::delete -user_id user_id [ -permanent ]

Defined in packages/acs-tcl/tcl/community-core-procs.tcl

Delete a user

Switches:
-user_id
(required)
-permanent
(boolean) (optional)
If provided the user will be deleted permanently from the database. Otherwise the user state will merely be set to "deleted".

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_expose_bug_1144 acs_subsite_expose_bug_1144 (test acs-subsite) acs_user::delete acs_user::delete test_acs_subsite_expose_bug_1144->acs_user::delete test_acs_subsite_test_email_confirmation acs_subsite_test_email_confirmation (test acs-subsite) test_acs_subsite_test_email_confirmation->acs_user::delete test_auth_authenticate auth_authenticate (test acs-authentication) test_auth_authenticate->acs_user::delete test_auth_create_user auth_create_user (test acs-authentication) test_auth_create_user->acs_user::delete test_auth_password_change auth_password_change (test acs-authentication) test_auth_password_change->acs_user::delete acs_user::change_state acs_user::change_state (public) acs_user::delete->acs_user::change_state acs_user::erase_portrait acs_user::erase_portrait (public) acs_user::delete->acs_user::erase_portrait acs_user::flush_cache acs_user::flush_cache (public) acs_user::delete->acs_user::flush_cache db_exec_plsql db_exec_plsql (public) acs_user::delete->db_exec_plsql acs::test::user::delete acs::test::user::delete (public) acs::test::user::delete->acs_user::delete packages/acs-admin/www/users/delete-user.tcl packages/acs-admin/ www/users/delete-user.tcl packages/acs-admin/www/users/delete-user.tcl->acs_user::delete packages/acs-subsite/www/pvt/unsubscribe-2.tcl packages/acs-subsite/ www/pvt/unsubscribe-2.tcl packages/acs-subsite/www/pvt/unsubscribe-2.tcl->acs_user::delete

Testcases:
auth_authenticate, auth_create_user, auth_password_change, auth_password_reset, acs_subsite_expose_bug_1144, acs_subsite_test_email_confirmation
Source code:
    if { ! $permanent_p } {
        change_state -user_id $user_id -state "deleted"
    } else {
        # portrait is also an entry in acs_objects with creation_user
        # set to this user. Therefore, won't be deleted by cascade and
        # must be removed manually
        acs_user::erase_portrait -user_id $user_id
        # flush before actual deletion, so all the information is
        # there to be retrieved
        acs_user::flush_cache -user_id $user_id
        db_exec_plsql permanent_delete {}
    }
Generic XQL file:
packages/acs-tcl/tcl/community-core-procs.xql

PostgreSQL XQL file:
<fullquery name="acs_user::delete.permanent_delete">
    <querytext>
          select acs__remove_user(:user_id);
      </querytext>
</fullquery>
packages/acs-tcl/tcl/community-core-procs-postgresql.xql

Oracle XQL file:
<fullquery name="acs_user::delete.permanent_delete">
    <querytext>
          begin
              acs.remove_user(
                  user_id => :user_id
              );
          end;
      </querytext>
</fullquery>
packages/acs-tcl/tcl/community-core-procs-oracle.xql

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