Index: openacs-4/packages/layout-managed-subsite/lib/add-applications-oracle.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/layout-managed-subsite/lib/add-applications-oracle.xql,v
diff -u
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/layout-managed-subsite/lib/add-applications-oracle.xql 20 Jan 2010 00:25:02 -0000 1.1
@@ -0,0 +1,44 @@
+
+
+
+ oracle8.1.6
+
+
+
+ select distinct ap.package_key , ap.package_id
+ from layout_includelets li, apm_packages ap, site_nodes s, apm_package_types apt
+ where s.parent_id = :subsite_node_id
+ and s.object_id = ap.package_id
+ and apm_package.is_child(li.application, ap.package_key) = 1
+ and apt.package_key = ap.package_key
+ and apt.package_type = 'apm_application'
+
+
+
+
+
+ select apt.package_key
+ from apm_package_types apt
+ where exists (select 1
+ from layout_includelets li, site_nodes s
+ where apm_package.is_child(li.application, apt.package_key) = 1)
+ and not exists (select 1
+ from site_nodes s, apm_packages ap
+ where s.parent_id = :subsite_node_id
+ and s.object_id = ap.package_id
+ and ap.package_key = apt.package_key)
+ and apt.package_type = 'apm_application'
+ order by apt.package_key
+
+
+
+
+
+ select title as includelet
+ from layout_includelets
+ where apm_package.is_child(application, :package_key) = 1
+ order by title
+
+
+
+
Index: openacs-4/packages/layout-managed-subsite/lib/add-applications-postgresql.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/layout-managed-subsite/lib/add-applications-postgresql.xql,v
diff -u
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/layout-managed-subsite/lib/add-applications-postgresql.xql 20 Jan 2010 00:25:02 -0000 1.1
@@ -0,0 +1,44 @@
+
+
+
+ postgresql7.2
+
+
+
+ select distinct ap.package_key , ap.package_id
+ from layout_includelets li, apm_packages ap, site_nodes s, apm_package_types apt
+ where s.parent_id = :subsite_node_id
+ and s.object_id = ap.package_id
+ and apm_package__is_child(li.application, ap.package_key)
+ and apt.package_key = ap.package_key
+ and apt.package_type = 'apm_application'
+
+
+
+
+
+ select apt.package_key
+ from apm_package_types apt
+ where exists (select 1
+ from layout_includelets li, site_nodes s
+ where apm_package__is_child(li.application, apt.package_key))
+ and not exists (select 1
+ from site_nodes s, apm_packages ap
+ where s.parent_id = :subsite_node_id
+ and s.object_id = ap.package_id
+ and ap.package_key = apt.package_key)
+ and apt.package_type = 'apm_application'
+ order by apt.package_key
+
+
+
+
+
+ select title as includelet
+ from layout_includelets
+ where apm_package__is_child(application, :package_key)
+ order by title
+
+
+
+
Index: openacs-4/packages/layout-managed-subsite/lib/add-applications.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/layout-managed-subsite/lib/add-applications.xql,v
diff -u -r1.3 -r1.4
--- openacs-4/packages/layout-managed-subsite/lib/add-applications.xql 3 Dec 2008 09:22:00 -0000 1.3
+++ openacs-4/packages/layout-managed-subsite/lib/add-applications.xql 20 Jan 2010 00:25:02 -0000 1.4
@@ -27,18 +27,6 @@
-
-
- select distinct ap.package_key , ap.package_id
- from layout_includelets li, apm_packages ap, site_nodes s, apm_package_types apt
- where s.parent_id = :subsite_node_id
- and s.object_id = ap.package_id
- and apm_package__is_child(li.application, ap.package_key)
- and apt.package_key = ap.package_key
- and apt.package_type = 'apm_application'
-
-
-
select li.title, count(*)
@@ -52,30 +40,4 @@
-
-
- select apt.package_key
- from apm_package_types apt
- where exists (select 1
- from layout_includelets li, site_nodes s
- where apm_package__is_child(li.application, apt.package_key))
- and not exists (select 1
- from site_nodes s, apm_packages ap
- where s.parent_id = :subsite_node_id
- and s.object_id = ap.package_id
- and ap.package_key = apt.package_key)
- and apt.package_type = 'apm_application'
- order by apt.package_key
-
-
-
-
-
- select title as includelet
- from layout_includelets
- where apm_package__is_child(application, :package_key)
- order by title
-
-
-