-
Notifications
You must be signed in to change notification settings - Fork 48
Expand file tree
/
Copy pathCalendar.php
More file actions
57 lines (45 loc) · 978 Bytes
/
Calendar.php
File metadata and controls
57 lines (45 loc) · 978 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Calendar extends CI_Controller {
function __construct()
{
// Call the Model constructor
parent::__construct();
$this->load->model('Calendar_model');
}
/*compress*/
/*Home page Calendar view */
Public function index()
{
$this->load->view('home');
}
/*Get all Events */
Public function getEvents()
{
$result=$this->Calendar_model->getEvents();
echo json_encode($result);
}
/*Add new event */
Public function addEvent()
{
$result=$this->Calendar_model->addEvent();
echo $result;
}
/*Update Event */
Public function updateEvent()
{
$result=$this->Calendar_model->updateEvent();
echo $result;
}
/*Delete Event*/
Public function deleteEvent()
{
$result=$this->Calendar_model->deleteEvent();
echo $result;
}
Public function dragUpdateEvent()
{
$result=$this->Calendar_model->dragUpdateEvent();
echo $result;
}
}