本文整理汇总了PHP中Grid::ProcessMessages方法的典型用法代码示例。如果您正苦于以下问题:PHP Grid::ProcessMessages方法的具体用法?PHP Grid::ProcessMessages怎么用?PHP Grid::ProcessMessages使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Grid
的用法示例。
在下文中一共展示了Grid::ProcessMessages方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Render
public function Render(Renderer $renderer)
{
try {
$errorReporting = error_reporting(null);
GetApplication()->SetOperation(OPERATION_COMMIT_DELETE);
$this->grid->SetState(OPERATION_COMMIT_DELETE);
$this->grid->GetState()->SetUseGetToExtractPrimaryKeys(true);
$this->grid->ProcessMessages();
header('Content-Type: text/xml');
if ($this->grid->GetErrorMessage() != '') {
$xmlWriter = XMLWriterFactory::CreateXMLWriter();
$xmlWriter->StartDocument('1.0', 'UTF-8');
$xmlWriter->StartElement('response');
$xmlWriter->WriteElement('type', 'error');
$xmlWriter->WriteElement('error_message', $this->grid->GetErrorMessage());
$xmlWriter->EndElement('response');
echo $xmlWriter->GetResult();
} else {
$xmlWriter = XMLWriterFactory::CreateXMLWriter();
$xmlWriter->StartDocument('1.0', 'UTF-8');
$xmlWriter->StartElement('response');
$xmlWriter->WriteElement('type', 'OK');
$xmlWriter->EndElement('response');
echo $xmlWriter->GetResult();
}
error_reporting($errorReporting);
} catch (Exception $e) {
echo '<?xml version="1.0" encoding="UTF-8"?><response><type>error</type><error_message>' . htmlspecialchars($e->getMessage()) . '</error_message></response>';
}
}
示例2: DoProcessMessages
function DoProcessMessages()
{
if (GetOperation() != OPERATION_RSS) {
//if (isset($this->AdvancedSearchControl) && $this->OpenAdvancedSearchByDefault())
//if (!$this->AdvancedSearchControl->HasCondition())
// GetApplication()->SetOperation(OPERATION_ADVANCED_SEARCH);
$this->grid->SetState(GetOperation());
$advancedSearchApplied = false;
if (isset($this->AdvancedSearchControl)) {
$advancedSearchApplied = $this->AdvancedSearchControl->ProcessMessages();
}
$this->grid->ProcessMessages();
if (isset($this->pageNavigator)) {
$this->pageNavigator->ProcessMessages();
}
if ($advancedSearchApplied) {
$link = $this->CreateLinkBuilder();
header('Location: ' . $link->GetLink());
exit;
}
}
}
示例3: ProcessMessages
public function ProcessMessages()
{
GetApplication()->SetOperation(OPERATION_VIEW);
$this->grid->SetState(OPERATION_VIEW);
$this->grid->ProcessMessages();
}