/** * BizForm::SetSessionContext() - Save Session data of this object * * @param SessionContext $sessCtxt * @return void */ public function setSessionVars($sessCtxt) { parent::setSessionVars($sessCtxt); $sessCtxt->setObjVar($this->m_Name, "PrtFormCtrlName", $this->m_PrtFormCtrlName); }
/** * DeleteRecord() - allow delete only if no child node * @return avoid */ public function deleteRecord() { $rec = $this->getActiveRecord(); if (!$rec) { return; } $id = $rec['Id']; $recordList = $this->getDataObj()->directFetch("[PId]='{$id}'"); if (count($recordList) > 0) { global $g_BizSystem; $errorMsg = "Unable to delete the record that has 1 or more children nodes."; BizSystem::clientProxy()->showErrorMessage($errorMsg); return; } return parent::deleteRecord(); }