Example #1
0
<?php

if (!defined('BASEPATH')) {
    exit('No direct script access allowed');
}
/*
	dhtmlxScheduler, without Model
*/
require_once "./dhtmlx/connector/scheduler_connector.php";
require_once "./dhtmlx/connector/db_phpci.php";
DataProcessor::$action_param = "dhx_editor_status";
class Scheduler extends CI_Controller
{
    public function beforeRender($action)
    {
        //formatting data before output
        if ($action->get_id() == 10) {
            $action->set_userdata("color", "pink");
        }
        //mark event
    }
    public function beforeProcessing($action)
    {
        //validation before saving
        if ($action->get_value("event_name") == "") {
            $action->invalid();
            $action->set_response_attribute("details", "Empty data not allowed");
        }
    }
    public function index()
    {