Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-class-memberships-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-class-memberships-create.sql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-class-memberships-create.sql 3 Jul 2002 19:58:07 -0000 1.2 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-class-memberships-create.sql 8 Jul 2002 20:33:50 -0000 1.3 @@ -130,12 +130,12 @@ begin perform acs_rel_type__create_type ( ''dotlrn_student_rel'', - ''dotlrn_member_rel'', ''dotLRN Student Community Membership'', ''dotLRN Student Community Memberships'', - ''dotlrn_student_rel'', + ''dotlrn_member_rel'', ''dotlrn_student_rels'', ''rel_id'', + ''dotlrn_student_rel'', ''dotlrn_class_instance'', null, 0, @@ -148,12 +148,12 @@ perform acs_rel_type__create_type ( ''dotlrn_ta_rel'', - ''dotlrn_admin_rel'', ''dotLRN Teaching Assistant Community Membership'', ''dotLRN Teaching Assistant Community Memberships'', - ''dotlrn_ta_rel'', + ''dotlrn_admin_rel'', ''dotlrn_ta_rels'', ''rel_id'', + ''dotlrn_ta_rel'', ''dotlrn_class_instance'', null, 0, @@ -166,12 +166,12 @@ perform acs_rel_type__create_type ( ''dotlrn_ca_rel'', - ''dotlrn_admin_rel'', ''dotLRN Course Assitant Community Membership'', ''dotLRN Course Assitant Community Memberships'', - ''dotlrn_ca_rel'', + ''dotlrn_admin_rel'', ''dotlrn_ca_rels'', ''rel_id'', + ''dotlrn_ca_rel'', ''dotlrn_class_instance'', null, 0, null, @@ -183,12 +183,12 @@ perform acs_rel_type__create_type ( ''dotlrn_cadmin_rel'', - ''dotlrn_admin_rel'', ''dotLRN Course Administrator Community Membership'', ''dotLRN Course Administrator Community Memberships'', - ''dotlrn_cadmin_rel'', + ''dotlrn_admin_rel'', ''dotlrn_cadmin_rels'', ''rel_id'', + ''dotlrn_cadmin_rel'', ''dotlrn_class_instance'', null, 0, @@ -201,12 +201,12 @@ perform acs_rel_type__create_type ( ''dotlrn_instructor_rel'', - ''dotlrn_admin_rel'', ''dotLRN Instructor Community Membership'', ''dotLRN Instructor Community Memberships'', - ''dotlrn_instructor_rel'', + ''dotlrn_admin_rel'', ''dotlrn_instructor_rels'', ''rel_id'', + ''dotlrn_instructor_rel'', ''dotlrn_class_instance'', null, 0, null, Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-communities-drop.sql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-drop.sql 2 Jul 2002 18:40:08 -0000 1.1 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-drop.sql 8 Jul 2002 20:33:50 -0000 1.2 @@ -26,7 +26,7 @@ -- @version $Id$ -- -\i communities-tree-drop.sql; +\i dotlrn-communities-tree-drop.sql; drop table dotlrn_community_applets; drop table dotlrn_applets; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-package-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-communities-package-create.sql,v diff -u -r1.5 -r1.6 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-package-create.sql 5 Jul 2002 15:26:25 -0000 1.5 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-package-create.sql 8 Jul 2002 20:33:50 -0000 1.6 @@ -132,6 +132,10 @@ from dotlrn_community_types where community_type = p_community_type; + delete + from group_types + where group_type = p_community_type; + PERFORM acs_object_type__drop_type(p_community_type, ''f''); return 0; END; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-tree-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-communities-tree-create.sql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-tree-create.sql 2 Jul 2002 18:40:08 -0000 1.1 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-tree-create.sql 8 Jul 2002 20:33:50 -0000 1.2 @@ -23,7 +23,7 @@ if new.supertype is null then -- if this is the root community_type we leave it''s sortkey as null - return; + return new; else -- else get the max_child_sortkey of the parent community_type select tree_sortkey, max_child_sortkey Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-tree-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-communities-tree-drop.sql,v diff -u -r1.3 -r1.4 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-tree-drop.sql 3 Jul 2002 19:58:07 -0000 1.3 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-communities-tree-drop.sql 8 Jul 2002 20:33:50 -0000 1.4 @@ -17,7 +17,7 @@ -- drop the dotLRN communities tree model -- @author dan chak (chak@openforce.net) -drop trigger dotlrn_communities_in_tr; -drop trigger dotlrn_community_types_in_tr; +drop trigger dotlrn_communities_in_tr on dotlrn_communities_all; +drop trigger dotlrn_community_types_in_tr on dotlrn_community_types; drop function dotlrn_communities_in_tr(); drop function dotlrn_community_types_in_tr(); Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/dotlrn-init.sql,v diff -u -r1.6 -r1.7 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-init.sql 3 Jul 2002 19:58:07 -0000 1.6 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-init.sql 8 Jul 2002 20:33:50 -0000 1.7 @@ -53,6 +53,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -66,6 +67,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -79,6 +81,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -92,6 +95,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -105,6 +109,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -120,7 +125,7 @@ ); -- create the dotlrn_club community type - dotlrn_community_type__new( + perform dotlrn_community_type__new( ''dotlrn_club'', ''dotlrn_community'', ''Club'', @@ -132,7 +137,7 @@ update acs_object_types set table_name = ''dotlrn_class_instance'', package_name = ''dotlrn_class_instance'' where object_type = ''dotlrn_class_instance''; update acs_object_types set table_name = ''dotlrn_club'', package_name = ''dotlrn_club'' where object_type = ''dotlrn_club''; - perform acs_attribute__create_atribute( + perform acs_attribute__create_attribute( ''dotlrn_community'', ''member_pretty_name'', ''string'', @@ -141,11 +146,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute( + perform acs_attribute__create_attribute( ''dotlrn_community'', ''member_pretty_plural'', ''string'', @@ -154,6 +160,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -166,7 +173,7 @@ perform acs_rel_type__create_role(''course_admin'', ''Course Administrator'', ''Course Administrators''); perform acs_rel_type__create_role(''admin'', ''Administrator'', ''Administrators''); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''student_pretty_name'', ''string'', @@ -175,11 +182,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''student_pretty_plural'', ''string'', @@ -188,11 +196,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''course_assistant_pretty_name'', ''string'', @@ -201,11 +210,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''course_assistant_pretty_plural'', ''string'', @@ -214,11 +224,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''teaching_assistant_pretty_name'', ''string'', @@ -227,11 +238,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''teaching_assistant_pretty_plural'', ''string'', @@ -240,11 +252,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''instructor_pretty_name'', ''string'', @@ -253,11 +266,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''instructor_pretty_plural'', ''string'', @@ -266,11 +280,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''course_admin_pretty_name'', ''string'', @@ -279,11 +294,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''course_admin_pretty_plural'', ''string'', @@ -292,11 +308,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''admin_pretty_name'', ''string'', @@ -305,11 +322,12 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_community'', ''admin_pretty_plural'', ''string'', @@ -318,6 +336,7 @@ null, null, null, 0, 1, + null, ''generic'', ''f'' ); @@ -361,12 +380,12 @@ ); -- all rels to communities must have a portal_id - perform acs_attribute__create_atribute ( + perform acs_attribute__create_attribute ( ''dotlrn_member_rel'', ''portal_id'', ''integer'', ''Page ID'', - ''Page IDs'' + ''Page IDs'', null, null, null, 1, 1, Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-professors-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-professors-drop.sql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-professors-drop.sql 5 Jul 2002 15:26:25 -0000 1.4 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-professors-drop.sql 8 Jul 2002 20:33:50 -0000 1.5 @@ -26,5 +26,4 @@ \i dotlrn-professors-sanitize.sql \i dotlrn-professor-profile-provider-drop.sql -drop table dotlrn_full_professor_profile_rels; drop table dotlrn_professor_profile_rels; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-students-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-students-init.sql,v diff -u -r1.6 -r1.7 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-students-init.sql 8 Jul 2002 04:12:21 -0000 1.6 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-students-init.sql 8 Jul 2002 20:33:50 -0000 1.7 @@ -35,10 +35,10 @@ ''dotLRN Profile Student'', ''dotLRN Profile Students'', ''dotlrn_user_profile_rel'', - ''dotlrn_student_profile_rel'', - ''profiled_group'', ''dotlrn_student_profile_rels'', ''rel_id'', + ''dotlrn_student_profile_rel'', + ''profiled_group'', null, 0, null,