src/Easy/EasyForm.php
public function deleteRecord($id = null)
    {
        if ($id == null || $id == '')
            $id = Openbizx::$app->getClientProxy()->getFormInputs('_selectedId');

        $selIds = Openbizx::$app->getClientProxy()->getFormInputs('row_selections', false);
        if ($selIds == null)
            $selIds[] = $id;
        foreach ($selIds as $id) {
            $dataRec = $this->getDataObj()->fetchById($id);
            $this->getDataObj()->setActiveRecord($dataRec);

            if (!$this->canDeleteRecord($dataRec)) {
                $this->errorMessage = $this->getMessage("FORM_OPERATION_NOT_PERMITTED", $this->objectName);
                if (strtoupper($this->formType) == "LIST") {
                    Openbizx::$app->getLog()->log(LOG_ERR, "DATAOBJ", "DataObj error = " . $errorMsg);
                    Openbizx::$app->getClientProxy()->showClientAlert($this->errorMessage);
                } else {
                    $this->processFormObjError(array($this->errorMessage));
                }
                return;
            }

            // take care of exception
            try {
                $dataRec->delete();
            } catch (Openbizx\Data\Exception $e) {
                // call $this->processDataException($e);
                $this->processDataException($e);
                return;
            }
        }
        if (strtoupper($this->formType) == "LIST")
            $this->rerender();

        $this->runEventLog();
        $this->processPostAction();
    }
public function deleteRecord($id = null)
    {
        if ($id == null || $id == '')
            $id = Openbizx::$app->getClientProxy()->getFormInputs('_selectedId');

        $selIds = Openbizx::$app->getClientProxy()->getFormInputs('row_selections', false);
        if ($selIds == null)
            $selIds[] = $id;
        foreach ($selIds as $id) {
            $dataRec = $this->getDataObj()->fetchById($id);
            $this->getDataObj()->setActiveRecord($dataRec);

            if (!$this->canDeleteRecord($dataRec)) {
                $this->errorMessage = $this->getMessage("FORM_OPERATION_NOT_PERMITTED", $this->objectName);
                if (strtoupper($this->formType) == "LIST") {
                    Openbizx::$app->getLog()->log(LOG_ERR, "DATAOBJ", "DataObj error = " . $errorMsg);
                    Openbizx::$app->getClientProxy()->showClientAlert($this->errorMessage);
                } else {
                    $this->processFormObjError(array($this->errorMessage));
                }
                return;
            }

            // take care of exception
            try {
                $dataRec->delete();
            } catch (Openbizx\Data\Exception $e) {
                // call $this->processDataException($e);
                $this->processDataException($e);
                return;
            }
        }
        if (strtoupper($this->formType) == "LIST")
            $this->rerender();

        $this->runEventLog();
        $this->processPostAction();
    }
Delete Record
NOTE: use redirectpage attr of eventhandler to redirect or redirect to previous page by default

@param string $id
@return void