[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [7078] property: menuitem for each project category
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [7078] property: menuitem for each project category |
Date: |
Mon, 07 Mar 2011 15:21:23 +0000 |
Revision: 7078
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=7078
Author: sigurdne
Date: 2011-03-07 15:21:21 +0000 (Mon, 07 Mar 2011)
Log Message:
-----------
property: menuitem for each project category
Modified Paths:
--------------
trunk/property/inc/class.menu.inc.php
trunk/property/inc/class.uiproject.inc.php
Modified: trunk/property/inc/class.menu.inc.php
===================================================================
--- trunk/property/inc/class.menu.inc.php 2011-03-07 14:30:57 UTC (rev
7077)
+++ trunk/property/inc/class.menu.inc.php 2011-03-07 15:21:21 UTC (rev
7078)
@@ -653,6 +653,24 @@
if ( $acl->check('.project', PHPGW_ACL_READ,
'property') )
{
+
+ $cats = CreateObject('phpgwapi.categories',
-1, 'property', '.project');
+ $cats->supress_info = true;
+
+ $project_cats =
$cats->formatted_xslt_list(array('format'=>'filter','globals' => True));
+//_debug_array($project_cats);die();
+ $project_children = array();
+ foreach($project_cats['cat_list'] as $dummy =>
$project_cat)
+ {
+
$project_children[$project_cat['cat_id']] = array
+ (
+ 'url' =>
$GLOBALS['phpgw']->link('/index.php',array('menuaction'=>
'property.uiproject.index', 'cat_id' => $project_cat['cat_id'])),
+ 'text' =>
$project_cat['name'],
+ 'image' =>
array('property', 'project'),
+
+ );
+ }
+
$menus['navigation']['project'] = array
(
'url' =>
$GLOBALS['phpgw']->link('/index.php',array('menuaction'=>
'property.uiproject.index')),
@@ -664,7 +682,8 @@
(
'url' =>
$GLOBALS['phpgw']->link('/index.php',array('menuaction'=>
'property.uiproject.index')),
'text' =>
lang('Project'),
- 'image'
=> array('property', 'project')
+ 'image'
=> array('property', 'project'),
+ 'children'
=> $project_children
),
'workorder' => array
(
Modified: trunk/property/inc/class.uiproject.inc.php
===================================================================
--- trunk/property/inc/class.uiproject.inc.php 2011-03-07 14:30:57 UTC (rev
7077)
+++ trunk/property/inc/class.uiproject.inc.php 2011-03-07 15:21:21 UTC (rev
7078)
@@ -167,6 +167,11 @@
function index()
{
$GLOBALS['phpgw_info']['flags']['menu_selection'] .=
'::project';
+ if($this->cat_id)
+ {
+
$GLOBALS['phpgw_info']['flags']['menu_selection'] .= "::{$this->cat_id}";
+ }
+
if(!$this->acl_read)
{
$GLOBALS['phpgw']->redirect_link('/index.php',array('menuaction'=>
'property.uiproject.stop', 'perm'=>1,'acl_location'=> $this->acl_location));
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [7078] property: menuitem for each project category,
Sigurd Nes <=