[Fusionforge-commits] FusionForge branch Branch_5_3 updated. 4515115b5c08987294566d229ceec35d0627e5cc

Franck VILLAUME nerville at fusionforge.org
Fri Feb 7 16:19:44 CET 2014


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, Branch_5_3 has been updated
       via  4515115b5c08987294566d229ceec35d0627e5cc (commit)
       via  5f034a97ef2dd7ba99559a312232467543730f3e (commit)
      from  4f9bea75dddf0bd10cfd178694e1e487562907a8 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 4515115b5c08987294566d229ceec35d0627e5cc
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Fri Feb 7 16:10:17 2014 +0100

    project admin: add entry in history when role is added/updated/deleted

diff --git a/src/www/project/admin/roledelete.php b/src/www/project/admin/roledelete.php
index bf262bb..3b2a322 100644
--- a/src/www/project/admin/roledelete.php
+++ b/src/www/project/admin/roledelete.php
@@ -4,6 +4,7 @@
  *
  * Copyright 2010 (c) Alcatel-Lucent
  * Copyright 2011, Roland Mas
+ * Copyright 2014, Franck Villaume - TrivialDev
  *
  * @author Alain Peyrat
  * @date 2010-05-18
@@ -58,10 +59,12 @@ if ($role->getHomeProject()->getID() != $group_id) {
 
 if (getStringFromRequest('submit')) {
 	if (getIntFromRequest('sure')) {
+		$role_name = $role->getName();
 		if (!$role->delete()) {
 			$error_msg = _('Error')._(': ').$role->getErrorMessage();
 		} else {
 			$feedback = _('Successfully Deleted Role');
+			$group->addHistory(_('Deleted Role'), $role_name);
 			session_redirect('/project/admin/users.php?group_id='.$group_id.'&feedback='.urlencode($feedback));
 		}
 	} else {
diff --git a/src/www/project/admin/roleedit.php b/src/www/project/admin/roleedit.php
index 8384b16..4c9ecab 100644
--- a/src/www/project/admin/roleedit.php
+++ b/src/www/project/admin/roleedit.php
@@ -8,6 +8,7 @@
  * Copyright © 2011
  *	Thorsten Glaser <t.glaser at tarent.de>
  * Copyright 2014, Stéphane-Eymeric Bredthauer
+ * Copyright 2014, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge. FusionForge is free software;
  * you can redistribute it and/or modify it under the terms of the
@@ -92,6 +93,7 @@ if (getStringFromRequest('submit')) {
 				$error_msg .= $role->getErrorMessage();
 			} else {
 				$feedback = _('Successfully Created New Role');
+				$group->addHistory(_('Added Role'), $role_name);
 			}
 		} else {
 			if ($role instanceof RoleExplicit) {
@@ -101,6 +103,7 @@ if (getStringFromRequest('submit')) {
 				$error_msg .= $role->getErrorMessage();
 			} else {
 				$feedback = _('Successfully Updated Role');
+				$group->addHistory(_('Updated Role'), $role_name);
 			}
 		}
 	}

commit 5f034a97ef2dd7ba99559a312232467543730f3e
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Fri Feb 7 16:09:24 2014 +0100

    Group: more translations

diff --git a/src/common/include/Group.class.php b/src/common/include/Group.class.php
index 5f72aa9..ac51787 100644
--- a/src/common/include/Group.class.php
+++ b/src/common/include/Group.class.php
@@ -2034,7 +2034,7 @@ class Group extends Error {
 		//
 		//	audit trail
 		//
-		$this->addHistory('Added User',$user_identifier);
+		$this->addHistory(_('Added User'),$user_identifier);
 		db_commit();
 		return true;
 	}
@@ -2145,7 +2145,7 @@ class Group extends Error {
 		plugin_hook ("group_removeuser", $hook_params);
 
 		//audit trail
-		$this->addHistory('Removed User',$user_id);
+		$this->addHistory(_('Removed User'),$user_id);
 
 		db_commit();
 		return true;
@@ -2194,7 +2194,7 @@ class Group extends Error {
 		$found_role->removeUser ($user);
 		$newrole->addUser ($user);
 
-		$this->addHistory('Updated User',$user_id);
+		$this->addHistory(_('Updated User'),$user_id);
 		return true;
 	}
 

-----------------------------------------------------------------------

Summary of changes:
 src/common/include/Group.class.php   |    6 +++---
 src/www/project/admin/roledelete.php |    3 +++
 src/www/project/admin/roleedit.php   |    3 +++
 3 files changed, 9 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list