/** * Gets the JSON representation of this object for use in AJAX calls. * @return string The JSON representation of this object. */ public function ToJSON() { $json = ""; $json .= "{ "; $json .= "\"ID\": " . $this->ID . ", "; $json .= "\"ParentObject\": " . $this->ParentObject->ToJSON(); $json .= " }"; return $json; }
/** * Gets the JSON representation of this object for use in AJAX calls. * @return string The JSON representation of this object. */ public function ToJSON() { $json = ""; $json .= "{ "; $json .= "\"ID\": " . $this->ID . ", "; // $json .= "\"Tenant\": " . $this->Tenant->ToJSON() . ", "; // $json .= "\"Module\": " . $this->Module->ToJSON() . ", "; $json .= "\"ParentObject\": " . ($this->ParentObject == null ? "null" : $this->ParentObject->ToJSON()) . ", "; $json .= "\"Name\": \"" . \JH\Utilities::JavaScriptEncode($this->Name, "\"") . "\""; $json .= " }"; return $json; }