fixing parent hook_admin_path() bugs for default_local_task pages #1119996
authorKris
Thu, 7 Apr 2011 19:32:23 +0000 (14:32 -0500)
committerEarl Miles
Thu, 21 Apr 2011 20:25:49 +0000 (13:25 -0700)
page_manager/page_manager.module

index 57b6ae2..a6e0d14 100644 (file)
@@ -171,8 +171,13 @@ function page_manager_admin_paths() {
           $path_parts[$key] = '*';
         }
       }
-      $path_parts = implode('/', $path_parts);
-      $items[$path_parts] = TRUE;
+      $path = implode('/', $path_parts);
+      array_pop($path_parts);
+      $parent_path = implode('/', $path_parts);
+      if ($page->menu['type'] == 'default tab') {
+        $items[$parent_path] = TRUE;
+      }
+      $items[$path] = TRUE;
     }
   }
   return $items;