fhiiqm/inc/func_lib.inc.php
changeset 15 1ed6fbdf4237
parent 14 32203b8f40ee
child 19 33ee23fafd4d
--- a/fhiiqm/inc/func_lib.inc.php	Fri Oct 07 11:37:29 2011 +0200
+++ b/fhiiqm/inc/func_lib.inc.php	Tue Oct 11 12:17:55 2011 +0200
@@ -155,8 +155,23 @@
                         {
                             $_SESSION["recht"] = null;
 //                            echo "error_recht: " . $dbc->error . "<br />";
-                        }    
+                        }
 //                        print_r($arecht);
+
+                        // Recht Produkt-Gruppe
+                        $sql = "SELECT prod_group_ID FROM user_prodgroup WHERE userid = '$userid'";   
+                        if ($re = $dbc -> queryObjectArray($sql))
+                        {
+                            $pgrecht = array();
+                            foreach ($re as $row)
+                            {    $pgrecht[] = $row->prod_group_ID;}
+                            if (count($pgrecht)>0)
+                                $_SESSION["prodg"] = $pgrecht;
+                            else 
+                                $_SESSION["prodg"] = null;
+                        }
+                        else 
+                            $_SESSION["prodg"] = null;
                 		header("Location: $target");
                 		exit;
                     }