当前位置: 首页>>代码示例>>PHP>>正文


PHP DataGrid::writeDataGrid方法代码示例

本文整理汇总了PHP中DataGrid::writeDataGrid方法的典型用法代码示例。如果您正苦于以下问题:PHP DataGrid::writeDataGrid方法的具体用法?PHP DataGrid::writeDataGrid怎么用?PHP DataGrid::writeDataGrid使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DataGrid的用法示例。


在下文中一共展示了DataGrid::writeDataGrid方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getCategorySelectArray

$categoryLabel = $widgets->createLabel("categoryId", getBadgerTranslation2('accountTransaction', 'category'), false, "");
$categoryField = $widgets->createSelectField("categoryId", getCategorySelectArray(true), "", "", false, "style='width: 210px;'");
//$btnFilterOkay = $widgets->createButton("btnFilterOkay", getBadgerTranslation2('dataGrid', 'setFilter'), "dataGridAccount$accountID.filter.setFilterFields(['title','amount','valutaDate','categoryId'])", "Widgets/dataGrid/filter.gif");
$btnFilterOkay = $widgets->createButton("btnFilterOkay", getBadgerTranslation2('dataGrid', 'setFilter'), "submit", "Widgets/dataGrid/filter.gif");
$btnFilterReset = $widgets->createButton("btnFilterReset", getBadgerTranslation2('dataGrid', 'resetFilter'), "dataGridAccount{$accountID}.filter.resetFilterFields(['title','amount','valutaDate','categoryId'])", "Widgets/cancel.gif");
$formAction = "javascript:dataGridAccount{$accountID}.filter.setFilterFields(['title','amount','valutaDate','categoryId'])";
eval('$filterContent = "' . $tpl->getTemplate('Account/StandardFilter') . '";');
$standardFilter = $widgets->addTwistieSection("Filter", $filterContent);
// DataGrid
$btnNewFinished = $widgets->createButton("btnNewFinished", getBadgerTranslation2('accountTransaction', 'newFinishedTrans'), "dataGridAccount{$accountID}.callNewEvent('type=finished')", "Account/finished_transaction_new.gif");
$btnNewPlanned = $widgets->createButton("btnNewPlanned", getBadgerTranslation2('accountTransaction', 'newPlannedTrans'), "dataGridAccount{$accountID}.callNewEvent('type=planned')", "Account/planned_transaction_new.gif");
$btnEdit = $widgets->createButton("btnEdit", getBadgerTranslation2('dataGrid', 'edit'), "dataGridAccount{$accountID}.callEditEvent()", "Widgets/table_edit.gif");
$btnDelete = $widgets->createButton("btnDelete", getBadgerTranslation2('dataGrid', 'delete'), "dataGridAccount{$accountID}.callDeleteEvent()", "Widgets/table_delete.gif");
$btnShowPlannedTransactions = $widgets->createButton("btnShowPlannedTransactions", getBadgerTranslation2('accountOverview', 'showPlannedTrans'), "location.href = location.href.replace(/AccountOverview\\.php/, 'AccountOverviewPlanned.php');", "Account/planned_transaction.png");
$btnGotoToday = $widgets->createButton("btnGotoToday", getBadgerTranslation2('dataGrid', 'gotoToday'), "dataGridAccount{$accountID}.gotoToday()", "Widgets/dataGrid/goto.gif");
$dgHtml = $dataGrid->writeDataGrid();
$legend = getBadgerTranslation2('dataGrid', 'legend');
$finishedTransactionText = getBadgerTranslation2('Account', 'finishedTransaction');
$finishedTransactionImage = $widgets->addImage('Account/finished_transaction.png', 'title="' . $finishedTransactionText . '"');
$finishedTransferalSourceTransactionText = getBadgerTranslation2('Account', 'FinishedTransferalSourceTransaction');
$finishedTransferalSourceTransactionImage = $widgets->addImage('Account/finished_transferal_source_transaction.png', 'title="' . $finishedTransferalSourceTransactionText . '"');
$finishedTransferalTargetTransactionText = getBadgerTranslation2('Account', 'FinishedTransferalTargetTransaction');
$finishedTransferalTargetTransactionImage = $widgets->addImage('Account/finished_transferal_target_transaction.png', 'title="' . $finishedTransferalTargetTransactionText . '"');
$plannedTransactionText = getBadgerTranslation2('Account', 'plannedTransaction');
$plannedTransactionImage = $widgets->addImage('Account/planned_transaction.png', 'title="' . $plannedTransactionText . '"');
$plannedTransferalSourceTransactionText = getBadgerTranslation2('Account', 'PlannedTransferalSourceTransaction');
$plannedTransferalSourceTransactionImage = $widgets->addImage('Account/planned_transferal_source_transaction.png', 'title="' . $plannedTransferalSourceTransactionText . '"');
$plannedTransferalTargetTransactionText = getBadgerTranslation2('Account', 'PlannedTransferalTargetTransaction');
$plannedTransferalTargetTransactionImage = $widgets->addImage('Account/planned_transferal_target_transaction.png', 'title="' . $plannedTransferalTargetTransactionText . '"');
eval('echo "' . $tpl->getTemplate('Account/AccountOverview') . '";');
eval("echo \"" . $tpl->getTemplate("badgerFooter") . "\";");
开发者ID:BackupTheBerlios,项目名称:badger-svn,代码行数:31,代码来源:AccountOverview.php

示例2: WidgetEngine

$account = $am->getAccountById($accountID);
$pageTitle = getBadgerTranslation2('accountOverviewPlanned', 'pageTitle');
$pageTitle .= ": " . $account->getTitle();
$widgets = new WidgetEngine($tpl);
$dataGrid = new DataGrid($tpl, "Account" . $accountID . "planned");
$dataGrid->sourceXML = BADGER_ROOT . "/core/XML/getDataGridXML.php?q=Account&qp={$accountID};planned";
$dataGrid->headerName = array(getBadgerTranslation2('accountOverview', 'colTitle'), getBadgerTranslation2('accountOverviewPlanned', 'colBeginDate'), getBadgerTranslation2('accountOverviewPlanned', 'colEndDate'), getBadgerTranslation2('accountOverviewPlanned', 'colRepeatText'), getBadgerTranslation2('accountOverview', 'colAmount'), getBadgerTranslation2('accountOverview', 'colCategoryTitle'));
//$dataGrid->columnOrder = array("title","beginDate", "endDate", "repeatUnit", "repeatFrequency", "amount", "categoryTitle");
$dataGrid->columnOrder = array("title", "beginDate", "endDate", "repeatText", "amount", "categoryTitle");
$dataGrid->height = "350px";
//$dataGrid->headerSize = array(210, 95, 85, 70, 75, 120, 200);
$dataGrid->headerSize = array(210, 95, 85, 85, 120, 200);
//$dataGrid->cellAlign = array("left", "right", "right", "left", "right", "right", "left");
$dataGrid->cellAlign = array("left", "right", "right", "left", "right", "left");
$dataGrid->deleteAction = "Transaction.php?action=delete&backTo=planned&accountID={$accountID}&ID=";
$dataGrid->editAction = "Transaction.php?action=edit&backTo=planned&accountID={$accountID}&ID=";
$dataGrid->newAction = "Transaction.php?action=new&backTo=planned&accountID={$accountID}";
$dataGrid->initDataGridJS();
$widgets->addNavigationHead();
echo $tpl->getHeader($pageTitle);
echo "<h1>{$pageTitle}</h1>";
echo $widgets->createButton("btnNewPlanned", getBadgerTranslation2('accountTransaction', 'newPlannedTrans'), "dataGridAccount" . $accountID . "planned.callNewEvent('type=planned')", "Widgets/table_add.gif");
echo ' ';
echo $widgets->createButton("btnEdit", getBadgerTranslation2('dataGrid', 'edit'), "dataGridAccount" . $accountID . "planned.callEditEvent()", "Widgets/table_edit.gif");
echo ' ';
echo $widgets->createButton("btnDelete", getBadgerTranslation2('dataGrid', 'delete'), "dataGridAccount" . $accountID . "planned.callDeleteEvent()", "Widgets/table_delete.gif");
echo ' ';
echo $widgets->createButton("btnShowTransactions", getBadgerTranslation2('accountOverviewPlanned', 'showTrans'), "location.href = location.href.replace(/AccountOverviewPlanned\\.php/, 'AccountOverview.php');", "Account/finished_transaction.png");
echo $dataGrid->writeDataGrid();
eval("echo \"" . $tpl->getTemplate("badgerFooter") . "\";");
require_once BADGER_ROOT . "/includes/fileFooter.php";
开发者ID:BackupTheBerlios,项目名称:badger-svn,代码行数:31,代码来源:AccountOverviewPlanned.php

示例3: WidgetEngine

* Visit http://www.badger-finance.org 
*
**/
define("BADGER_ROOT", "..");
require_once BADGER_ROOT . "/includes/fileHeaderFrontEnd.inc.php";
require_once BADGER_ROOT . "/core/widgets/DataGrid.class.php";
require_once BADGER_ROOT . '/modules/account/AccountManager.class.php';
require_once BADGER_ROOT . '/modules/account/accountCommon.php';
updateBalances();
$widgets = new WidgetEngine($tpl);
$dataGrid = new DataGrid($tpl, "AccountManagerWelcomePage");
//$dataGrid->noRowSelectedMsg = "test";
$dataGrid->sourceXML = BADGER_ROOT . "/core/XML/getDataGridXML.php?q=AccountManager";
$dataGrid->headerName = array(getBadgerTranslation2('accountAccount', 'colTitle'), getBadgerTranslation2('accountAccount', 'colBalance'), getBadgerTranslation2('accountAccount', 'colCurrency'));
$dataGrid->columnOrder = array("title", "balance", "currency");
$dataGrid->headerSize = array(200, 150, 100);
$dataGrid->cellAlign = array("left", "right", "left");
$dataGrid->height = "180px";
$dataGrid->width = "520px";
$dataGrid->discardSelectedRows = "true";
$dataGrid->editAction = "account/AccountOverview.php?accountID=";
$dataGrid->initDataGridJS();
$widgets->addNavigationHead();
echo $tpl->getHeader("Badger");
$accountOverviewHeader = getBadgerTranslation2('welcome', 'pageTitle');
$accountOverviewGrid = $dataGrid->writeDataGrid();
$btnOpen = $widgets->createButton("btnNew", getBadgerTranslation2('dataGrid', 'open'), "dataGridAccountManagerWelcomePage.callEditEvent()", "Widgets/table_go.gif");
eval("echo \"" . $tpl->getTemplate("badgerOverview") . "\";");
/*echo $dataGridTest->writeDataGrid();*/
eval("echo \"" . $tpl->getTemplate("badgerFooter") . "\";");
require_once BADGER_ROOT . "/includes/fileFooter.php";
开发者ID:BackupTheBerlios,项目名称:badger-svn,代码行数:31,代码来源:welcome.php

示例4: showSelectPage

function showSelectPage()
{
    global $tpl;
    global $us;
    global $badgerDb;
    handleOldFinishedTransactions(new AccountManager($badgerDb));
    $widgets = new WidgetEngine($tpl);
    $widgets->addCalendarJS();
    $widgets->addToolTipJS();
    $tpl->addJavaScript("js/behaviour.js");
    $tpl->addJavaScript("js/prototype.js");
    $tpl->addJavaScript("js/statistics.js");
    $tpl->addHeaderTag('<script type="text/javascript">var badgerHelpChapter = "Statistiken";</script>');
    $dataGrid = new DataGrid($tpl);
    $dataGrid->sourceXML = BADGER_ROOT . "/core/XML/getDataGridXML.php?q=AccountManager";
    $dataGrid->headerName = array(getBadgerTranslation2('statistics', 'accColTitle'), getBadgerTranslation2('statistics', 'accColBalance'), getBadgerTranslation2('statistics', 'accColCurrency'));
    $dataGrid->columnOrder = array("title", "balance", 'currency');
    $dataGrid->initialSort = "title";
    $dataGrid->initialSortDirection = "asc";
    $dataGrid->headerSize = array(160, 100, 75);
    $dataGrid->cellAlign = array("left", 'right', 'left');
    $dataGrid->width = '30em';
    $dataGrid->height = '7em';
    $dataGrid->initDataGridJS();
    try {
        $preselectedAccounts = $us->getProperty('statisticsPreselectedAccounts');
        foreach ($preselectedAccounts as $currentPreselectedAccount) {
            $tpl->addOnLoadEvent("dgPreselectId('{$currentPreselectedAccount}');");
        }
    } catch (BadgerException $ex) {
    }
    $tpl->addOnLoadEvent("Behaviour.register(statisticsBehaviour);");
    $tpl->addOnLoadEvent("Behaviour.apply();");
    $widgets->addNavigationHead();
    $selectTitle = getBadgerTranslation2('statistics', 'pageTitle');
    echo $tpl->getHeader($selectTitle);
    $widgets->addToolTipLayer();
    $selectFormAction = BADGER_ROOT . '/modules/statistics/statistics.php';
    $graphTypeText = getBadgerTranslation2('statistics', 'type');
    $categoryTypeText = getBadgerTranslation2('statistics', 'category');
    $timeFrameText = getBadgerTranslation2('statistics', 'period');
    $summarizeCategoriesText = getBadgerTranslation2('statistics', 'catMerge');
    $accountsText = getBadgerTranslation2('statistics', 'accounts');
    $differentCurrencyWarningText = getBadgerTranslation2('statistics', 'attention');
    $fromText = getBadgerTranslation2('statistics', 'from');
    $toText = getBadgerTranslation2('statistics', 'to');
    $trendRadio = $widgets->createField('mode', null, 'trendPage', '', false, 'radio', 'checked="checked"');
    $trendLabel = $widgets->createLabel('mode', getBadgerTranslation2('statistics', 'trend'));
    $categoryRadio = $widgets->createField('mode', null, 'categoryPage', '', false, 'radio');
    $categoryLabel = $widgets->createLabel('mode', getBadgerTranslation2('statistics', 'categories'));
    $accountSelect = $dataGrid->writeDataGrid();
    $accountField = $widgets->createField('accounts', null, null, '', false, 'hidden');
    $monthArray = array('fullYear' => getBadgerTranslation2('statistics', 'fullYear'), '1' => getBadgerTranslation2('statistics', 'jan'), '2' => getBadgerTranslation2('statistics', 'feb'), '3' => getBadgerTranslation2('statistics', 'mar'), '4' => getBadgerTranslation2('statistics', 'apr'), '5' => getBadgerTranslation2('statistics', 'may'), '6' => getBadgerTranslation2('statistics', 'jun'), '7' => getBadgerTranslation2('statistics', 'jul'), '8' => getBadgerTranslation2('statistics', 'aug'), '9' => getBadgerTranslation2('statistics', 'sep'), '10' => getBadgerTranslation2('statistics', 'oct'), '11' => getBadgerTranslation2('statistics', 'nov'), '12' => getBadgerTranslation2('statistics', 'dec'));
    $monthSelect = $widgets->createSelectField('monthSelect', $monthArray, 'fullYear', '', false, 'onchange="updateDateRange();"');
    $now = new Date();
    $beginOfYear = new Date();
    $beginOfYear->setMonth(1);
    $beginOfYear->setDay(1);
    $yearInput = $widgets->createField('yearSelect', 4, $now->getYear(), '', false, 'text', 'onchange="updateDateRange();"');
    $startDateField = $widgets->addDateField("startDate", $beginOfYear->getFormatted());
    $endDateField = $widgets->addDateField("endDate", $now->getFormatted());
    $inputRadio = $widgets->createField('type', null, 'i', '', false, 'radio', 'checked="checked"');
    $inputLabel = $widgets->createLabel('type', getBadgerTranslation2('statistics', 'income'));
    $outputRadio = $widgets->createField('type', null, 'o', '', false, 'radio');
    $outputLabel = $widgets->createLabel('type', getBadgerTranslation2('statistics', 'expenses'));
    $summarizeRadio = $widgets->createField('summarize', null, 't', '', false, 'radio', 'checked="checked"');
    $summarizeLabel = $widgets->createLabel('summarize', getBadgerTranslation2('statistics', 'subCat'));
    $distinguishRadio = $widgets->createField('summarize', null, 'f', '', false, 'radio');
    $distinguishLabel = $widgets->createLabel('summarize', getBadgerTranslation2('statistics', 'subCat2'));
    $dateFormatField = $widgets->createField('dateFormat', null, $us->getProperty('badgerDateFormat'), null, false, 'hidden');
    $errorMsgAccountMissingField = $widgets->createField('errorMsgAccountMissing', null, getBadgerTranslation2('statistics', 'errorMissingAcc'), null, false, 'hidden');
    $errorMsgStartBeforeEndField = $widgets->createField('errorMsgStartBeforeEnd', null, getBadgerTranslation2('statistics', 'errorDate'), null, false, 'hidden');
    $errorMsgEndInFutureField = $widgets->createField('errorMsgEndInFuture', null, getBadgerTranslation2('statistics', 'errorEndDate'), null, false, 'hidden');
    $submitButton = $widgets->createButton('submit', getBadgerTranslation2('statistics', 'showButton'), 'submitSelect();', "Widgets/accept.gif");
    eval('echo "' . $tpl->getTemplate('statistics/select') . '";');
    eval('echo "' . $tpl->getTemplate('badgerFooter') . '";');
}
开发者ID:BackupTheBerlios,项目名称:badger-svn,代码行数:77,代码来源:statistics.php

示例5: getCategorySelectArray

$filters['transactionPartner'] = getBadgerTranslation2('statistics2', 'transactionPartnerFilter') . $widgets->createSelectField("transactionPartnerOperator{$FILTER_ID_MARKER}", $dataGridStringFilterArray, "", "", false, "style='width: 95px;'") . '&nbsp;' . $widgets->createField("transactionPartner{$FILTER_ID_MARKER}", 30, "", "", false, "text", "");
$filters['category'] = getBadgerTranslation2('statistics2', 'categoryFilter') . $widgets->createField("categoryOp{$FILTER_ID_MARKER}", null, 'eq', '', false, 'radio') . $widgets->createLabel("categoryOp{$FILTER_ID_MARKER}", getBadgerTranslation2('statistics2', 'categoryFilterIs')) . '&nbsp;' . $widgets->createField("categoryOp{$FILTER_ID_MARKER}", null, 'ne', '', false, 'radio') . $widgets->createLabel("categoryOp{$FILTER_ID_MARKER}", getBadgerTranslation2('statistics2', 'categoryFilterIsNot')) . '&nbsp;' . $widgets->createSelectField("categoryId{$FILTER_ID_MARKER}", getCategorySelectArray(true), "", "", false, "style='width: 210px;'");
$filters['exceptional'] = getBadgerTranslation2('statistics2', 'exceptionalFilter') . $widgets->createField("exceptional{$FILTER_ID_MARKER}", null, '1', '', false, 'radio') . $widgets->createLabel("exceptional{$FILTER_ID_MARKER}", getBadgerTranslation2('statistics2', 'exceptionalFilterExceptional')) . '&nbsp;' . $widgets->createField("exceptional{$FILTER_ID_MARKER}", null, '0', '', false, 'radio') . $widgets->createLabel("exceptional{$FILTER_ID_MARKER}", getBadgerTranslation2('statistics2', 'exceptionalFilterNotExceptional'));
$filters['periodical'] = getBadgerTranslation2('statistics2', 'periodicalFilter') . $widgets->createField("periodical{$FILTER_ID_MARKER}", null, '1', '', false, 'radio') . $widgets->createLabel("periodical{$FILTER_ID_MARKER}", getBadgerTranslation2('statistics2', 'periodicalFilterPeriodical')) . '&nbsp;' . $widgets->createField("periodical{$FILTER_ID_MARKER}", null, '0', '', false, 'radio') . $widgets->createLabel("periodical{$FILTER_ID_MARKER}", getBadgerTranslation2('statistics2', 'periodicalFilterNotPeriodical'));
$availableFilters = array('unselected' => getBadgerTranslation2('statistics2', 'availableFiltersUnselected'), 'title' => getBadgerTranslation2('statistics2', 'availableFiltersTitle'), 'description' => getBadgerTranslation2('statistics2', 'availableFiltersDescription'), 'valutaDate' => getBadgerTranslation2('statistics2', 'availableFiltersValutaDate'), 'valutaDateBetween' => getBadgerTranslation2('statistics2', 'availableFiltersValutaDateBetween'), 'valutaDateAgo' => getBadgerTranslation2('statistics2', 'availableFiltersValutaDateAgo'), 'amount' => getBadgerTranslation2('statistics2', 'availableFiltersAmount'), 'outsideCapital' => getBadgerTranslation2('statistics2', 'availableFiltersOutsideCapital'), 'transactionPartner' => getBadgerTranslation2('statistics2', 'availableFiltersTransactionPartner'), 'category' => getBadgerTranslation2('statistics2', 'availableFiltersCategory'), 'exceptional' => getBadgerTranslation2('statistics2', 'availableFiltersExceptional'), 'periodical' => getBadgerTranslation2('statistics2', 'availableFiltersPeriodical'), 'delete' => getBadgerTranslation2('statistics2', 'availableFiltersDelete'));
$dateFormat = $widgets->createField('dateFormat', null, $us->getProperty('badgerDateFormat'), null, false, 'hidden');
$content = "<div style=\"float: left;\">";
$content .= $widgets->createSelectField("filterSelect{$FILTER_ID_MARKER}", $availableFilters, "", "", false, "onchange=\"setFilterContent('{$FILTER_ID_MARKER}');\"");
$content .= "</div><div id=\"filterContent{$FILTER_ID_MARKER}\"></div>";
$filterLineEmpty = "<div id='filterLineEmpty' style='display:none;'>{$content}</div>";
$filtersEmpty = '';
foreach ($filters as $currentName => $currentFilter) {
    $filtersEmpty .= "<div id='{$currentName}Empty' style='display:none;'>{$currentFilter}</div>";
}
$dataGridAccounts = $dgAccounts->writeDataGrid();
$filterCaption = getBadgerTranslation2('statistics2', 'filterCaption');
$addFilterButton = $widgets->createButton('addFilter', getBadgerTranslation2('statistics2', 'addFilterButton'), 'addFilterLineX();');
eval('$filterBoxContent = "' . $tpl->getTemplate('statistics2/filterBox') . '";');
$filterBox = $widgets->addTwistieSection(getBadgerTranslation2('statistics2', 'twistieCaptionInput'), $filterBoxContent, null, true);
$ACTIVE_OS_MARKER = '__ACTIVE_OS__';
$outputSelectionTrend = '<div id="outputSelectionTrend" style="display: inline; vertical-align: top;">' . '<fieldset style="display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionTrendStartValue') . '</legend>' . '<p>' . $widgets->createField("outputSelectionTrendStart{$ACTIVE_OS_MARKER}", null, 'b', '', false, 'radio', 'checked="checked"') . $widgets->createLabel("outputSelectionTrendStart{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTrendStartValueBalance')) . '</p><p>' . $widgets->createField("outputSelectionTrendStart{$ACTIVE_OS_MARKER}", null, '0', '', false, 'radio') . $widgets->createLabel("outputSelectionTrendStart{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTrendStartValueZero')) . '</p>' . '</fieldset>' . '<fieldset style="display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionTrendTickLabels') . '</legend>' . '<p>' . $widgets->createField("outputSelectionTrendTicks{$ACTIVE_OS_MARKER}", null, 's', '', false, 'radio', 'checked="checked"') . $widgets->createLabel("outputSelectionTrendTicks{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTrendTickLabelsShow')) . '</p><p>' . $widgets->createField("outputSelectionTrendTicks{$ACTIVE_OS_MARKER}", null, 'h', '', false, 'radio') . $widgets->createLabel("outputSelectionTrendTicks{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTrendTickLabelsHide')) . '</p>' . '</fieldset>' . '</div>';
$outputSelectionCategory = '<div id="outputSelectionCategory">' . '<fieldset style="display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionCategoryType') . '</legend>' . '<p>' . $widgets->createField("outputSelectionCategoryType{$ACTIVE_OS_MARKER}", null, 'i', '', false, 'radio', 'checked="checked"') . $widgets->createLabel("outputSelectionCategoryType{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionCategoryTypeInput')) . '</p><p>' . $widgets->createField("outputSelectionCategoryType{$ACTIVE_OS_MARKER}", null, 'o', '', false, 'radio') . $widgets->createLabel("outputSelectionCategoryType{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionCategoryTypeOutput')) . '</p>' . '</fieldset>' . '<fieldset style="display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionCategorySubCategories') . '</legend>' . '<p>' . $widgets->createField("outputSelectionCategorySummarize{$ACTIVE_OS_MARKER}", null, 't', '', false, 'radio', 'checked="checked"') . $widgets->createLabel("outputSelectionCategorySummarize{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionCategorySubCategoriesSummarize')) . '</p><p>' . $widgets->createField("outputSelectionCategorySummarize{$ACTIVE_OS_MARKER}", null, 'f', '', false, 'radio') . $widgets->createLabel("outputSelectionCategorySummarize{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionCategorySubCategoriesNoSummarize')) . '</p>' . '</fieldset>' . '</div>';
$outputSelectionTimespan = '<div id="outputSelectionTimespan">' . '<fieldset style="display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionTimespanType') . '</legend>' . '<p>' . $widgets->createField("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", null, 'w', '', false, 'radio') . $widgets->createLabel("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTimespanTypeWeek')) . '</p><p>' . $widgets->createField("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", null, 'm', '', false, 'radio') . $widgets->createLabel("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTimespanTypeMonth')) . '</p><p>' . $widgets->createField("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", null, 'q', '', false, 'radio', 'checked="checked"') . $widgets->createLabel("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTimespanTypeQuarter')) . '</p><p>' . $widgets->createField("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", null, 'y', '', false, 'radio') . $widgets->createLabel("outputSelectionTimespanType{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionTimespanTypeYear')) . '</p>' . '</fieldset>' . '<fieldset style="display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionCategorySubCategories') . '</legend>' . '<p>' . $widgets->createField("outputSelectionTimespanSummarize{$ACTIVE_OS_MARKER}", null, 't', '', false, 'radio', 'checked="checked"') . $widgets->createLabel("outputSelectionTimespanSummarize{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionCategorySubCategoriesSummarize')) . '</p><p>' . $widgets->createField("outputSelectionTimespanSummarize{$ACTIVE_OS_MARKER}", null, 'f', '', false, 'radio') . $widgets->createLabel("outputSelectionTimespanSummarize{$ACTIVE_OS_MARKER}", getBadgerTranslation2('statistics2', 'outputSelectionCategorySubCategoriesNoSummarize')) . '</p>' . '</fieldset>' . '</div>';
$outputSelection = "<div id='outputSelections' style='display:none;'>\r\n\t{$outputSelectionTrend}\r\n\t{$outputSelectionCategory}\r\n\t{$outputSelectionTimespan}\r\n</div>";
$outputSelectionContent = '<fieldset style="width: 8em; display: inline; vertical-align: top;">' . '<legend>' . getBadgerTranslation2('statistics2', 'outputSelectionGraphType') . '</legend>' . '<p>' . $widgets->createField("outputSelectionType", null, 'Trend', '', false, 'radio', 'checked="checked" onchange="updateOutputSelection();" onclick="updateOutputSelection();"') . $widgets->createLabel("outputSelectionType", getBadgerTranslation2('statistics2', 'outputSelectionGraphTypeTrend')) . '</p><p>' . $widgets->createField("outputSelectionType", null, 'Category', '', false, 'radio', 'onchange="updateOutputSelection();" onclick="updateOutputSelection();"') . $widgets->createLabel("outputSelectionType", getBadgerTranslation2('statistics2', 'outputSelectionGraphTypeCategory')) . '</p><p>' . $widgets->createField("outputSelectionType", null, 'Timespan', '', false, 'radio', 'onchange="updateOutputSelection();" onclick="updateOutputSelection();"') . $widgets->createLabel("outputSelectionType", getBadgerTranslation2('statistics2', 'outputSelectionGraphTypeTimespan')) . '</p>' . '</fieldset>' . "<div id='outputSelectionContent' style='display: inline; vertical-align: top;'>" . str_replace($ACTIVE_OS_MARKER, '', $outputSelectionTrend) . '</div>';
$outputSelectionTwistie = $widgets->addTwistieSection(getBadgerTranslation2('statistics2', 'twistieCaptionOutputSelection'), $outputSelectionContent, null, true);
$analyzeButton = $widgets->createButton('applyFilter', getBadgerTranslation2('statistics2', 'analyzeButton'), 'applyFilterX();');
$graphTwistie = $widgets->addTwistieSection(getBadgerTranslation2('statistics2', 'twistieCaptionGraph'), '<div id="graphContent"></div>', null, true);
$outputTwistie = $widgets->addTwistieSection(getBadgerTranslation2('statistics2', 'twistieCaptionOutput'), '<div id="resultGridContainer" style="display:none;">' . $dgResult->writeDataGrid() . '</div>', null, true);
eval('echo "' . $tpl->getTemplate('statistics2/statistics2') . '";');
eval('echo "' . $tpl->getTemplate('badgerFooter') . '";');
开发者ID:BackupTheBerlios,项目名称:badger-svn,代码行数:31,代码来源:statistics2.php


注:本文中的DataGrid::writeDataGrid方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。