public function renderButton($row) { $objControlId = "editButton" . $row; $objControl = $this->GetControl($objControlId); if (!$objControl) { $objControl = new QJqButton($this->dtgButtons, $objControlId); $objControl->Text = true; $objControl->AddAction(new QClickEvent(), new QAjaxAction("renderButton_Click")); } $objControl->Label = "update & alert " . $this->intHitCnt; // We pass the parameter of "false" to make sure the control doesn't render // itself RIGHT HERE - that it instead returns its string rendering result. return $objControl->Render(false); }
public function renderRemoveButton($item) { $objControlId = "removeButton" . $item->Id; $objControl = $this->GetControl($objControlId); if (!$objControl) { $objControl = new QJqButton($this->dtgOrders, $objControlId); $objControl->Text = true; $objControl->ActionParameter = $item->Id; $objControl->AddAction(new QClickEvent(), new QAjaxAction("removeButton_Click")); } $objControl->Label = "Remove"; // We pass the parameter of "false" to make sure the control doesn't render // itself RIGHT HERE - that it instead returns its string rendering result. return $objControl->Render(false); }