public function data() { //data feed $this->load->database(); $connector = new SchedulerConnector($this->db, "PHPCI"); //$connector->filter ("item_nm = 'miembro'"); $connector->configure("events", "event_id", "start_date, end_date, event_name, id_trainer"); $connector->render(); }
<?php include '../../codebase/scheduler_connector.php'; $data = array(array("event_id" => 1, "start_date" => "2012-05-24 00:00", "end_date" => "2012-05-25 00:00", "event_name" => "creation time"), array("event_id" => 2, "start_date" => "2010-02-16", "end_date" => "2084-06-08", "event_name" => "second part")); $scheduler = new SchedulerConnector(); $scheduler->render_array($data, "event_id", "start_date,end_date,event_name");
public function __construct($res, $type = false, $item_type = false, $data_type = false, $render_type = false) { if (!$item_type) { $item_type = "JSONSchedulerDataItem"; } if (!$data_type) { $data_type = "SchedulerDataProcessor"; } if (!$render_type) { $render_type = "JSONRenderStrategy"; } parent::__construct($res, $type, $item_type, $data_type, $render_type); }
<?php require "connector/scheduler_connector.php"; $res = mysql_connect("46.101.32.81:3306", "root", "teameight"); mysql_select_db("eg_database"); $conn = new SchedulerConnector($res, "MySQL"); $conn->render_table("eg_calender_events", "eventID", "start_date,end_date,text");
<?php include '../../common/connector/scheduler_connector.php'; include '../../common/connector/crosslink_connector.php'; require_once '../../common/config.php'; $cross = new CrossOptionsConnector($res, $dbtype); $cross->dynamic_loading(true); $cross->options->render_table("user", "user_id", "user_id(value),username(label)"); $cross->link->render_table("event_user", "event_id", "user_id,event_id"); $fruitCross = new CrossOptionsConnector($res, $dbtype); $fruitCross->dynamic_loading(true); $fruitCross->options->render_table("fruit", "fruit_id", "fruit_id(value),fruit_name(label)"); $fruitCross->link->render_table("event_fruit", "event_id", "fruit_id,event_id"); $scheduler = new SchedulerConnector($res, $dbtype); $scheduler->set_options("user_id", $cross->options); $scheduler->set_options("fruit_id", $fruitCross->options); $scheduler->render_table("events_ms", "event_id", "start_date,end_date,event_name,details");
<?php require_once '../../common/connector/scheduler_connector.php'; include '../../common/config.php'; $scheduler = new SchedulerConnector($res, $dbtype); $scheduler->render_table("events_map", "event_id", "start_date,end_date,event_name,details,event_location,lat,lng");
<?php session_start(); require_once "../codebase/connector/scheduler_connector.php"; $res = mysql_connect("localhost", "root", ""); mysql_select_db("calendar"); // $conn = new SchedulerConnector($res); $details = new DataConnector($res); $details->configure("cus", "c_id", "c_id,c_fname"); $conn = new SchedulerConnector($res); $conn->mix("cus", $details, array("c_id" => "c_id")); // function my_update($data){ // $data->add_field("c_id",1); // $data->set_value("c_id","10"); // //will be included in update processing // } // $conn->event->attach("beforeUpdate","my_update"); $conn->enable_log("temp.log"); $c_id = $_SESSION["login"]; $type = $_GET['type']; $eid = $_GET['eid']; // $conn->render_table("bookevent","event_id","start_date,end_date,event_name"); function insert_session($action) { $action->add_field("cid", $_SESSION["login"]); $action->add_field("eid", $_GET["eid"]); } $conn->event->attach("beforeProcessing", "insert_session"); // $conn->event->attach("Select","select * from bookevent where c_id={c_id}"); // $conn->render_table("bookevent","event_id","start_date,end_date,event_name,cid"); // $conn->render_sql("select * from bookevent where c_id = ".$c_id." AND `start_date` >= '2015-07-08 00:00:00' AND `end_date` <= '2015-07-11 00:00:00' ","event_id","start_date,end_date,event_name,rec_type,event_pid,event_length,details,event_location,lat,lng");
<?php session_start(); require_once "../codebase/connector/scheduler_connector.php"; $res = mysql_connect("localhost", "root", ""); mysql_select_db("calendar"); // $conn = new SchedulerConnector($res); $details = new DataConnector($res); $details->configure("cus", "c_id", "c_id,c_fname"); $conn = new SchedulerConnector($res); $conn->mix("cus", $details, array("c_id" => "c_id")); // function my_update($data){ // $data->add_field("c_id",1); // $data->set_value("c_id","10"); // //will be included in update processing // } // $conn->event->attach("beforeUpdate","my_update"); $conn->enable_log("temp.log"); $c_id = $_SESSION["login"]; $type = $_GET['type']; // $conn->render_table("events","event_id","start_date,end_date,event_name"); // function insert_session($action){ // $action->add_field("c_id", $_SESSION["login"]); // } // $conn->event->attach("beforeProcessing", "insert_session"); // $conn->event->attach("Select","select * from events where c_id={c_id}"); // $conn->render_table("events","event_id","start_date,end_date,event_name,rec_type,event_pid,event_length,details,event_location,lat,lng"); // $conn->render_sql("select * from events where c_id = ".$c_id." AND `start_date` >= '2015-07-08 00:00:00' AND `end_date` <= '2015-07-11 00:00:00' ","event_id","start_date,end_date,event_name,rec_type,event_pid,event_length,details,event_location,lat,lng"); if ($type == 1) { // $conn->render_sql("select * from events where c_id = ".$c_id." AND `start_date` >= '2015-07-08 00:00:00' AND `end_date` <= '2015-07-11 00:00:00' ","event_id","start_date,end_date,event_name,rec_type,event_pid,event_length,details,event_location,lat,lng"); } else {