本文整理汇总了PHP中app::getFilterMenuStatusItemsByTable方法的典型用法代码示例。如果您正苦于以下问题:PHP app::getFilterMenuStatusItemsByTable方法的具体用法?PHP app::getFilterMenuStatusItemsByTable怎么用?PHP app::getFilterMenuStatusItemsByTable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类app
的用法示例。
在下文中一共展示了app::getFilterMenuStatusItemsByTable方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: executeFilters
public function executeFilters(sfWebRequest $request)
{
$m = array();
$params = (int) $request->getParameter('projects_id') > 0 ? 'projects_id=' . $request->getParameter('projects_id') : false;
$m = app::getFilterMenuItemsByTable($m, 'TasksPriority', 'Priority', 'ganttChart/index', $params);
$m = app::getFilterMenuStatusItemsByTable($m, 'TasksStatus', 'Status', 'ganttChart/index', $params);
$m = app::getFilterMenuItemsByTable($m, 'TasksLabels', 'Label', 'ganttChart/index', $params);
$m = app::getFilterMenuItemsByTable($m, 'TasksTypes', 'Type', 'ganttChart/index', $params);
$m = app::getFilterMenuUsers($m, 'TasksAssignedTo', 'Assigned To', 'ganttChart/index', $params);
$m = app::getFilterMenuUsers($m, 'TasksCreatedBy', 'Created By', 'ganttChart/index', $params);
if (!$params) {
$m = app::getFilterProjects($m, 'ganttChart/index', $params, array(), $this->getUser());
$m = app::getFilterMenuStatusItemsByTable($m, 'ProjectsStatus', 'Project Status', 'ganttChart/index', $params);
$m = app::getFilterMenuItemsByTable($m, 'ProjectsTypes', 'Project Type', 'ganttChart/index', $params);
} else {
$m = app::getFilterMenuItemsByTable($m, 'TasksGroups', 'Group', 'ganttChart/index', $params);
$m = app::getFilterMenuItemsByTable($m, 'ProjectsPhases', 'Phase', 'ganttChart/index', $params);
$m = app::getFilterMenuItemsByTable($m, 'Versions', 'Version', 'ganttChart/index', $params);
}
$this->m = array(array('title' => __('Filters'), 'submenu' => $m));
}
示例2: link_to
$count++;
?>
<td>
<div class="filterPreviewBox">
<table>
<tr>
<td valign="top" style="padding-top: 2px;"><?php
echo link_to(image_tag('icons/close_gray.png'), 'timeReport/' . $action_name . '?remove_filter=' . $table . ($params ? '&' . $params : ''), array('title' => __('Remove Filter')));
?>
</td>
<td valign="top"><div id="filtersPreviewMenuBox">
<?php
switch ($table) {
case 'TasksStatus':
$m = app::getFilterMenuStatusItemsByTable(array(), $table, 'Status', 'timeReport/' . $action_name, $params, $filter_by[$table]);
break;
case 'TasksAssignedTo':
$m = app::getFilterMenuUsers(array(), $table, 'Assigned To', 'timeReport/' . $action_name, $params, $filter_by[$table]);
break;
case 'TasksCreatedBy':
$m = app::getFilterMenuUsers(array(), $table, 'Created By', 'timeReport/' . $action_name, $params, $filter_by[$table]);
break;
case 'Projects':
$m = app::getFilterProjects(array(), 'timeReport/' . $action_name, $params, $filter_by[$table], $sf_user);
break;
default:
$m = app::getFilterMenuItemsByTable(array(), $table, $title, 'timeReport/' . $action_name, $params, $filter_by[$table], $sf_user);
break;
}
echo renderYuiMenu('filtersMenu' . $table, $m);
示例3: switch
} else {
switch ($table) {
case 'DiscussionsStatus':
$m = app::getFilterMenuStatusItemsByTable(array(), $table, 'Status', 'discussions/index', $params, $filter_by[$table]);
break;
case 'DiscussionsAssignedTo':
$m = app::getFilterMenuUsers(array(), $table, 'Assigned To', 'discussions/index', $params, $filter_by[$table]);
break;
case 'DiscussionsCreatedBy':
$m = app::getFilterMenuUsers(array(), $table, 'Created By', 'discussions/index', $params, $filter_by[$table]);
break;
case 'Projects':
$m = app::getFilterProjects(array(), 'discussions/index', $params, $filter_by[$table], $sf_user);
break;
case 'ProjectsStatus':
$m = app::getFilterMenuStatusItemsByTable(array(), $table, 'Project Status', 'discussions/index', $params, $filter_by[$table]);
break;
default:
$m = app::getFilterMenuItemsByTable(array(), $table, $title, 'discussions/index', $params, $filter_by[$table], $sf_user);
break;
}
}
echo renderYuiMenu('filtersMenu' . $table, $m);
?>
</div></td>
<td valign="top" class="selectedFilterItems"><?php
echo strstr($table, 'extraField') ? $filter_by[$table] : app::getNameByTableId($table, $filter_by[$table]);
?>
</td>
</tr>
</table>