phpcompta-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpcompta-dev] r4583 - phpcompta/trunk/html/admin/sql/patch


From: phpcompta-dev
Subject: [Phpcompta-dev] r4583 - phpcompta/trunk/html/admin/sql/patch
Date: Thu, 8 Dec 2011 00:11:09 +0100 (CET)

Author: danydb
Date: 2011-12-08 00:11:07 +0100 (Thu, 08 Dec 2011)
New Revision: 4583

Added:
   phpcompta/trunk/html/admin/sql/patch/upgrade99.sql
Log:
fix bug in menu, profile and security for PRINTJRN

Added: phpcompta/trunk/html/admin/sql/patch/upgrade99.sql
===================================================================
--- phpcompta/trunk/html/admin/sql/patch/upgrade99.sql                          
(rev 0)
+++ phpcompta/trunk/html/admin/sql/patch/upgrade99.sql  2011-12-07 23:11:07 UTC 
(rev 4583)
@@ -0,0 +1,32 @@
+begin;
+CREATE OR REPLACE FUNCTION comptaproc.get_menu_dependency(profile_menu_id int)
+  RETURNS SETOF int AS
+$BODY$
+declare
+       i int;
+       x int;
+       e int;
+begin
+       for x in select pm_id,me_code
+                       from profile_menu
+                       where me_code_dep in (select me_code from profile_menu 
where pm_id=profile_menu_id)
+                       and p_id = (select p_id from profile_menu where 
pm_id=profile_menu_id)
+       loop
+               return next x;
+
+       for e in select *  from comptaproc.get_menu_dependency_pm(x)
+               loop
+                       return next e;
+               end loop;
+
+       end loop;
+       return;
+end;
+$BODY$
+LANGUAGE plpgsql;
+
+delete from profile_menu where p_id=2 and me_code_dep='DIVPARM';
+delete from profile_menu where p_id=2 and me_code_dep='MOD';
+update version set val=100;
+
+commit;
\ No newline at end of file




reply via email to

[Prev in Thread] Current Thread [Next in Thread]