Table editor fills the new entry form with the default values of the fields
[platal.git] / modules / xnet.php
index 2b6e9b4..f3cf0f9 100644 (file)
@@ -32,9 +32,16 @@ class XnetModule extends PLModule
             'groups'    => $this->make_hook('groups',    AUTH_PUBLIC),
             'groupes.php' => $this->make_hook('groups2', AUTH_PUBLIC),
             'plan'      => $this->make_hook('plan',      AUTH_PUBLIC),
+            'send_bug'  => $this->make_hook('bug',       AUTH_MDP),
         );
     }
 
+    function handler_bug(&$page)
+    {
+        $this->handler_index(&$page);
+        $page->assign('bug', 1);
+    }
+    
     function handler_index(&$page)
     {
         $page->nomenu = true;
@@ -43,7 +50,10 @@ class XnetModule extends PLModule
 
     function handler_login(&$page)
     {
-        pl_redirect('');
+        $allkeys = func_get_args();
+        unset($allkeys[0]);
+        $url = join('/',$allkeys);
+        pl_redirect($url);
     }
 
     function handler_exit(&$page)
@@ -166,12 +176,12 @@ class XnetModule extends PLModule
         $page->assign('doms', $doms);
 
         if (empty($doms)) {
-            $res = XDB::query("SELECT diminutif, nom FROM groupex.asso
+            $res = XDB::query("SELECT diminutif, nom, site FROM groupex.asso
                                    WHERE FIND_IN_SET({?}, cat)
                                 ORDER BY nom", $cat);
             $page->assign('gps', $res->fetchAllAssoc());
         } elseif (!is_null($dom)) {
-            $res = XDB::query("SELECT diminutif, nom FROM groupex.asso
+            $res = XDB::query("SELECT diminutif, nom, site FROM groupex.asso
                                 WHERE FIND_IN_SET({?}, cat) AND dom={?}
                              ORDER BY nom", $cat, $dom);
             $page->assign('gps', $res->fetchAllAssoc());