} if ($readevalues == false) { // do event $retval = true; if ($eventObj->exists("BeforeEdit")) { $retval = $eventObj->BeforeEdit($evalues, $strWhereClause, $dataold, $keys, $usermessage, (bool) $inlineedit, $pageObject); } if ($retval && $pageObject->isCaptchaOk) { if ($inlineedit != EDIT_INLINE) { $_SESSION[$strTableName . "_count_captcha"] = $_SESSION[$strTableName . "_count_captcha"] + 1; } //set updated lat-lng values for all map fileds with 'UpdateLatLng' ticked if (isTableGeoUpdatable($pageObject->cipherer->pSet)) { setUpdatedLatLng($evalues, $pageObject->cipherer->pSet, $dataold); } if (DoUpdateRecord($strOriginalTableName, $evalues, $blobfields, $strWhereClause, $id, $pageObject, $pageObject->cipherer)) { $IsSaved = true; // Give possibility to all edit controls to clean their data // processing nama - begin $condition = 1; if ($condition) { $control_nama->afterSuccessfulSave(); } // processing nama - end // processing app_id - begin $condition = 1; if ($condition) { $control_app_id->afterSuccessfulSave(); } // processing app_id - end // processing kode - begin
/** * Process user data input and save it to the database table */ public function processDataInput() { // get prepared for the data saving $this->oldKeys = $this->keys; $this->buildNewRecordData(); if (!$this->recheckUserPermissions()) { // prevent the page from reading database values $this->oldRecordData = $this->newRecordData; $this->cachedRecord = $this->newRecordData; return false; } if (!$this->checkCaptcha()) { return false; } if (!$this->isRecordEditable(true)) { return $this->SecurityRedirect(); } if (!$this->callBeforeEditEvent()) { return false; } $this->addGeoValues(); if (!$this->checkDeniedDuplicatedValues()) { return false; } if (!$this->confirmLockingBeforeSaving()) { return false; } // do save the record if ($this->callCustomEditEvent()) { $this->updatedSuccessfully = DoUpdateRecord($this); } $this->unlockNewRecord(); if (!$this->updatedSuccessfully) { $this->setKeys($this->oldKeys); return false; } // after save steps $this->ProcessFiles(); $this->setMessage("<<< " . "Record updated" . ">>>"); $this->messageType = MESSAGE_INFO; $this->callAfterSuccessfulSave(); $this->unlockOldRecord(); $this->mergeNewRecordData(); $this->callAfterEditEvent(); $this->auditLogEdit(); $this->setKeys($this->keys); return true; }