Author: danydb
Date: 2012-09-17 20:28:04 +0200 (Mon, 17 Sep 2012)
New Revision: 5108
Modified:
phpcompta/tags/rel650/include/profile.inc.php
Log:
When adding a menu it cannot depend on itself
Modified: phpcompta/tags/rel650/include/profile.inc.php
===================================================================
--- phpcompta/tags/rel650/include/profile.inc.php 2012-09-16 16:53:59 UTC
(rev 5107)
+++ phpcompta/tags/rel650/include/profile.inc.php 2012-09-17 18:28:04 UTC
(rev 5108)
@@ -276,6 +276,13 @@
if ($inf > 0)
throw new Exception("Boucle infinie");
/**
+ * Check if we don't add a menu depending on itself
+ */
+ if ( $me_code == $me_code_dep )
+ throw new Exception("Un menu ne peut pas dépendre de
lui-même");
+
+
+ /**
* if me_code_dep == -1, it means it is null
*/
$me_code_dep = ($me_code_dep == -1) ? null : $me_code_dep;
---
PhpCompta est un logiciel de comptabilité libre en ligne (full web)
Projet opensource http://www.phpcompta.eu
_______________________________________________
Phpcompta est un logiciel libre de comptabilité en ligne
(http://www.phpcompta.eu)
Phpcompta-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/phpcompta-dev