Skip to content

Commit a86321c

Browse files
committed
Initial commit
1 parent 8fbdad8 commit a86321c

File tree

3 files changed

+321
-0
lines changed

3 files changed

+321
-0
lines changed

DB/scheduledb.sql

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
-- phpMyAdmin SQL Dump
2+
-- version 5.2.0
3+
-- https://www.phpmyadmin.net/
4+
--
5+
-- Host: 127.0.0.1
6+
-- Generation Time: Dec 27, 2022 at 07:30 PM
7+
-- Server version: 10.4.24-MariaDB
8+
-- PHP Version: 8.1.5
9+
10+
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
11+
START TRANSACTION;
12+
SET time_zone = "+00:00";
13+
14+
15+
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
16+
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
17+
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
18+
/*!40101 SET NAMES utf8mb4 */;
19+
20+
--
21+
-- Database: `scheduledb`
22+
--
23+
24+
-- --------------------------------------------------------
25+
26+
--
27+
-- Table structure for table `appointments`
28+
--
29+
30+
CREATE TABLE `appointments` (
31+
`Id` int(11) NOT NULL,
32+
`Subject` varchar(200) DEFAULT NULL,
33+
`StartTime` datetime NOT NULL,
34+
`EndTime` datetime NOT NULL,
35+
`StartTimezone` varchar(200) DEFAULT NULL,
36+
`EndTimezone` varchar(200) DEFAULT NULL,
37+
`Location` varchar(200) DEFAULT NULL,
38+
`Description` varchar(200) DEFAULT NULL,
39+
`IsAllDay` bit(1) NOT NULL,
40+
`RecurrenceID` int(11) DEFAULT NULL,
41+
`FollowingID` int(11) DEFAULT NULL,
42+
`RecurrenceRule` varchar(200) DEFAULT NULL,
43+
`RecurrenceException` varchar(200) DEFAULT NULL,
44+
`IsReadonly` bit(1) DEFAULT NULL,
45+
`IsBlock` bit(1) DEFAULT NULL,
46+
`RoomID` int(11) DEFAULT NULL
47+
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
48+
49+
--
50+
-- Dumping data for table `appointments`
51+
--
52+
53+
INSERT INTO `appointments` (`Id`, `Subject`, `StartTime`, `EndTime`, `StartTimezone`, `EndTimezone`, `Location`, `Description`, `IsAllDay`, `RecurrenceID`, `FollowingID`, `RecurrenceRule`, `RecurrenceException`, `IsReadonly`, `IsBlock`, `RoomID`) VALUES
54+
(1, 'Meeting', '2022-12-12 00:00:00', '2022-12-13 00:00:00', NULL, NULL, '', '', b'1', NULL, NULL, 'FREQ=DAILY;INTERVAL=1;', '20221213T183000Z', NULL, NULL, NULL),
55+
(2, 'edited', '2022-12-05 00:00:00', '2022-12-08 00:00:00', NULL, NULL, '', '', b'1', NULL, NULL, NULL, NULL, NULL, NULL, 4),
56+
(3, 'Edited event', '2022-12-05 00:00:00', '2022-12-11 00:00:00', NULL, NULL, '', '', b'1', NULL, NULL, NULL, NULL, NULL, NULL, 4);
57+
COMMIT;
58+
59+
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
60+
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
61+
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;

index.php

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
<html xmlns="http://www.w3.org/1999/xhtml">
2+
<head>
3+
<title>Essential Studio for JavaScript : Detail Template</title>
4+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
5+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-base/styles/material.css" rel="stylesheet" type="text/css"/>
6+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-buttons/styles/material.css" rel="stylesheet" type="text/css"/>
7+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-calendars/styles/material.css" rel="stylesheet" type="text/css"/>
8+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-dropdowns/styles/material.css" rel="stylesheet" type="text/css"/>
9+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-inputs/styles/material.css" rel="stylesheet" type="text/css"/>
10+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-splitbuttons/styles/material.css" rel="stylesheet" type="text/css"/>
11+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-lists/styles/material.css" rel="stylesheet" type="text/css"/>
12+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-popups/styles/material.css" rel="stylesheet" type="text/css"/>
13+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-navigations/styles/material.css" rel="stylesheet" type="text/css"/>
14+
<link href="https://cdn.syncfusion.com/ej2/20.4.38/ej2-schedule/styles/material.css" rel="stylesheet" type="text/css"/>
15+
<script src="https://cdn.syncfusion.com/ej2/20.4.38/dist/ej2.min.js" type="text/javascript"></script>
16+
</head>
17+
<body>
18+
<?php
19+
// initialize scheduler
20+
echo '
21+
<div id="Schedule"></div>
22+
<script>
23+
var dataManager = new ej.data.DataManager({
24+
url: "http://localhost/ej2-php-crud-service/server.php",
25+
crudUrl: "http://localhost/ej2-php-crud-service/server.php",
26+
adaptor: new ej.data.UrlAdaptor(),
27+
crossDomain: true
28+
});
29+
var scheduleObj = new ej.schedule.Schedule({
30+
height: "550px",
31+
selectedDate: new Date(2020, 9, 20),
32+
views: ["TimelineDay", "TimelineWeek"],
33+
allowDragAndDrop: true,
34+
eventSettings: { dataSource: dataManager },
35+
group: {
36+
resources: ["MeetingRoom"]
37+
},
38+
resources: [{
39+
field: "RoomID", title: "Room Type",
40+
name: "MeetingRoom", allowMultiple: true,
41+
dataSource: [
42+
{ text: "Jammy", id: 1, color: "#ea7a57", capacity: 20, type: "Conference" },
43+
{ text: "Tweety", id: 2, color: "#7fa900", capacity: 7, type: "Cabin" },
44+
{ text: "Nestle", id: 3, color: "#5978ee", capacity: 5, type: "Cabin" },
45+
{ text: "Phoenix", id: 4, color: "#fec200", capacity: 15, type: "Conference" },
46+
{ text: "Mission", id: 5, color: "#df5286", capacity: 25, type: "Conference" },
47+
{ text: "Hangout", id: 6, color: "#00bdae", capacity: 10, type: "Cabin" },
48+
{ text: "Rick Roll", id: 7, color: "#865fcf", capacity: 20, type: "Conference" },
49+
{ text: "Rainbow", id: 8, color: "#1aaa55", capacity: 8, type: "Cabin" },
50+
{ text: "Swarm", id: 9, color: "#df5286", capacity: 30, type: "Conference" },
51+
{ text: "Photogenic", id: 10, color: "#710193", capacity: 25, type: "Conference" }
52+
],
53+
textField: "text", idField: "id", colorField: "color"
54+
}],
55+
});
56+
scheduleObj.appendTo("#Schedule");
57+
</script>
58+
';
59+
?>
60+
</body>
61+
</html>

0 commit comments

Comments
 (0)