本文整理汇总了PHP中Dashboard::findAll方法的典型用法代码示例。如果您正苦于以下问题:PHP Dashboard::findAll方法的具体用法?PHP Dashboard::findAll怎么用?PHP Dashboard::findAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Dashboard
的用法示例。
在下文中一共展示了Dashboard::findAll方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: deselectAll
<th>Name</th>
<th>Description</th>
<th>Group</th>
<th>Columns</th>
<th>Background Color</th>
<th>Action</th>
<th class="last"><input type="submit" class="btn btn-default" value="Export selected" onclick="$('#form_mass_export').submit();
deselectAll();
return false;" /></th>
</tr>
</thead>
<tbody>
<?php
$first = TRUE;
if ($filter_group_id == -1) {
$dashboards = Dashboard::findAll();
} else {
$dashboards = Dashboard::findAllByFilter($filter_group_id);
}
/* Filter Graphs */
foreach ($dashboards as $dashboard) {
$dashboard_id = $dashboard->getDashboardId();
$graphs = Graph::findAll($dashboard_id);
$number_of_lines = 0;
foreach ($graphs as $graph) {
$number_of_lines = $number_of_lines + Line::countAllByFilter($graph->getGraphId(), $filter_text);
}
$number_of_graphs = Graph::countAllByFilter($dashboard_id, $filter_text);
?>
<?php
if ($number_of_graphs > 0 || $number_of_lines > 0 || preg_match('/' . $filter_text . '/i', $dashboard->getName()) || preg_match('/' . $filter_text . '/i', $dashboard->getDescription())) {
示例2: echo
<div id="form_clone_into_<?php
echo (int) $graph->getGraphId();
?>
" style="display:none;">
<form id="" method="post" action="<?php
echo Graph::makeURL('clone_into', $graph);
?>
" class="inline no-margin">
<input type="hidden" name="token" value="<?php
echo fRequest::generateCSRFToken("/graphs.php");
?>
" />
Select destination :
<select name="dashboard_dest_id">
<?php
foreach (Dashboard::findAll() as $dashboard_dest) {
if ($dashboard_dest->prepareDashboardId() != $graph->prepareDashboardId()) {
?>
<option value="<?php
echo (int) $dashboard_dest->getDashboardId();
?>
"><?php
echo $dashboard_dest->prepareName();
?>
</option>
<?php
}
}
?>
</select>
<input type="submit" value="Clone !" class="btn btn-primary"/>