Index: openacs-4/packages/acs-tcl/tcl/community-core-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/community-core-procs.tcl,v diff -u -r1.47 -r1.47.2.1 --- openacs-4/packages/acs-tcl/tcl/community-core-procs.tcl 26 Feb 2005 17:52:20 -0000 1.47 +++ openacs-4/packages/acs-tcl/tcl/community-core-procs.tcl 16 Sep 2005 15:47:59 -0000 1.47.2.1 @@ -139,6 +139,25 @@ return $user_id } +ad_proc -public person::person_p { + {-party_id:required} +} { + is this party a person? Cached +} { + return [util_memoize [list ::person::person_p_not_cached -party_id $party_id]] +} + +ad_proc -public person::person_p_not_cached { + {-party_id:required} +} { + is this party a person? Cached +} { + if {[db_0or1row contact_person_exists_p {select '1' from persons where person_id = :party_id}]} { + return 1 + } else { + return 0 + } +} ad_proc -public person::new { {-first_names:required}