public function render() { $this->event->trigger("onInit", $this); EventMaster::trigger_static("connectorInit", $this); if (!$this->as_string) { $this->parse_request(); } $this->set_relation(); if ($this->live_update !== false && $this->updating !== false) { $this->live_update->get_updates(); } else { if ($this->editing) { $dp = new $this->names["data_class"]($this, $this->config, $this->request); $dp->process($this->config, $this->request); } else { if (!$this->access->check("read")) { LogMaster::log("Access control: read operation blocked"); echo "Access denied"; die; } $wrap = new SortInterface($this->request); $this->apply_sorts($wrap); $this->event->trigger("beforeSort", $wrap); $wrap->store(); $wrap = new FilterInterface($this->request); $this->apply_filters($wrap); $this->event->trigger("beforeFilter", $wrap); $wrap->store(); if ($this->model && method_exists($this->model, "get")) { $this->sql = new ArrayDBDataWrapper(); $result = new ArrayQueryWrapper(call_user_func(array($this->model, "get"), $this->request)); $out = $this->output_as_xml($result); } else { $out = $this->output_as_xml($this->get_resource()); if ($out !== null) { return $out; } } } } $this->end_run(); }
public function render() { EventMaster::trigger_static("connectorInit", $this); $this->parse_request(); if ($this->live_update !== false && $this->updating !== false) { $this->live_update->get_updates(); } else { if ($this->editing) { $dp = new $this->names["data_class"]($this, $this->config, $this->request); $dp->process($this->config, $this->request); } else { $wrap = new SortInterface($this->request); $this->event->trigger("beforeSort", $wrap); $wrap->store(); $wrap = new FilterInterface($this->request); $this->event->trigger("beforeFilter", $wrap); $wrap->store(); $this->output_as_xml($this->sql->select($this->request)); } } $this->end_run(); }
public function render() { $this->event->trigger("onInit", $this); EventMaster::trigger_static("connectorInit", $this); $this->parse_request(); if ($this->live_update !== false && $this->updating !== false) { $this->live_update->get_updates(); } else { if ($this->editing) { $dp = new $this->names["data_class"]($this, $this->config, $this->request); $dp->process($this->config, $this->request); } else { if (!$this->access->check("read")) { LogMaster::log("Access control: read operation blocked"); echo "Access denied"; die; } $wrap = new SortInterface($this->request); $this->event->trigger("beforeSort", $wrap); $wrap->store(); $wrap = new FilterInterface($this->request); $this->event->trigger("beforeFilter", $wrap); $wrap->store(); $this->output_as_xml($this->sql->select($this->request)); } } $this->end_run(); }