Index: openacs-4/packages/acs-subsite/catalog/acs-subsite.de_DE.ISO-8859-1.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/catalog/acs-subsite.de_DE.ISO-8859-1.xml,v diff -u -r1.24 -r1.25 --- openacs-4/packages/acs-subsite/catalog/acs-subsite.de_DE.ISO-8859-1.xml 8 Jun 2005 16:35:48 -0000 1.24 +++ openacs-4/packages/acs-subsite/catalog/acs-subsite.de_DE.ISO-8859-1.xml 10 Jun 2005 09:47:22 -0000 1.25 @@ -31,6 +31,7 @@ Deaktivieren Allgemeine Informationen: Lebenslauf + Mime Type der Biographie Passwort zur�cksetzen durch lokale Authentifizierungsstelle nicht unterst�tzt Liste der Teilnehmer verborgen Sprache einstellen Index: openacs-4/packages/acs-subsite/catalog/acs-subsite.en_US.ISO-8859-1.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/catalog/acs-subsite.en_US.ISO-8859-1.xml,v diff -u -r1.69 -r1.70 --- openacs-4/packages/acs-subsite/catalog/acs-subsite.en_US.ISO-8859-1.xml 8 Jun 2005 16:36:03 -0000 1.69 +++ openacs-4/packages/acs-subsite/catalog/acs-subsite.en_US.ISO-8859-1.xml 10 Jun 2005 09:47:22 -0000 1.70 @@ -265,6 +265,7 @@ What other people see when they click your name You can't have a < in your first name because it will look like an HTML tag and confuse other users. You can't have a < in your last name because it will look like an HTML tag and confuse other users. + You have to provide at least an object_id_on or object_id_two You won't get any email until after %pretty_date%. Your email has been confirmed. You may now log into %system_name%. @@ -284,6 +285,7 @@ Member Member State Members + Missing argument Name New Password No applications @@ -401,6 +403,10 @@ upload a portrait upload a replacement portrait Upload Portrait + User Portrait + User Portraits + User Profile + User Profiles Username No user with username '%username%' found for authority %this_authority% Username required Index: openacs-4/packages/acs-subsite/sql/postgresql/portraits.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/sql/postgresql/portraits.sql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/acs-subsite/sql/postgresql/portraits.sql 17 Apr 2001 04:10:06 -0000 1.2 +++ openacs-4/packages/acs-subsite/sql/postgresql/portraits.sql 10 Jun 2005 09:47:23 -0000 1.3 @@ -45,8 +45,8 @@ PERFORM acs_rel_type__create_type ( ''user_portrait_rel'', - ''User Portrait'', - ''User Portraits'', + ''#acs-subsite.User_Portrait#'', + ''#acs-subsite.User_Portraits#'', ''relationship'', ''user_portraits'', ''user_id'', Index: openacs-4/packages/acs-subsite/sql/postgresql/user-profiles-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/sql/postgresql/user-profiles-create.sql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/acs-subsite/sql/postgresql/user-profiles-create.sql 28 Aug 2001 18:34:55 -0000 1.4 +++ openacs-4/packages/acs-subsite/sql/postgresql/user-profiles-create.sql 10 Jun 2005 09:47:23 -0000 1.5 @@ -53,8 +53,8 @@ PERFORM acs_rel_type__create_type ( ''user_profile'', - ''User Profile'', - ''User Profiles'', + ''#acs-subsite.User_Profile#'', + ''#acs-subsite.User_Profiles#'', ''membership_rel'', ''user_profiles'', ''profile_id'', Index: openacs-4/packages/acs-subsite/tcl/relation-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/tcl/relation-procs.tcl,v diff -u -r1.12 -r1.13 --- openacs-4/packages/acs-subsite/tcl/relation-procs.tcl 4 Mar 2005 21:22:05 -0000 1.12 +++ openacs-4/packages/acs-subsite/tcl/relation-procs.tcl 10 Jun 2005 09:47:23 -0000 1.13 @@ -322,17 +322,49 @@ ad_proc -public relation::get_object_one { {-object_id_two:required} {-rel_type "membership_rel"} + {-multiple_p "f"} } { Return the object_id of object one if a relation of rel_type exists between the supplied object_id_two and it. + + @param multiple_p If set to "t" return a list instead of only one object_id } { - return [db_string select_object_one {} -default {}] + if {$multiple_p == "t"} { + return [db_list select_object_one {}] + } else { + return [db_string select_object_one {} -default {}] + } } ad_proc -public relation::get_object_two { {-object_id_one:required} {-rel_type "membership_rel"} + {-multiple_p "f"} } { Return the object_id of object two if a relation of rel_type exists between the supplied object_id_one and it. + + @param multiple_p If set to "t" return a list instead of only one object_id } { - return [db_string select_object_two {} -default {}] + if {$multiple_p == "t"} { + return [db_list select_object_two {}] + } else { + return [db_string select_object_two {} -default {}] + } } + +ad_proc -public relation::get_objects { + {-object_id_one ""} + {-object_id_two ""} + {-rel_type "membership_rel"} +} { + Return the list of object_ids if a relation of rel_type exists between the supplied object_id and it. +} { + if {[empty_string_p $object_id_one]} { + if {[empty_string_p $object_id_two]} { + ad_return_error "[_ acs-subsite.Missing_argument]" "[_ acs-subsite.lt_You_have_to_provide_a]" + } else { + return [relation::get_object_one -object_id_two $object_id_two -rel_type $rel_type -multiple_p "t"] + } + } else { + return [relation::get_object_two -object_id_one $object_id_one -rel_type $rel_type -multiple_p "t"] + } +}