[Fusionforge-commits] r15570 - in branches/Branch_5_1: . src/common/forum src/common/pm src/common/tracker src/www/pm/admin src/www/tracker/admin

Roland Mas lolando at fusionforge.org
Thu May 24 14:16:34 CEST 2012


Author: lolando
Date: 2012-05-24 14:16:33 +0200 (Thu, 24 May 2012)
New Revision: 15570

Modified:
   branches/Branch_5_1/
   branches/Branch_5_1/src/common/forum/Forum.class.php
   branches/Branch_5_1/src/common/pm/ProjectGroup.class.php
   branches/Branch_5_1/src/common/tracker/ArtifactType.class.php
   branches/Branch_5_1/src/www/pm/admin/index.php
   branches/Branch_5_1/src/www/tracker/admin/ind.php
Log:
Normalize roles on forum/subproject/tracker creation in the API rather than in the web interface

Modified: branches/Branch_5_1/src/common/forum/Forum.class.php
===================================================================
--- branches/Branch_5_1/src/common/forum/Forum.class.php	2012-05-24 11:54:08 UTC (rev 15569)
+++ branches/Branch_5_1/src/common/forum/Forum.class.php	2012-05-24 12:16:33 UTC (rev 15570)
@@ -225,6 +225,7 @@
 				return false;
 			}
 		}
+		$this->Group->normalizeAllRoles () ;
 		db_commit();
 		return true;
 	}

Modified: branches/Branch_5_1/src/common/pm/ProjectGroup.class.php
===================================================================
--- branches/Branch_5_1/src/common/pm/ProjectGroup.class.php	2012-05-24 11:54:08 UTC (rev 15569)
+++ branches/Branch_5_1/src/common/pm/ProjectGroup.class.php	2012-05-24 12:16:33 UTC (rev 15570)
@@ -174,6 +174,7 @@
 		}
 		$this->group_project_id=db_insertid($result,'project_group_list','group_project_id');
 		$this->fetchData($this->group_project_id);
+		$this->Group->normalizeAllRoles () ;
 
 		db_commit();
 

Modified: branches/Branch_5_1/src/common/tracker/ArtifactType.class.php
===================================================================
--- branches/Branch_5_1/src/common/tracker/ArtifactType.class.php	2012-05-24 11:54:08 UTC (rev 15569)
+++ branches/Branch_5_1/src/common/tracker/ArtifactType.class.php	2012-05-24 12:16:33 UTC (rev 15570)
@@ -260,11 +260,12 @@
 				db_rollback();
 				return false;
 			} else {
+				$this->Group->normalizeAllRoles ();
 				db_commit();
 				return $id;
+			}
 		}
 	}
-	}
 
 	/**
 	 *  fetchData - re-fetch the data for this ArtifactType from the database.

Modified: branches/Branch_5_1/src/www/pm/admin/index.php
===================================================================
--- branches/Branch_5_1/src/www/pm/admin/index.php	2012-05-24 11:54:08 UTC (rev 15569)
+++ branches/Branch_5_1/src/www/pm/admin/index.php	2012-05-24 12:16:33 UTC (rev 15570)
@@ -79,7 +79,6 @@
 		} else {
 			$feedback .= _('Subproject Inserted');
 			$warning_msg .= _("Please configure also the roles (by default, it's 'No Access')");
-			$g->normalizeAllRoles () ;
 		}
 
 	} else if ($add_cat) {

Modified: branches/Branch_5_1/src/www/tracker/admin/ind.php
===================================================================
--- branches/Branch_5_1/src/www/tracker/admin/ind.php	2012-05-24 11:54:08 UTC (rev 15569)
+++ branches/Branch_5_1/src/www/tracker/admin/ind.php	2012-05-24 12:16:33 UTC (rev 15570)
@@ -49,7 +49,6 @@
             $feedback .= '<br/>';
 			$feedback .= _('Please configure also the roles (by default, it\'s \'No Access\')');
 		}
-		$group->normalizeAllRoles () ;
 	}
 }
 




More information about the Fusionforge-commits mailing list