Author: jure
Date: Mon Mar 18 09:58:11 2013
New Revision: 1457691

URL: http://svn.apache.org/r1457691
Log:
#404, do not copy TRAC_ADMIN permission from global scope on product addition, 
patch t404_r1456016_revert_r1449636.diff applied (from Olemis)


Modified:
    
incubator/bloodhound/branches/bep_0003_multiproduct/bloodhound_multiproduct/multiproduct/api.py

Modified: 
incubator/bloodhound/branches/bep_0003_multiproduct/bloodhound_multiproduct/multiproduct/api.py
URL: 
http://svn.apache.org/viewvc/incubator/bloodhound/branches/bep_0003_multiproduct/bloodhound_multiproduct/multiproduct/api.py?rev=1457691&r1=1457690&r2=1457691&view=diff
==============================================================================
--- 
incubator/bloodhound/branches/bep_0003_multiproduct/bloodhound_multiproduct/multiproduct/api.py
 (original)
+++ 
incubator/bloodhound/branches/bep_0003_multiproduct/bloodhound_multiproduct/multiproduct/api.py
 Mon Mar 18 09:58:11 2013
@@ -322,15 +322,6 @@ class MultiProductSystem(Component):
                     (table[0], ','.join(cols), ','.join(['%s' for c in cols])),
                     rows)
 
-            # in addition copy global admin permissions (they are
-            # not part of the default permission table)
-            rows = db("""SELECT username FROM permission WHERE 
action='TRAC_ADMIN'
-                         AND product=''""")
-            rows = [(r[0], 'TRAC_ADMIN', product.prefix) for r in rows]
-            cols = ('username', 'action', 'product')
-            db.executemany("INSERT INTO permission (%s) VALUES (%s)" %
-                           (','.join(cols), ','.join(['%s' for c in cols])), 
rows)
-
     def resource_changed(self, resource, old_values, context):
         return
 


Reply via email to