diff --git a/GraphQl/package.json b/GraphQl/package.json
new file mode 100644
index 0000000..546c7ff
--- /dev/null
+++ b/GraphQl/package.json
@@ -0,0 +1,18 @@
+{
+ "name": "graphql-server",
+ "version": "1.0.0",
+ "description": "",
+ "main": "index.js",
+ "scripts": {
+ "dev": "graphpack --port 4400",
+ "build": "graphpack build"
+ },
+ "author": "",
+ "license": "ISC",
+ "devDependencies": {
+ "graphpack": "^1.0.9"
+ },
+ "dependencies": {
+ "@syncfusion/ej2-data": "^19.2.55"
+ }
+}
diff --git a/GraphQl/src/db.js b/GraphQl/src/db.js
new file mode 100644
index 0000000..a93a4e3
--- /dev/null
+++ b/GraphQl/src/db.js
@@ -0,0 +1,112 @@
+
+export let eventsData = [
+ {
+ Id: 1,
+ Subject: 'Server Maintenance',
+ StartTime: new Date(2021, 1, 11, 10, 0).toISOString(),
+ EndTime: new Date(2021, 1, 11, 11, 30).toISOString(),
+ Location: 'Seattle'
+ }, {
+ Id: 2,
+ Subject: 'Art & Painting Gallery',
+ StartTime: new Date(2021, 1, 12, 12, 0).toISOString(),
+ EndTime: new Date(2021, 1, 12, 14, 0).toISOString(),
+ Location: 'Costa Rica'
+ }, {
+ Id: 3,
+ Subject: 'Dany Birthday Celebration',
+ StartTime: new Date(2021, 1, 13, 10, 0).toISOString(),
+ EndTime: new Date(2021, 1, 13, 11, 30).toISOString(),
+ Location: 'Kirkland'
+ }, {
+ Id: 4,
+ Subject: 'John Wedding Anniversary',
+ StartTime: new Date(2021, 1, 14, 9, 0).toISOString(),
+ EndTime: new Date(2021, 1, 14, 10, 0).toISOString(),
+ Location: 'Redmond'
+ }, {
+ Id: 5,
+ Subject: 'ISA Annual Conference',
+ StartTime: new Date(2021, 1, 15, 10, 0).toISOString(),
+ EndTime: new Date(2021, 1, 15, 11, 30).toISOString(),
+ Location: 'USA'
+ }, {
+ Id: 6,
+ Subject: 'Equipment Maintenance',
+ StartTime: new Date(2021, 1, 16, 12, 0).toISOString(),
+ EndTime: new Date(2021, 1, 16, 14, 0).toISOString(),
+ Location: 'Seattle',
+ }, {
+ Id: 7,
+ Subject: 'Aircraft Maintenance',
+ StartTime: new Date(2021, 1, 17, 10, 0).toISOString(),
+ EndTime: new Date(2021, 1, 17, 11, 30).toISOString(),
+ Location: 'Seattle'
+ }, {
+ Id: 8,
+ Subject: 'Facilities Maintenance',
+ StartTime: new Date(2021, 1, 19, 9, 30).toISOString(),
+ EndTime: new Date(2021, 1, 19, 11, 0).toISOString(),
+ Location: 'Seattle'
+ }, {
+ Id: 9,
+ Subject: 'Britto Birthday Celebration',
+ StartTime: new Date(2021, 1, 21, 11, 0).toISOString(),
+ EndTime: new Date(2021, 1, 21, 13, 0).toISOString(),
+ Location: 'Greenland'
+ }, {
+ Id: 10,
+ Subject: 'Justin Wedding Anniversary',
+ StartTime: new Date(2021, 1, 22, 9, 30).toISOString(),
+ EndTime: new Date(2021, 1, 22, 11, 0).toISOString(),
+ Location: 'Finland'
+ }, {
+ Id: 11,
+ Subject: 'AIEA Annual Meet',
+ StartTime: new Date(2021, 1, 9, 10, 0).toISOString(),
+ EndTime: new Date(2021, 1, 9, 11, 30).toISOString(),
+ Location: 'USA'
+ }, {
+ Id: 12,
+ Subject: 'AAN Conference',
+ StartTime: new Date(2021, 1, 7, 10, 30).toISOString(),
+ EndTime: new Date(2021, 1, 7, 12, 30).toISOString(),
+ Location: 'USA'
+ }, {
+ Id: 13,
+ Subject: 'Photography Gallery',
+ StartTime: new Date(2021, 1, 5, 10, 0).toISOString(),
+ EndTime: new Date(2021, 1, 5, 11, 30).toISOString(),
+ Location: 'Chennai'
+ }, {
+ Id: 14,
+ Subject: 'Beach Clean-up',
+ StartTime: new Date(2021, 1, 14, 12, 0).toISOString(),
+ EndTime: new Date(2021, 1, 14, 14, 0).toISOString(),
+ Location: 'Mumbai'
+ }, {
+ Id: 15,
+ Subject: 'Turtle Walk',
+ StartTime: new Date(2021, 1, 19, 13, 0).toISOString(),
+ EndTime: new Date(2021, 1, 19, 14, 30).toISOString(),
+ Location: 'Costa Rica'
+ }, {
+ Id: 16,
+ Subject: 'Silent Walk for Cancer day',
+ StartTime: new Date(2021, 1, 22, 13, 0).toISOString(),
+ EndTime: new Date(2021, 1, 22, 14, 30).toISOString(),
+ Location: 'Chennai'
+ }, {
+ Id: 17,
+ Subject: 'Beach Clean-up',
+ StartTime: new Date(2021, 1, 13, 14, 0).toISOString(),
+ EndTime: new Date(2021, 1, 13, 16, 0).toISOString(),
+ Location: 'Mumbai'
+ }, {
+ Id: 18,
+ Subject: 'Photography Gallery',
+ StartTime: new Date(2021, 1, 15, 14, 0).toISOString(),
+ EndTime: new Date(2021, 1, 15, 16, 0).toISOString(),
+ Location: 'Chennai'
+ }
+ ];
\ No newline at end of file
diff --git a/GraphQl/src/resolvers.js b/GraphQl/src/resolvers.js
new file mode 100644
index 0000000..ffcda85
--- /dev/null
+++ b/GraphQl/src/resolvers.js
@@ -0,0 +1,49 @@
+import { eventsData } from "./db";
+
+const resolvers = {
+ Query: {
+ getEvents: (parent, datamanager, context, info) => {
+ const dataArgs = datamanager;
+ const params = JSON.parse(dataArgs.datamanager.params);
+ console.log('startDate: ' + params.StartDate + ' EndDate: ' + params.EndDate);
+ var data = eventsData.filter(x => new Date(x.StartTime) >= new Date(params.StartDate) && new Date(x.EndTime) <= new Date(params.EndDate));
+ return {result: data || eventsData};
+ }
+ },
+
+ Mutation: {
+ batchUpdate: (parent, { added, changed, deleted }, context, info) => {
+ if (added && added.length > 0) {
+ console.log('added: ' + added.length);
+ added.forEach((order) => {
+ eventsData.push(order);
+ });
+ }
+ if (changed && changed.length > 0) {
+ console.log('changed: ' + changed.length);
+ changed.forEach((order) => {
+ let newOrder = eventsData.find(app => app.Id === order.Id);
+ newOrder.Id = order.Id;
+ newOrder.Subject = order.Subject;
+ newOrder.StartTime = order.StartTime;
+ newOrder.EndTime = order.EndTime;
+ newOrder.Location = order.Location;
+ newOrder.IsAllDay = order.IsAllDay;
+ newOrder.RecurrenceRule = order.RecurrenceRule;
+ newOrder.StartTimezone = order.StartTimezone;
+ newOrder.EndTimezone = order.EndTimezone;
+ });
+ }
+ if (deleted && deleted.length > 0) {
+ console.log('deleted: ' + deleted.length);
+ deleted.forEach((order) => {
+ const orderIndex = eventsData.findIndex(app => app.Id === parseInt(order.Id));
+ if (orderIndex === -1) throw new Error("app not found." + order.Id);
+ eventsData.splice(orderIndex, 1);
+ });
+ }
+ }
+ }
+};
+
+export default resolvers;
\ No newline at end of file
diff --git a/GraphQl/src/schema.graphql b/GraphQl/src/schema.graphql
new file mode 100644
index 0000000..0645653
--- /dev/null
+++ b/GraphQl/src/schema.graphql
@@ -0,0 +1,63 @@
+input Sort {
+ name: String!
+ direction: String!
+}
+
+input Aggregate {
+ field: String!
+ type: String!
+}
+
+#Syncfusion DataManager query params
+
+input DataManager {
+ skip: Int
+ take: Int
+ sorted: [Sort]
+ group: [String]
+ table: String
+ select: [String]
+ where: String
+ search: String
+ requiresCounts: Boolean
+ aggregates: [Aggregate]
+ params: String
+}
+
+# Schedule Appointment field names
+input AppointmentFields {
+ Id: Int!
+ Subject: String
+ StartTime: String!
+ EndTime: String!
+ Location: String
+ IsAllDay: Boolean
+ Guid: String
+ RecurrenceRule: String
+ StartTimezone: String
+ EndTimezone: String
+}
+
+type Appointment {
+ Id: Int!
+ Subject: String
+ StartTime: String!
+ EndTime: String!
+ Location: String
+ IsAllDay: Boolean
+ RecurrenceRule: String
+ StartTimezone: String
+ EndTimezone: String
+}
+
+type ReturnType {
+ result: [Appointment]
+}
+
+type Query {
+ getEvents(datamanager: DataManager): ReturnType
+}
+
+type Mutation {
+ batchUpdate(added: [AppointmentFields], changed: [AppointmentFields], deleted: [AppointmentFields]): Appointment
+}
\ No newline at end of file
diff --git a/README.md b/README.md
index 3024cc5..9eeffe6 100644
--- a/README.md
+++ b/README.md
@@ -1 +1,32 @@
-# ej2-angular-scheduler-crud-graphql-adaptor
\ No newline at end of file
+# ej2-angular-scheduler-crud-graphql-adaptor
+
+This project is a skeleton application used to create [Syncfusion Angular Components](https://www.syncfusion.com/angular-ui-components) web application.
+
+## Add Syncfusion Grid component in your application
+
+Refer the following UG documenation for adding Syncfusion Angular component in your application
+* [Getting Started of Syncfusion Angular Scheduler component](https://ej2.syncfusion.com/angular/documentation/schedule/getting-started)
+
+## GraphQL Server setup
+
+You can setup GraphQL server by using `graphpack` npm package. Find the following link for getting more details for your reference.
+[`https://www.npmjs.com/package/graphpack`](https://www.npmjs.com/package/graphpack)
+
+## Run the GraphQL Server
+
+```
+npm run dev
+```
+
+## Run the client Schedule application
+
+```
+npm start
+```
+
+## Resources
+
+You can also refer the below resources to know more details about Syncfusion Angular Scheduler components.
+* [Demo](https://ej2.syncfusion.com/angular/demos/#/material/schedule/default)
+* [Documentation](https://helpej2.syncfusion.com/angular/documentation/schedule/)
+* [GraphQL with Syncfusion DataManager](https://ej2.syncfusion.com/angular/documentation/data/adaptors/#graphql-adaptor)
\ No newline at end of file
diff --git a/Schedule/.browserslistrc b/Schedule/.browserslistrc
new file mode 100644
index 0000000..4f9ac26
--- /dev/null
+++ b/Schedule/.browserslistrc
@@ -0,0 +1,16 @@
+# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
+# For additional information regarding the format and rule options, please see:
+# https://github.com/browserslist/browserslist#queries
+
+# For the full list of supported browsers by the Angular framework, please see:
+# https://angular.io/guide/browser-support
+
+# You can see what browsers were selected by your queries by running:
+# npx browserslist
+
+last 1 Chrome version
+last 1 Firefox version
+last 2 Edge major versions
+last 2 Safari major versions
+last 2 iOS major versions
+Firefox ESR
diff --git a/Schedule/.editorconfig b/Schedule/.editorconfig
new file mode 100644
index 0000000..59d9a3a
--- /dev/null
+++ b/Schedule/.editorconfig
@@ -0,0 +1,16 @@
+# Editor configuration, see https://editorconfig.org
+root = true
+
+[*]
+charset = utf-8
+indent_style = space
+indent_size = 2
+insert_final_newline = true
+trim_trailing_whitespace = true
+
+[*.ts]
+quote_type = single
+
+[*.md]
+max_line_length = off
+trim_trailing_whitespace = false
diff --git a/Schedule/.gitignore b/Schedule/.gitignore
new file mode 100644
index 0000000..105c00f
--- /dev/null
+++ b/Schedule/.gitignore
@@ -0,0 +1,46 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+
+# compiled output
+/dist
+/tmp
+/out-tsc
+# Only exists if Bazel was run
+/bazel-out
+
+# dependencies
+/node_modules
+
+# profiling files
+chrome-profiler-events*.json
+
+# IDEs and editors
+/.idea
+.project
+.classpath
+.c9/
+*.launch
+.settings/
+*.sublime-workspace
+
+# IDE - VSCode
+.vscode/*
+!.vscode/settings.json
+!.vscode/tasks.json
+!.vscode/launch.json
+!.vscode/extensions.json
+.history/*
+
+# misc
+/.angular/cache
+/.sass-cache
+/connect.lock
+/coverage
+/libpeerconnection.log
+npm-debug.log
+yarn-error.log
+testem.log
+/typings
+
+# System Files
+.DS_Store
+Thumbs.db
diff --git a/Schedule/angular.json b/Schedule/angular.json
new file mode 100644
index 0000000..07fb341
--- /dev/null
+++ b/Schedule/angular.json
@@ -0,0 +1,111 @@
+{
+ "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
+ "version": 1,
+ "newProjectRoot": "projects",
+ "projects": {
+ "ej2-angular-app": {
+ "projectType": "application",
+ "schematics": {
+ "@schematics/angular:component": {
+ "style": "scss"
+ },
+ "@schematics/angular:application": {
+ "strict": true
+ }
+ },
+ "root": "",
+ "sourceRoot": "src",
+ "prefix": "app",
+ "architect": {
+ "build": {
+ "builder": "@angular-devkit/build-angular:browser",
+ "options": {
+ "outputPath": "dist/ej2-angular-app",
+ "index": "src/index.html",
+ "main": "src/main.ts",
+ "polyfills": "src/polyfills.ts",
+ "tsConfig": "tsconfig.app.json",
+ "inlineStyleLanguage": "scss",
+ "assets": [
+ "src/favicon.ico",
+ "src/assets"
+ ],
+ "styles": [
+ "src/styles.scss"
+ ],
+ "scripts": []
+ },
+ "configurations": {
+ "production": {
+ "budgets": [
+ {
+ "type": "initial",
+ "maximumWarning": "500kb",
+ "maximumError": "1mb"
+ },
+ {
+ "type": "anyComponentStyle",
+ "maximumWarning": "2kb",
+ "maximumError": "4kb"
+ }
+ ],
+ "fileReplacements": [
+ {
+ "replace": "src/environments/environment.ts",
+ "with": "src/environments/environment.prod.ts"
+ }
+ ],
+ "outputHashing": "all"
+ },
+ "development": {
+ "buildOptimizer": false,
+ "optimization": false,
+ "vendorChunk": true,
+ "extractLicenses": false,
+ "sourceMap": true,
+ "namedChunks": true
+ }
+ },
+ "defaultConfiguration": "production"
+ },
+ "serve": {
+ "builder": "@angular-devkit/build-angular:dev-server",
+ "configurations": {
+ "production": {
+ "browserTarget": "ej2-angular-app:build:production"
+ },
+ "development": {
+ "browserTarget": "ej2-angular-app:build:development"
+ }
+ },
+ "defaultConfiguration": "development"
+ },
+ "extract-i18n": {
+ "builder": "@angular-devkit/build-angular:extract-i18n",
+ "options": {
+ "browserTarget": "ej2-angular-app:build"
+ }
+ },
+ "test": {
+ "builder": "@angular-devkit/build-angular:karma",
+ "options": {
+ "main": "src/test.ts",
+ "polyfills": "src/polyfills.ts",
+ "tsConfig": "tsconfig.spec.json",
+ "karmaConfig": "karma.conf.js",
+ "inlineStyleLanguage": "scss",
+ "assets": [
+ "src/favicon.ico",
+ "src/assets"
+ ],
+ "styles": [
+ "src/styles.scss"
+ ],
+ "scripts": []
+ }
+ }
+ }
+ }
+ },
+ "defaultProject": "ej2-angular-app"
+}
diff --git a/Schedule/karma.conf.js b/Schedule/karma.conf.js
new file mode 100644
index 0000000..15021a2
--- /dev/null
+++ b/Schedule/karma.conf.js
@@ -0,0 +1,44 @@
+// Karma configuration file, see link for more information
+// https://karma-runner.github.io/1.0/config/configuration-file.html
+
+module.exports = function (config) {
+ config.set({
+ basePath: '',
+ frameworks: ['jasmine', '@angular-devkit/build-angular'],
+ plugins: [
+ require('karma-jasmine'),
+ require('karma-chrome-launcher'),
+ require('karma-jasmine-html-reporter'),
+ require('karma-coverage'),
+ require('@angular-devkit/build-angular/plugins/karma')
+ ],
+ client: {
+ jasmine: {
+ // you can add configuration options for Jasmine here
+ // the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html
+ // for example, you can disable the random execution with `random: false`
+ // or set a specific seed with `seed: 4321`
+ },
+ clearContext: false // leave Jasmine Spec Runner output visible in browser
+ },
+ jasmineHtmlReporter: {
+ suppressAll: true // removes the duplicated traces
+ },
+ coverageReporter: {
+ dir: require('path').join(__dirname, './coverage/ej2-angular-app'),
+ subdir: '.',
+ reporters: [
+ { type: 'html' },
+ { type: 'text-summary' }
+ ]
+ },
+ reporters: ['progress', 'kjhtml'],
+ port: 9876,
+ colors: true,
+ logLevel: config.LOG_INFO,
+ autoWatch: true,
+ browsers: ['Chrome'],
+ singleRun: false,
+ restartOnFileChange: true
+ });
+};
diff --git a/Schedule/package.json b/Schedule/package.json
new file mode 100644
index 0000000..d9d9d56
--- /dev/null
+++ b/Schedule/package.json
@@ -0,0 +1,42 @@
+{
+ "name": "ej2-angular-app",
+ "version": "0.0.0",
+ "scripts": {
+ "ng": "ng",
+ "start": "ng serve",
+ "build": "ng build",
+ "watch": "ng build --watch --configuration development",
+ "test": "ng test"
+ },
+ "private": true,
+ "dependencies": {
+ "@angular/animations": "~13.0.0-next.0",
+ "@angular/common": "~13.0.0-next.0",
+ "@angular/compiler": "~13.0.0-next.0",
+ "@angular/core": "~13.0.0-next.0",
+ "@angular/forms": "~13.0.0-next.0",
+ "@angular/platform-browser": "~13.0.0-next.0",
+ "@angular/platform-browser-dynamic": "~13.0.0-next.0",
+ "@angular/router": "~13.0.0-next.0",
+ "@syncfusion/ej2-angular-buttons": "^20.1.55",
+ "@syncfusion/ej2-angular-dropdowns": "^20.1.59",
+ "@syncfusion/ej2-angular-schedule": "^20.1.59",
+ "rxjs": "~7.4.0",
+ "tslib": "^2.3.0",
+ "zone.js": "~0.11.4"
+ },
+ "devDependencies": {
+ "@angular-devkit/build-angular": "~13.0.0",
+ "@angular/cli": "~13.0.0",
+ "@angular/compiler-cli": "~13.0.0-next.0",
+ "@types/jasmine": "~3.10.0",
+ "@types/node": "^12.11.1",
+ "jasmine-core": "~3.10.0",
+ "karma": "~6.3.0",
+ "karma-chrome-launcher": "~3.1.0",
+ "karma-coverage": "~2.0.3",
+ "karma-jasmine": "~4.0.0",
+ "karma-jasmine-html-reporter": "~1.7.0",
+ "typescript": "~4.4.3"
+ }
+}
diff --git a/Schedule/src/app/app-routing.module.ts b/Schedule/src/app/app-routing.module.ts
new file mode 100644
index 0000000..0297262
--- /dev/null
+++ b/Schedule/src/app/app-routing.module.ts
@@ -0,0 +1,10 @@
+import { NgModule } from '@angular/core';
+import { RouterModule, Routes } from '@angular/router';
+
+const routes: Routes = [];
+
+@NgModule({
+ imports: [RouterModule.forRoot(routes)],
+ exports: [RouterModule]
+})
+export class AppRoutingModule { }
diff --git a/Schedule/src/app/app.component.html b/Schedule/src/app/app.component.html
new file mode 100644
index 0000000..40c3b70
--- /dev/null
+++ b/Schedule/src/app/app.component.html
@@ -0,0 +1,2 @@
+