diff --git a/scheduler_app/app/(routes)/dashboard/availability/page.js b/scheduler_app/app/(routes)/dashboard/availability/page.js
new file mode 100644
index 0000000..cfc0a98
--- /dev/null
+++ b/scheduler_app/app/(routes)/dashboard/availability/page.js
@@ -0,0 +1,37 @@
+import DaysList from '@/app/_utils/DaysList'
+import React from 'react'
+import { Checkbox } from "@/components/ui/checkbox"
+import { Input } from '@/components/ui/input'
+import { Button } from '@/components/ui/button'
+
+
+const Availability = () => {
+ return (
+
+
Availability
+
+
Available days & time
+
+ {DaysList.map((item, index) => (
+
+ ))}
+
+
+
+
+ )
+}
+
+export default Availability
\ No newline at end of file
diff --git a/scheduler_app/app/(routes)/dashboard/meeting/_components/MeetingEventList.js b/scheduler_app/app/(routes)/dashboard/meeting/_components/MeetingEventList.js
index 5192d95..e12af31 100644
--- a/scheduler_app/app/(routes)/dashboard/meeting/_components/MeetingEventList.js
+++ b/scheduler_app/app/(routes)/dashboard/meeting/_components/MeetingEventList.js
@@ -2,11 +2,13 @@
import React, { useEffect, useState } from 'react'
import { app } from '@/config/FirebaseConfig'
import { useKindeBrowserClient } from '@kinde-oss/kinde-auth-nextjs'
-import { collection, getDocs, getFirestore, orderBy, query, where } from 'firebase/firestore'
+import { collection, deleteDoc, doc, getDocs, getFirestore, orderBy, query, where } from 'firebase/firestore'
import { GoClock } from "react-icons/go";
import { PiMapPinLight, PiCopyLight, PiShareFatLight } from 'react-icons/pi'
import { IoSettingsOutline } from "react-icons/io5";
import { toast } from 'sonner'
+import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger, } from "@/components/ui/dropdown-menu"
+
const MeetingEventList = () => {
const [eventList, setEventList] = useState([]);
@@ -23,6 +25,14 @@ const MeetingEventList = () => {
});
}
+ //Delete event functionality
+ const onDeleteEvent = async (event) => {
+ await deleteDoc(doc(db, "MeetingEvent", event?.id)).then(res => {
+ toast('Meeting/Event is deleted');
+ getEventList();
+ })
+ }
+
useEffect(() => {
user && getEventList()
}, [user])
@@ -43,7 +53,17 @@ const MeetingEventList = () => {
-
+
+
+
+
+
+
+ Edit
+ onDeleteEvent(event)}>Delete
+
+
+
)): Loading...
diff --git a/scheduler_app/app/_utils/DaysList.js b/scheduler_app/app/_utils/DaysList.js
new file mode 100644
index 0000000..0e67f0a
--- /dev/null
+++ b/scheduler_app/app/_utils/DaysList.js
@@ -0,0 +1,23 @@
+export default[
+ {
+ day: 'Sunday'
+ },
+ {
+ day: 'Monday'
+ },
+ {
+ day: 'Tuesday'
+ },
+ {
+ day: 'Wednesday'
+ },
+ {
+ day: 'Thursday'
+ },
+ {
+ day: 'Friday'
+ },
+ {
+ day: 'Saturday'
+ }
+]
\ No newline at end of file
diff --git a/scheduler_app/components/ui/checkbox.jsx b/scheduler_app/components/ui/checkbox.jsx
new file mode 100644
index 0000000..dc639bc
--- /dev/null
+++ b/scheduler_app/components/ui/checkbox.jsx
@@ -0,0 +1,24 @@
+"use client"
+
+import * as React from "react"
+import * as CheckboxPrimitive from "@radix-ui/react-checkbox"
+import { Check } from "lucide-react"
+
+import { cn } from "@/lib/utils"
+
+const Checkbox = React.forwardRef(({ className, ...props }, ref) => (
+
+
+
+
+
+))
+Checkbox.displayName = CheckboxPrimitive.Root.displayName
+
+export { Checkbox }
diff --git a/scheduler_app/package-lock.json b/scheduler_app/package-lock.json
index f89d5e8..b16ceff 100644
--- a/scheduler_app/package-lock.json
+++ b/scheduler_app/package-lock.json
@@ -9,6 +9,7 @@
"version": "0.1.0",
"dependencies": {
"@kinde-oss/kinde-auth-nextjs": "^2.2.4",
+ "@radix-ui/react-checkbox": "^1.0.4",
"@radix-ui/react-dropdown-menu": "^2.0.6",
"@radix-ui/react-slot": "^1.0.2",
"class-variance-authority": "^0.7.0",
@@ -2538,6 +2539,36 @@
}
}
},
+ "node_modules/@radix-ui/react-checkbox": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/@radix-ui/react-checkbox/-/react-checkbox-1.0.4.tgz",
+ "integrity": "sha512-CBuGQa52aAYnADZVt/KBQzXrwx6TqnlwtcIPGtVt5JkkzQwMOLJjPukimhfKEr4GQNd43C+djUh5Ikopj8pSLg==",
+ "dependencies": {
+ "@babel/runtime": "^7.13.10",
+ "@radix-ui/primitive": "1.0.1",
+ "@radix-ui/react-compose-refs": "1.0.1",
+ "@radix-ui/react-context": "1.0.1",
+ "@radix-ui/react-presence": "1.0.1",
+ "@radix-ui/react-primitive": "1.0.3",
+ "@radix-ui/react-use-controllable-state": "1.0.1",
+ "@radix-ui/react-use-previous": "1.0.1",
+ "@radix-ui/react-use-size": "1.0.1"
+ },
+ "peerDependencies": {
+ "@types/react": "*",
+ "@types/react-dom": "*",
+ "react": "^16.8 || ^17.0 || ^18.0",
+ "react-dom": "^16.8 || ^17.0 || ^18.0"
+ },
+ "peerDependenciesMeta": {
+ "@types/react": {
+ "optional": true
+ },
+ "@types/react-dom": {
+ "optional": true
+ }
+ }
+ },
"node_modules/@radix-ui/react-collection": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/@radix-ui/react-collection/-/react-collection-1.0.3.tgz",
@@ -2992,6 +3023,23 @@
}
}
},
+ "node_modules/@radix-ui/react-use-previous": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/@radix-ui/react-use-previous/-/react-use-previous-1.0.1.tgz",
+ "integrity": "sha512-cV5La9DPwiQ7S0gf/0qiD6YgNqM5Fk97Kdrlc5yBcrF3jyEZQwm7vYFqMo4IfeHgJXsRaMvLABFtd0OVEmZhDw==",
+ "dependencies": {
+ "@babel/runtime": "^7.13.10"
+ },
+ "peerDependencies": {
+ "@types/react": "*",
+ "react": "^16.8 || ^17.0 || ^18.0"
+ },
+ "peerDependenciesMeta": {
+ "@types/react": {
+ "optional": true
+ }
+ }
+ },
"node_modules/@radix-ui/react-use-rect": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-use-rect/-/react-use-rect-1.0.1.tgz",
diff --git a/scheduler_app/package.json b/scheduler_app/package.json
index d89accc..08cd08f 100644
--- a/scheduler_app/package.json
+++ b/scheduler_app/package.json
@@ -10,6 +10,7 @@
},
"dependencies": {
"@kinde-oss/kinde-auth-nextjs": "^2.2.4",
+ "@radix-ui/react-checkbox": "^1.0.4",
"@radix-ui/react-dropdown-menu": "^2.0.6",
"@radix-ui/react-slot": "^1.0.2",
"class-variance-authority": "^0.7.0",