removing "profile" stuff, using "groups" instead
authormiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 18 Jul 2005 19:43:02 +0000 (19:43 +0000)
committermiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 18 Jul 2005 19:43:02 +0000 (19:43 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@1273 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/cgi-bin/config.html
Open-ILS/src/sql/Postgres/006.schema.permissions.sql

index 1307571..edce602 100644 (file)
@@ -6,8 +6,8 @@
                <h2>Open-ILS Bootstrapping Scripts</h2>
                <hr>
                <ul>
-                       <li><a href='/cgi-bin/superuser-setup.cgi'>Set up Superusers</a></li>
-                       <li><a href='/cgi-bin/user-profiles.cgi'>Configure User Profiles</a></li>
+                       <!-- <li><a href='/cgi-bin/superuser-setup.cgi'>Set up Superusers</a></li> -->
+                       <!-- <li><a href='/cgi-bin/user-profiles.cgi'>Configure User Profiles</a></li> -->
                        <li><a href='/cgi-bin/perms-setup.cgi'>Configure Permisssions</a></li>
                        <li><a href='/cgi-bin/usr_group-setup.cgi'>Configure User Permission Groups</a></li>
                        <li><a href='/cgi-bin/org_unit_types.cgi'>Configure Library Types and Levels</a></li>
index b863c17..f4f82f2 100644 (file)
@@ -80,7 +80,25 @@ BEGIN
        FOR u_perm IN SELECT * FROM permission.usr_perm_map WHERE usr = iuser LOOP
                RETURN NEXT u_perm;
        END LOOP;
-       
+
+       FOR g_list IN   SELECT  *
+                         FROM  permission.grp_ancestors(
+                                 (     SELECT  u.profile
+                                         FROM  actor.usr u
+                                         WHERE u.id = iuser
+                                 )
+                               )
+               LOOP
+
+               FOR u_perm IN   SELECT  DISTINCT -p.id, iuser AS usr, p.perm, p.depth
+                                 FROM  permission.grp_perm_map p
+                                 WHERE p.grp = g_list.id LOOP
+
+                       RETURN NEXT u_perm;
+
+               END LOOP;
+       END LOOP;
+
        FOR grp IN      SELECT  *
                          FROM  permission.usr_grp_map
                          WHERE usr = iuser LOOP