--
-- PostgreSQL database dump
--

-- Dumped from database version 17.5
-- Dumped by pg_dump version 17.5

SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
SET transaction_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SELECT pg_catalog.set_config('search_path', '', false);
SET check_function_bodies = false;
SET xmloption = content;
SET client_min_messages = warning;
SET row_security = off;

--
-- Name: public; Type: SCHEMA; Schema: -; Owner: Anup
--

-- *not* creating schema, since initdb creates it


ALTER SCHEMA public OWNER TO "Anup";

--
-- Name: SCHEMA public; Type: COMMENT; Schema: -; Owner: Anup
--

COMMENT ON SCHEMA public IS '';


--
-- Name: AssignmentStatus; Type: TYPE; Schema: public; Owner: Anup
--

CREATE TYPE public."AssignmentStatus" AS ENUM (
    'submitted',
    'graded',
    'pending'
);


ALTER TYPE public."AssignmentStatus" OWNER TO "Anup";

--
-- Name: AttendanceStatus; Type: TYPE; Schema: public; Owner: Anup
--

CREATE TYPE public."AttendanceStatus" AS ENUM (
    'present',
    'absent'
);


ALTER TYPE public."AttendanceStatus" OWNER TO "Anup";

--
-- Name: EnrollmentStatus; Type: TYPE; Schema: public; Owner: Anup
--

CREATE TYPE public."EnrollmentStatus" AS ENUM (
    'pending',
    'active',
    'expired',
    'cancelled'
);


ALTER TYPE public."EnrollmentStatus" OWNER TO "Anup";

--
-- Name: Gateway; Type: TYPE; Schema: public; Owner: Anup
--

CREATE TYPE public."Gateway" AS ENUM (
    'khalti',
    'esewa',
    'stripe',
    'paypal',
    'cash'
);


ALTER TYPE public."Gateway" OWNER TO "Anup";

--
-- Name: PaymentStatus; Type: TYPE; Schema: public; Owner: Anup
--

CREATE TYPE public."PaymentStatus" AS ENUM (
    'pending',
    'paid',
    'failed'
);


ALTER TYPE public."PaymentStatus" OWNER TO "Anup";

--
-- Name: Role; Type: TYPE; Schema: public; Owner: Anup
--

CREATE TYPE public."Role" AS ENUM (
    'admin',
    'teacher',
    'student',
    'accountant'
);


ALTER TYPE public."Role" OWNER TO "Anup";

SET default_tablespace = '';

SET default_table_access_method = heap;

--
-- Name: Assignment; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Assignment" (
    id integer NOT NULL,
    title text NOT NULL,
    description text,
    "fileUrl" text,
    "dueDate" timestamp(3) without time zone NOT NULL,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "subjectId" integer NOT NULL,
    "teacherId" integer NOT NULL,
    "fileSize" integer,
    "fileType" text,
    "lessonId" integer
);


ALTER TABLE public."Assignment" OWNER TO "Anup";

--
-- Name: Assignment_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Assignment_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Assignment_id_seq" OWNER TO "Anup";

--
-- Name: Assignment_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Assignment_id_seq" OWNED BY public."Assignment".id;


--
-- Name: Attendance; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Attendance" (
    id integer NOT NULL,
    status public."AttendanceStatus" DEFAULT 'present'::public."AttendanceStatus" NOT NULL,
    "timestamp" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "classId" integer NOT NULL,
    "studentId" integer NOT NULL
);


ALTER TABLE public."Attendance" OWNER TO "Anup";

--
-- Name: Attendance_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Attendance_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Attendance_id_seq" OWNER TO "Anup";

--
-- Name: Attendance_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Attendance_id_seq" OWNED BY public."Attendance".id;


--
-- Name: ContactMessage; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."ContactMessage" (
    id integer NOT NULL,
    name text NOT NULL,
    email text NOT NULL,
    message text NOT NULL,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);


ALTER TABLE public."ContactMessage" OWNER TO "Anup";

--
-- Name: ContactMessage_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."ContactMessage_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."ContactMessage_id_seq" OWNER TO "Anup";

--
-- Name: ContactMessage_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."ContactMessage_id_seq" OWNED BY public."ContactMessage".id;


--
-- Name: Enrollment; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Enrollment" (
    id integer NOT NULL,
    "studentId" integer NOT NULL,
    "subjectId" integer NOT NULL,
    status public."EnrollmentStatus" DEFAULT 'active'::public."EnrollmentStatus" NOT NULL,
    "startAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "expiresAt" timestamp(3) without time zone,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);


ALTER TABLE public."Enrollment" OWNER TO "Anup";

--
-- Name: Enrollment_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Enrollment_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Enrollment_id_seq" OWNER TO "Anup";

--
-- Name: Enrollment_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Enrollment_id_seq" OWNED BY public."Enrollment".id;


--
-- Name: Lesson; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Lesson" (
    id integer NOT NULL,
    title text NOT NULL,
    "videoUrl" text,
    "pdfUrl" text,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "updatedAt" timestamp(3) without time zone NOT NULL,
    "subjectId" integer NOT NULL,
    "teacherId" integer NOT NULL,
    description text NOT NULL,
    "thumbnailUrl" text,
    views integer DEFAULT 0 NOT NULL,
    "videoDurationSeconds" integer
);


ALTER TABLE public."Lesson" OWNER TO "Anup";

--
-- Name: LessonProgress; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."LessonProgress" (
    id integer NOT NULL,
    "studentId" integer NOT NULL,
    "lessonId" integer NOT NULL,
    "videoWatchedSeconds" integer DEFAULT 0,
    "videoCompleted" boolean DEFAULT false,
    "assignmentCompleted" boolean DEFAULT false,
    "pdfViewed" boolean DEFAULT false,
    completed boolean DEFAULT false,
    "updatedAt" timestamp(3) without time zone NOT NULL
);


ALTER TABLE public."LessonProgress" OWNER TO "Anup";

--
-- Name: LessonProgress_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."LessonProgress_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."LessonProgress_id_seq" OWNER TO "Anup";

--
-- Name: LessonProgress_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."LessonProgress_id_seq" OWNED BY public."LessonProgress".id;


--
-- Name: Lesson_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Lesson_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Lesson_id_seq" OWNER TO "Anup";

--
-- Name: Lesson_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Lesson_id_seq" OWNED BY public."Lesson".id;


--
-- Name: LiveClass; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."LiveClass" (
    id integer NOT NULL,
    "startTime" timestamp(3) without time zone NOT NULL,
    "endTime" timestamp(3) without time zone,
    "meetingUrl" text,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "updatedAt" timestamp(3) without time zone NOT NULL,
    "subjectId" integer NOT NULL,
    "teacherId" integer NOT NULL
);


ALTER TABLE public."LiveClass" OWNER TO "Anup";

--
-- Name: LiveClass_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."LiveClass_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."LiveClass_id_seq" OWNER TO "Anup";

--
-- Name: LiveClass_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."LiveClass_id_seq" OWNED BY public."LiveClass".id;


--
-- Name: Message; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Message" (
    id integer NOT NULL,
    content text NOT NULL,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "senderId" integer NOT NULL,
    "receiverId" integer NOT NULL
);


ALTER TABLE public."Message" OWNER TO "Anup";

--
-- Name: Message_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Message_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Message_id_seq" OWNER TO "Anup";

--
-- Name: Message_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Message_id_seq" OWNED BY public."Message".id;


--
-- Name: Notification; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Notification" (
    id integer NOT NULL,
    message text NOT NULL,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "isRead" boolean DEFAULT false NOT NULL,
    "userId" integer NOT NULL
);


ALTER TABLE public."Notification" OWNER TO "Anup";

--
-- Name: Notification_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Notification_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Notification_id_seq" OWNER TO "Anup";

--
-- Name: Notification_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Notification_id_seq" OWNED BY public."Notification".id;


--
-- Name: Payment; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Payment" (
    id integer NOT NULL,
    amount integer NOT NULL,
    status public."PaymentStatus" DEFAULT 'pending'::public."PaymentStatus" NOT NULL,
    gateway public."Gateway" NOT NULL,
    "transactionId" text,
    "paidAt" timestamp(3) without time zone,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "studentId" integer NOT NULL,
    "subjectId" integer NOT NULL
);


ALTER TABLE public."Payment" OWNER TO "Anup";

--
-- Name: PaymentGatewaySettings; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."PaymentGatewaySettings" (
    id integer NOT NULL,
    service text NOT NULL,
    wallet text NOT NULL,
    "qrBaseUrl" text,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "updatedAt" timestamp(3) without time zone NOT NULL
);


ALTER TABLE public."PaymentGatewaySettings" OWNER TO "Anup";

--
-- Name: PaymentGatewaySettings_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."PaymentGatewaySettings_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."PaymentGatewaySettings_id_seq" OWNER TO "Anup";

--
-- Name: PaymentGatewaySettings_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."PaymentGatewaySettings_id_seq" OWNED BY public."PaymentGatewaySettings".id;


--
-- Name: PaymentRequest; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."PaymentRequest" (
    id integer NOT NULL,
    "txnId" character varying(255) NOT NULL,
    "studentId" integer NOT NULL,
    "subjectId" integer NOT NULL,
    amount integer NOT NULL,
    status character varying(20) DEFAULT 'pending'::character varying,
    "proofImage" text,
    "createdAt" timestamp(6) without time zone DEFAULT CURRENT_TIMESTAMP,
    "approvedAt" timestamp(6) without time zone
);


ALTER TABLE public."PaymentRequest" OWNER TO "Anup";

--
-- Name: PaymentRequest_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."PaymentRequest_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."PaymentRequest_id_seq" OWNER TO "Anup";

--
-- Name: PaymentRequest_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."PaymentRequest_id_seq" OWNED BY public."PaymentRequest".id;


--
-- Name: Payment_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Payment_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Payment_id_seq" OWNER TO "Anup";

--
-- Name: Payment_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Payment_id_seq" OWNED BY public."Payment".id;


--
-- Name: Salary; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Salary" (
    id integer NOT NULL,
    amount integer NOT NULL,
    month text NOT NULL,
    status text DEFAULT 'pending'::text NOT NULL,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "teacherId" integer NOT NULL
);


ALTER TABLE public."Salary" OWNER TO "Anup";

--
-- Name: Salary_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Salary_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Salary_id_seq" OWNER TO "Anup";

--
-- Name: Salary_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Salary_id_seq" OWNED BY public."Salary".id;


--
-- Name: Subject; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Subject" (
    id integer NOT NULL,
    title text NOT NULL,
    description text,
    price integer DEFAULT 0 NOT NULL,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "updatedAt" timestamp(3) without time zone NOT NULL,
    "teacherId" integer NOT NULL
);


ALTER TABLE public."Subject" OWNER TO "Anup";

--
-- Name: Subject_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Subject_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Subject_id_seq" OWNER TO "Anup";

--
-- Name: Subject_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Subject_id_seq" OWNED BY public."Subject".id;


--
-- Name: Submission; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."Submission" (
    id integer NOT NULL,
    "fileUrl" text,
    marks integer,
    status public."AssignmentStatus" DEFAULT 'pending'::public."AssignmentStatus" NOT NULL,
    "assignmentId" integer NOT NULL,
    "studentId" integer NOT NULL,
    "submittedAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    feedback text,
    "gradedAt" timestamp(3) without time zone
);


ALTER TABLE public."Submission" OWNER TO "Anup";

--
-- Name: Submission_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."Submission_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."Submission_id_seq" OWNER TO "Anup";

--
-- Name: Submission_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."Submission_id_seq" OWNED BY public."Submission".id;


--
-- Name: User; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public."User" (
    id integer NOT NULL,
    "firstName" text NOT NULL,
    "lastName" text NOT NULL,
    email text NOT NULL,
    phone text,
    password text NOT NULL,
    role public."Role" DEFAULT 'student'::public."Role" NOT NULL,
    status text DEFAULT 'pending'::text,
    "createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
    "updatedAt" timestamp(3) without time zone NOT NULL,
    "resetToken" text,
    "resetTokenExpiry" timestamp(3) without time zone,
    "refreshToken" text,
    "refreshTokenExpiresAt" timestamp(3) without time zone,
    "esewaNumber" text,
    "lastLogin" timestamp(3) without time zone,
    "lastActivity" timestamp(3) without time zone
);


ALTER TABLE public."User" OWNER TO "Anup";

--
-- Name: User_id_seq; Type: SEQUENCE; Schema: public; Owner: Anup
--

CREATE SEQUENCE public."User_id_seq"
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public."User_id_seq" OWNER TO "Anup";

--
-- Name: User_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: Anup
--

ALTER SEQUENCE public."User_id_seq" OWNED BY public."User".id;


--
-- Name: _prisma_migrations; Type: TABLE; Schema: public; Owner: Anup
--

CREATE TABLE public._prisma_migrations (
    id character varying(36) NOT NULL,
    checksum character varying(64) NOT NULL,
    finished_at timestamp with time zone,
    migration_name character varying(255) NOT NULL,
    logs text,
    rolled_back_at timestamp with time zone,
    started_at timestamp with time zone DEFAULT now() NOT NULL,
    applied_steps_count integer DEFAULT 0 NOT NULL
);


ALTER TABLE public._prisma_migrations OWNER TO "Anup";

--
-- Name: Assignment id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Assignment" ALTER COLUMN id SET DEFAULT nextval('public."Assignment_id_seq"'::regclass);


--
-- Name: Attendance id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Attendance" ALTER COLUMN id SET DEFAULT nextval('public."Attendance_id_seq"'::regclass);


--
-- Name: ContactMessage id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."ContactMessage" ALTER COLUMN id SET DEFAULT nextval('public."ContactMessage_id_seq"'::regclass);


--
-- Name: Enrollment id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Enrollment" ALTER COLUMN id SET DEFAULT nextval('public."Enrollment_id_seq"'::regclass);


--
-- Name: Lesson id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Lesson" ALTER COLUMN id SET DEFAULT nextval('public."Lesson_id_seq"'::regclass);


--
-- Name: LessonProgress id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LessonProgress" ALTER COLUMN id SET DEFAULT nextval('public."LessonProgress_id_seq"'::regclass);


--
-- Name: LiveClass id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LiveClass" ALTER COLUMN id SET DEFAULT nextval('public."LiveClass_id_seq"'::regclass);


--
-- Name: Message id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Message" ALTER COLUMN id SET DEFAULT nextval('public."Message_id_seq"'::regclass);


--
-- Name: Notification id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Notification" ALTER COLUMN id SET DEFAULT nextval('public."Notification_id_seq"'::regclass);


--
-- Name: Payment id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Payment" ALTER COLUMN id SET DEFAULT nextval('public."Payment_id_seq"'::regclass);


--
-- Name: PaymentGatewaySettings id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."PaymentGatewaySettings" ALTER COLUMN id SET DEFAULT nextval('public."PaymentGatewaySettings_id_seq"'::regclass);


--
-- Name: PaymentRequest id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."PaymentRequest" ALTER COLUMN id SET DEFAULT nextval('public."PaymentRequest_id_seq"'::regclass);


--
-- Name: Salary id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Salary" ALTER COLUMN id SET DEFAULT nextval('public."Salary_id_seq"'::regclass);


--
-- Name: Subject id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Subject" ALTER COLUMN id SET DEFAULT nextval('public."Subject_id_seq"'::regclass);


--
-- Name: Submission id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Submission" ALTER COLUMN id SET DEFAULT nextval('public."Submission_id_seq"'::regclass);


--
-- Name: User id; Type: DEFAULT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."User" ALTER COLUMN id SET DEFAULT nextval('public."User_id_seq"'::regclass);


--
-- Data for Name: Assignment; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Assignment" (id, title, description, "fileUrl", "dueDate", "createdAt", "subjectId", "teacherId", "fileSize", "fileType", "lessonId") FROM stdin;
1	aerfg	gdfgfgfg	https://res.cloudinary.com/dvck3axc5/image/upload/v1765698719/lms_lessons/lesson_1765698715947.pdf	2025-12-13 18:15:00	2025-12-14 07:52:00.288	1	3	646770	application/pdf	21
2	Introduction to TypeScript	`This assignment focuses on mastering the fundamentals of TypeScript. You are required to:\r\n\r\nDefine and use basic types: Create variables using string, number, boolean, and array types.\r\n\r\nImplement interfaces and types: Design at least two interfaces and one type alias to model real-world objects.\r\n\r\nUse classes and inheritance: Implement a class hierarchy demonstrating inheritance, encapsulation, and access modifiers.\r\n\r\nGenerics: Create a generic function or class to handle different data types.\r\n\r\nError handling: Implement proper error handling using try-catch blocks where necessary.\r\n\r\nYour submission should include:\r\n\r\nA .ts file or a zipped folder containing all your TypeScript code.\r\n\r\nComments explaining each section of your code.\r\n\r\nScreenshots demonstrating that your code compiles without errors.\r\n\r\nDeadline: Please submit your assignment before the due date. Late submissions may incur a deduction of marks.`	https://res.cloudinary.com/dvck3axc5/image/upload/v1765739372/lms_lessons/lesson_1765739370773.pdf	2025-12-17 18:15:00	2025-12-14 19:09:34.272	1	3	646770	application/pdf	22
3	Introduction to React	This assignment covers the fundamentals of React. You are required to create a simple To-Do application using React components. The app should include the following features:\r\n\r\nAdd new tasks.\r\n\r\nRemove tasks.\r\n\r\nMark tasks as completed.\r\n\r\nMaintain the task list state using React useState hook.\r\n\r\nSubmission Instructions:\r\n\r\nPackage your React project into a ZIP file.\r\n\r\nInclude a README file describing how to run your project.\r\n\r\nSubmit the ZIP file through the assignment submission portal.	https://res.cloudinary.com/dvck3axc5/image/upload/v1765816438/lms_lessons/lesson_1765816437612.pdf	2025-12-17 18:15:00	2025-12-15 16:34:00.925	1	3	128581	application/pdf	22
5	hiufadehiosad	dshuijhsdai	https://res.cloudinary.com/dvck3axc5/image/upload/v1765967871/lms_lessons/lesson_1765967870942.pdf	2025-12-20 10:35:00	2025-12-17 10:37:55.436	1	3	128581	application/pdf	23
6	huygdyu	hsuaiasuia	https://res.cloudinary.com/dvck3axc5/image/upload/v1765968531/lms_lessons/lesson_1765968528998.pdf	2025-12-19 18:30:00	2025-12-17 10:48:55.235	1	3	128581	application/pdf	24
7	jdheuids	hcsdhvhds	https://res.cloudinary.com/dvck3axc5/image/upload/v1766028672/lms_lessons/lesson_1766028673581.pdf	2025-12-19 22:15:00	2025-12-18 03:31:17.833	2	3	128581	application/pdf	25
8	njidshisa	dsck bjkx	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029004/lms_lessons/lesson_1766029004149.pdf	2025-12-18 18:35:00	2025-12-18 03:36:49.42	2	3	128581	application/pdf	25
9	jhqijfhfiusd	 njcsbuis	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029187/lms_lessons/lesson_1766029187810.pdf	2025-12-19 23:15:00	2025-12-18 03:39:52.848	2	3	128581	application/pdf	25
10	yudegys	sdjbjscdh	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029339/lms_lessons/lesson_1766029340392.pdf	2025-12-19 18:40:00	2025-12-18 03:42:24.52	2	3	128581	application/pdf	25
11	yudegys	sdjbjscdh	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029341/lms_lessons/lesson_1766029343187.pdf	2025-12-19 18:40:00	2025-12-18 03:42:26.659	2	3	128581	application/pdf	25
12	;hnduihdsui	cjnsishios	https://res.cloudinary.com/dvck3axc5/image/upload/v1766030481/lms_lessons/lesson_1766030481798.pdf	2025-12-19 18:15:00	2025-12-18 04:01:26.474	2	3	128581	application/pdf	26
13	 xcBhsz	bdsguysa	https://res.cloudinary.com/dvck3axc5/image/upload/v1766047112/lms_lessons/lesson_1766047111872.pdf	2025-12-18 03:15:00	2025-12-18 08:38:36.751	2	3	128581	application/pdf	26
\.


--
-- Data for Name: Attendance; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Attendance" (id, status, "timestamp", "classId", "studentId") FROM stdin;
1	absent	2025-12-16 07:53:23.503	1	5
2	absent	2025-12-16 07:53:23.503	1	4
3	absent	2025-12-16 08:17:04.961	2	5
4	absent	2025-12-16 08:17:04.961	2	4
5	absent	2025-12-16 09:17:16.368	3	5
6	absent	2025-12-16 09:17:16.368	3	4
7	absent	2025-12-16 09:26:32.383	4	5
8	absent	2025-12-16 09:26:32.383	4	4
9	absent	2025-12-16 09:26:49.581	5	5
10	absent	2025-12-16 09:26:49.581	5	4
11	absent	2025-12-16 09:27:19.545	6	5
12	absent	2025-12-16 09:27:19.545	6	4
13	absent	2025-12-16 09:27:34.882	7	5
14	absent	2025-12-16 09:27:34.882	7	4
15	absent	2025-12-16 09:29:33.826	8	5
16	absent	2025-12-16 09:29:33.826	8	4
17	absent	2025-12-16 10:38:11.333	9	4
18	absent	2025-12-16 10:39:02.808	10	4
19	absent	2025-12-16 16:44:20.875	11	4
20	absent	2025-12-16 16:44:56.104	12	4
21	absent	2025-12-17 10:51:43.657	13	4
22	absent	2025-12-18 10:15:23.395	14	4
23	absent	2025-12-18 17:41:38.141	15	4
\.


--
-- Data for Name: ContactMessage; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."ContactMessage" (id, name, email, message, "createdAt") FROM stdin;
\.


--
-- Data for Name: Enrollment; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Enrollment" (id, "studentId", "subjectId", status, "startAt", "expiresAt", "createdAt") FROM stdin;
1	4	3	active	2025-12-09 17:21:54.943	\N	2025-12-09 17:21:54.953
2	4	2	active	2025-12-09 17:22:04.461	\N	2025-12-09 17:22:04.463
3	4	1	active	2025-12-09 17:22:08.341	\N	2025-12-09 17:22:08.342
4	4	11	active	2025-12-10 17:52:13.378	\N	2025-12-10 17:52:13.382
5	4	7	active	2025-12-10 17:52:18.206	\N	2025-12-10 17:52:18.207
6	4	6	active	2025-12-11 10:52:49.992	\N	2025-12-11 10:52:50.032
8	4	5	active	2025-12-12 18:12:05.599	\N	2025-12-12 17:19:05.775
7	4	8	active	2025-12-12 20:16:43.372	\N	2025-12-12 16:53:38.946
15	5	8	active	2025-12-12 20:59:31.263	\N	2025-12-12 20:59:31.264
\.


--
-- Data for Name: Lesson; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Lesson" (id, title, "videoUrl", "pdfUrl", "createdAt", "updatedAt", "subjectId", "teacherId", description, "thumbnailUrl", views, "videoDurationSeconds") FROM stdin;
1	Lesson 1: Introduction to Computers	https://www.youtube.com/watch?v=O5nskjZ_GoI	https://www.tutorialspoint.com/computer_fundamentals/computer_fundamentals.pdf	2025-12-09 07:43:35.61	2025-12-09 07:43:35.61	1	3	Learn about the history of computers, types of computers, and basic components like CPU, memory, and input/output devices.	http://localhost:8080/uploads/thumbnails/lesson_1765266215587.png	0	\N
2	Lesson 2: Course Overview	https://www.youtube.com/watch?v=abc001	\N	2025-12-13 16:59:26.866	2025-12-13 16:59:26.866	1	3	Understand what this course covers and how to navigate it.	http://localhost:8080/uploads/thumbnails/lesson_1765645166846.png	0	\N
3	Lesson 3: Tools & Setup	https://www.youtube.com/watch?v=abc002	https://example.com/setup.pdf	2025-12-13 16:59:26.916	2025-12-13 16:59:26.916	1	3	Install required tools and configure your development environment.	http://localhost:8080/uploads/thumbnails/lesson_1765645166900.png	0	\N
4	Lesson 4: Basics Concepts	https://www.youtube.com/watch?v=abc003	\N	2025-12-13 16:59:26.951	2025-12-13 16:59:26.951	1	3	Learn the fundamental concepts required for this subject.	http://localhost:8080/uploads/thumbnails/lesson_1765645166929.png	0	\N
5	Lesson 5: First Practical Example	https://www.youtube.com/watch?v=abc004	\N	2025-12-13 16:59:26.985	2025-12-13 16:59:26.985	1	3	Build your first practical example step by step.	http://localhost:8080/uploads/thumbnails/lesson_1765645166962.png	0	\N
6	Lesson 6: Understanding the Workflow	\N	\N	2025-12-13 16:59:27.016	2025-12-13 16:59:27.016	1	3	Learn the complete workflow used in real-world projects.	http://localhost:8080/uploads/thumbnails/lesson_1765645166997.png	0	\N
7	Lesson 7: Common Mistakes	\N	\N	2025-12-13 16:59:27.065	2025-12-13 16:59:27.065	1	3	Avoid common beginner mistakes and learn best practices.	http://localhost:8080/uploads/thumbnails/lesson_1765645167030.png	0	\N
8	Lesson 8: Project Structure	\N	\N	2025-12-13 16:59:27.116	2025-12-13 16:59:27.116	1	3	Understand how to organize files and folders properly.	http://localhost:8080/uploads/thumbnails/lesson_1765645167102.png	0	\N
9	Lesson 9: Working with Data	\N	\N	2025-12-13 16:59:27.154	2025-12-13 16:59:27.154	1	3	Learn how to manage and process data efficiently.	http://localhost:8080/uploads/thumbnails/lesson_1765645167127.png	0	\N
10	Lesson 10: Intermediate Concepts	\N	\N	2025-12-13 16:59:27.193	2025-12-13 16:59:27.193	1	3	Move beyond basics and explore intermediate-level concepts.	http://localhost:8080/uploads/thumbnails/lesson_1765645167173.png	0	\N
11	Lesson 11: Debugging Techniques	\N	\N	2025-12-13 16:59:27.22	2025-12-13 16:59:27.22	1	3	Learn how to debug issues like a professional.	http://localhost:8080/uploads/thumbnails/lesson_1765645167201.png	0	\N
12	Lesson 12: Performance Optimization	\N	\N	2025-12-13 16:59:27.261	2025-12-13 16:59:27.261	1	3	Optimize performance and improve efficiency.	http://localhost:8080/uploads/thumbnails/lesson_1765645167232.png	0	\N
13	Lesson 13: Security Best Practices	\N	\N	2025-12-13 16:59:27.307	2025-12-13 16:59:27.307	1	3	Understand common security risks and how to prevent them.	http://localhost:8080/uploads/thumbnails/lesson_1765645167278.png	0	\N
14	Lesson 14: Mini Project	\N	\N	2025-12-13 16:59:27.359	2025-12-13 16:59:27.359	1	3	Apply what you’ve learned by building a mini project.	http://localhost:8080/uploads/thumbnails/lesson_1765645167323.png	0	\N
15	Lesson 15: Real-world Use Cases	\N	\N	2025-12-13 16:59:27.411	2025-12-13 16:59:27.411	1	3	Explore real-world applications of the concepts.	http://localhost:8080/uploads/thumbnails/lesson_1765645167377.png	0	\N
16	Lesson 16: Final Review & Next Steps	\N	\N	2025-12-13 16:59:27.533	2025-12-13 16:59:27.533	1	3	Summarize the course and learn what to do next.	http://localhost:8080/uploads/thumbnails/lesson_1765645167508.png	0	\N
17	 Lesson 17 : Introduction to Computers	https://www.youtube.com/watch?v=dQw4w9WgXcQ	https://example.com/resources/computer-intro.pdf	2025-12-13 19:12:32.822	2025-12-13 19:12:32.822	1	3	Learn about the history of computers, types of computers, and basic components like CPU, memory, and input/output devices.	http://localhost:8080/uploads/thumbnails/lesson_1765653152450.png	0	214
18	lesson 18	https://www.youtube.com/watch?v=enjkcCdAlXc&list=RDenjkcCdAlXc&start_radio=1	\N	2025-12-14 03:50:48.072	2025-12-14 03:50:48.072	1	3	this is lesson 18 	http://localhost:8080/uploads/thumbnails/lesson_1765684247534.png	0	240
19	hiii	https://www.youtube.com/watch?v=O5nskjZ_GoI	https://www.tutorialspoint.com/computer_fundamentals/computer_fundamentals.pdf	2025-12-14 04:10:38.542	2025-12-14 04:10:38.542	1	3	iiiii	http://localhost:8080/uploads/thumbnails/lesson_1765685438267.png	0	713
20	gdcv	https://www.youtube.com/watch?v=O5nskjZ_GoI	\N	2025-12-14 07:26:30.098	2025-12-14 07:26:30.098	1	3	zxcvgrf	http://localhost:8080/uploads/thumbnails/lesson_1765697189334.png	0	713
21	effDdc	https://www.youtube.com/watch?v=O5nskjZ_GoI	\N	2025-12-14 07:37:41.622	2025-12-14 07:37:41.622	1	3	fsdsdv 	http://localhost:8080/uploads/thumbnails/lesson_1765697860064.png	0	713
22	GSDVv	https://www.youtube.com/watch?v=O5nskjZ_GoI	\N	2025-12-14 08:13:17.471	2025-12-14 08:13:17.471	1	3	vcdfdf	http://localhost:8080/uploads/thumbnails/lesson_1765699997098.png	0	713
23	bjsdjsak	https://www.youtube.com/watch?v=O5nskjZ_GoI	https://www.w3.org/WAI/testfiles/docs/ComputerBasics.pdf	2025-12-17 10:36:21.111	2025-12-17 10:36:21.111	1	3	;nsadjkosia	http://localhost:8080/uploads/thumbnails/lesson_1765967780376.png	0	713
24	jschius	https://www.youtube.com/watch?v=O5nskjZ_GoI	\N	2025-12-17 10:48:10.352	2025-12-17 10:48:10.352	1	3	sjidhisa	http://localhost:8080/uploads/thumbnails/lesson_1765968488718.png	0	713
25	ddsjhbjds	https://www.youtube.com/watch?v=O5nskjZ_GoI	https://www.w3.org/WAI/testfiles/docs/ComputerBasics.pdf	2025-12-18 03:30:33.317	2025-12-18 03:30:33.317	2	3	 cxzhbsj	http://localhost:8080/uploads/thumbnails/lesson_1766028630920.png	0	713
26	jhdwuijds	https://www.youtube.com/watch?v=O5nskjZ_GoI	https://www.w3.org/WAI/testfiles/docs/ComputerBasics.pdf	2025-12-18 04:00:05.894	2025-12-18 04:00:05.894	2	3	bjisadhbuisja	http://localhost:8080/uploads/thumbnails/lesson_1766030405058.png	0	713
\.


--
-- Data for Name: LessonProgress; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."LessonProgress" (id, "studentId", "lessonId", "videoWatchedSeconds", "videoCompleted", "assignmentCompleted", "pdfViewed", completed, "updatedAt") FROM stdin;
2	4	17	214	t	t	t	t	2025-12-14 03:46:26.96
5	4	13	0	f	t	f	f	2025-12-14 03:47:32.098
6	4	16	0	f	t	f	f	2025-12-14 03:47:39.132
8	4	18	240	t	t	f	f	2025-12-14 03:51:15.127
12	4	20	713	t	f	f	f	2025-12-14 07:34:02.332
1	4	1	0	t	f	f	f	2025-12-14 08:18:11.518
13	4	21	713	t	t	f	f	2025-12-14 18:29:38.658
14	4	22	713	t	t	f	f	2025-12-14 19:17:41.665
11	4	19	713	t	f	t	f	2025-12-15 14:06:28.742
46	4	23	713	t	f	t	f	2025-12-17 10:39:41.111
58	4	26	713	t	t	t	f	2025-12-18 04:01:53.06
56	4	25	713	t	t	t	t	2025-12-18 04:03:08.557
\.


--
-- Data for Name: LiveClass; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."LiveClass" (id, "startTime", "endTime", "meetingUrl", "createdAt", "updatedAt", "subjectId", "teacherId") FROM stdin;
1	2025-12-26 07:53:00	2025-12-16 08:11:08.301		2025-12-16 07:53:23.439	2025-12-16 08:11:08.307	1	3
6	2025-12-24 09:27:00	\N	https://meet.google.com/jwi-yyaz-hyy	2025-12-16 09:27:19.541	2025-12-16 09:27:19.541	1	3
7	2025-12-26 09:27:00	\N	https://meet.google.com/jwi-yyaz-hyy	2025-12-16 09:27:34.879	2025-12-16 09:27:34.879	5	3
2	2025-12-16 09:16:00	2025-12-16 09:27:54.285	https://meet.google.com/byq-insu-ovj	2025-12-16 08:17:04.894	2025-12-16 09:27:54.287	1	3
3	2025-12-16 09:23:00	2025-12-16 09:29:38.841	https://meet.google.com/nwf-wfct-hti	2025-12-16 09:17:16.336	2025-12-16 09:29:38.842	1	3
4	2025-12-16 09:41:00	2025-12-16 10:11:18.248	https://meet.google.com/jwi-yyaz-hyy	2025-12-16 09:26:32.361	2025-12-16 10:11:18.25	1	3
10	2025-12-16 10:40:00	2025-12-16 16:55:15.783	https://meet.google.com/vsb-rvgb-aeb	2025-12-16 10:39:02.803	2025-12-16 16:55:15.787	2	3
12	2025-12-16 16:48:00	2025-12-16 16:55:16.997	https://meet.google.com/dmo-zbev-cmk	2025-12-16 16:44:56.088	2025-12-16 16:55:16.998	2	3
11	2025-12-16 16:49:00	2025-12-16 16:55:18.442	https://meet.google.com/dmo-zbev-cmk	2025-12-16 16:44:20.805	2025-12-16 16:55:18.443	10	3
13	2025-12-17 10:54:00	2025-12-17 11:04:22.433	https://meet.google.com/riy-bkbb-rck	2025-12-17 10:51:43.627	2025-12-17 11:04:22.434	1	3
14	2025-12-18 10:19:00	2025-12-18 17:07:36.233	https://meet.google.com/vow-orom-fbs	2025-12-18 10:15:23.324	2025-12-18 17:07:36.234	1	3
9	2025-12-18 10:37:00	2025-12-18 17:07:37.468	https://meet.google.com/vsb-rvgb-aeb	2025-12-16 10:38:11.3	2025-12-18 17:07:37.469	9	3
8	2025-12-18 09:29:00	2025-12-18 17:07:38.644	https://meet.google.com/jwi-yyaz-hyy	2025-12-16 09:29:33.815	2025-12-18 17:07:38.646	1	3
5	2025-12-18 09:26:00	2025-12-18 17:07:39.958	https://meet.google.com/jwi-yyaz-hyy	2025-12-16 09:26:49.576	2025-12-18 17:07:39.959	1	3
15	2025-12-18 17:43:00	2025-12-18 18:07:30.55	https://meet.google.com/ptr-wrqv-xmk	2025-12-18 17:41:38.109	2025-12-18 18:07:30.555	1	3
\.


--
-- Data for Name: Message; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Message" (id, content, "createdAt", "senderId", "receiverId") FROM stdin;
\.


--
-- Data for Name: Notification; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Notification" (id, message, "createdAt", "isRead", "userId") FROM stdin;
\.


--
-- Data for Name: Payment; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Payment" (id, amount, status, gateway, "transactionId", "paidAt", "createdAt", "studentId", "subjectId") FROM stdin;
\.


--
-- Data for Name: PaymentGatewaySettings; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."PaymentGatewaySettings" (id, service, wallet, "qrBaseUrl", "createdAt", "updatedAt") FROM stdin;
\.


--
-- Data for Name: PaymentRequest; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."PaymentRequest" (id, "txnId", "studentId", "subjectId", amount, status, "proofImage", "createdAt", "approvedAt") FROM stdin;
71	ENR-1765384985536-7212	4	2	2000	pending	\N	2025-12-10 16:43:05.538	\N
74	ENR-1765386013616-5489	4	7	799	approved	\N	2025-12-10 17:00:13.617	2025-12-10 17:52:18.209
70	ENR-1765384792375-7420	4	1	2200	pending	/uploads/payment-proofs/lms_lessons/lesson_1765389598739	2025-12-10 16:39:52.377	\N
72	ENR-1765385262826-8455	4	6	899	approved	\N	2025-12-10 16:47:42.829	2025-12-11 10:52:50.067
76	ENR-1765450569262-2646	4	3	599	pending	/uploads/payment-proofs/lms_lessons/lesson_1765450625279	2025-12-11 10:56:09.264	\N
77	ENR-1765535137106-4064	4	5	699	approved	https://res.cloudinary.com/dvck3axc5/image/upload/v1765535159/lms_lessons/lesson_1765535156650.png	2025-12-12 10:25:37.108	2025-12-12 18:12:05.644
78	ENR-1765567647396-3605	4	8	499	approved	https://res.cloudinary.com/dvck3axc5/image/upload/v1765567670/lms_lessons/lesson_1765567659690.png	2025-12-12 19:27:27.398	2025-12-12 19:28:20.791
73	ENR-1765385451157-3892	4	8	499	approved	/uploads/payment-proofs/lms_lessons/lesson_1765390023465	2025-12-10 16:50:51.159	2025-12-12 20:16:43.648
79	ENR-1765573102570-8334	5	8	499	approved	https://res.cloudinary.com/dvck3axc5/image/upload/v1765573113/lms_lessons/lesson_1765573113947.png	2025-12-12 20:58:22.572	2025-12-12 20:59:31.44
75	ENR-1765387625878-4313	4	11	999	rejected	\N	2025-12-10 17:27:05.881	2025-12-10 17:52:13.44
80	ENR-1765573723182-6429	4	4	599	rejected	\N	2025-12-12 21:08:43.185	\N
81	ENR-1765575878552-5086	4	10	799	pending	\N	2025-12-12 21:44:38.553	\N
82	ENR-1765575899275-2130	4	4	599	pending	\N	2025-12-12 21:44:59.276	\N
83	ENR-1765576167195-5046	4	9	1099	pending	\N	2025-12-12 21:49:27.197	\N
\.


--
-- Data for Name: Salary; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Salary" (id, amount, month, status, "createdAt", "teacherId") FROM stdin;
\.


--
-- Data for Name: Subject; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Subject" (id, title, description, price, "createdAt", "updatedAt", "teacherId") FROM stdin;
1	Computer	This is computer course	2200	2025-12-09 07:42:03.627	2025-12-09 07:42:03.627	3
2	Math	Math is number 1	2000	2025-12-09 08:57:26.187	2025-12-09 08:57:26.187	3
3	Python for Beginners	Start coding in Python with hands-on projects.	599	2025-12-09 08:58:50.07	2025-12-09 08:58:50.07	3
4	Python for Beginners	Start coding in Python with hands-on projects.	599	2025-12-09 09:00:27.251	2025-12-09 09:00:27.251	3
5	JavaScript Essentials	Learn JavaScript fundamentals and DOM manipulation.	699	2025-12-09 09:00:27.258	2025-12-09 09:00:27.258	3
6	React from Scratch	Build interactive UIs using React and hooks.	899	2025-12-09 09:00:27.261	2025-12-09 09:00:27.261	3
7	Node.js and Express	Create backend APIs with Node.js and Express framework.	799	2025-12-09 09:00:27.265	2025-12-09 09:00:27.265	3
8	HTML & CSS Mastery	Design responsive web pages with modern HTML and CSS.	499	2025-12-09 09:00:27.268	2025-12-09 09:00:27.268	3
9	Fullstack Web Development	Combine frontend and backend skills to build complete apps.	1099	2025-12-09 09:00:27.271	2025-12-09 09:00:27.271	3
10	Data Structures & Algorithms	Learn key data structures and algorithmic problem solving.	799	2025-12-09 09:00:27.274	2025-12-09 09:00:27.274	3
11	Python for Data Science	Analyze and visualize data using Python libraries.	999	2025-12-09 09:00:27.276	2025-12-09 09:00:27.276	3
12	Machine Learning Basics	Understand the fundamentals of machine learning and AI.	1299	2025-12-09 09:00:27.278	2025-12-09 09:00:27.278	3
13	Database Management with SQL	Learn to create, query, and manage relational databases.	699	2025-12-09 09:00:27.28	2025-12-09 09:00:27.28	3
14	OPT Maths	this is opt maths	2000	2025-12-09 09:01:16.519	2025-12-09 09:01:16.519	3
\.


--
-- Data for Name: Submission; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."Submission" (id, "fileUrl", marks, status, "assignmentId", "studentId", "submittedAt", feedback, "gradedAt") FROM stdin;
1	https://res.cloudinary.com/dvck3axc5/image/upload/v1765736976/lms_lessons/lesson_1765736963868.pdf	\N	submitted	1	4	2025-12-14 18:29:38.176	\N	\N
2	https://res.cloudinary.com/dvck3axc5/image/upload/v1765739859/lms_lessons/lesson_1765739856929.pdf	95	graded	2	4	2025-12-14 19:17:41.308	good job	\N
3	https://res.cloudinary.com/dvck3axc5/image/upload/v1765817001/lms_lessons/lesson_1765816999652.pdf	87	graded	3	4	2025-12-15 16:43:23.725	good job prepare more and try to cross 90	\N
4	https://res.cloudinary.com/dvck3axc5/image/upload/v1765968094/lms_lessons/lesson_1765968094847.pdf	95	graded	5	4	2025-12-17 10:41:39.269	good job	\N
5	https://res.cloudinary.com/dvck3axc5/image/upload/v1765968570/lms_lessons/lesson_1765968569221.pdf	\N	submitted	6	4	2025-12-17 10:49:34.841	\N	\N
6	https://res.cloudinary.com/dvck3axc5/image/upload/v1766028717/lms_lessons/lesson_1766028717879.pdf	\N	submitted	7	4	2025-12-18 03:32:03.126	\N	\N
7	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029033/lms_lessons/lesson_1766029033169.pdf	\N	submitted	8	4	2025-12-18 03:37:18.024	\N	\N
8	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029208/lms_lessons/lesson_1766029209122.pdf	\N	submitted	9	4	2025-12-18 03:40:13.902	\N	\N
9	https://res.cloudinary.com/dvck3axc5/image/upload/v1766029360/lms_lessons/lesson_1766029361585.pdf	\N	submitted	11	4	2025-12-18 03:42:45.386	\N	\N
10	https://res.cloudinary.com/dvck3axc5/image/upload/v1766030507/lms_lessons/lesson_1766030508391.pdf	70	graded	12	4	2025-12-18 04:01:53.038	work hard	\N
\.


--
-- Data for Name: User; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public."User" (id, "firstName", "lastName", email, phone, password, role, status, "createdAt", "updatedAt", "resetToken", "resetTokenExpiry", "refreshToken", "refreshTokenExpiresAt", "esewaNumber", "lastLogin", "lastActivity") FROM stdin;
4	Baskota	Anup	baskotanup@gmail.com	(+977) 9862773203	$2b$10$0Jt3V6aBw2SdFOFrXmEBwOaIfvG1Up3fqtmi.2RAd31Gh2./.Mi7K	student	approved	2025-12-09 07:39:05.572	2025-12-18 16:55:00.825	\N	\N	\N	\N	\N	2025-12-18 10:41:12.307	2025-12-18 16:55:00.82
5	Deepak	Gajamer	gajamerdipak19@gmail.com	9876543210	$2b$10$sM306ONYk8e8j1TVEJXDEOaQjUfkt0iB/blNrjLQI1E5t1KQg1YOS	teacher	approved	2025-12-11 10:43:04.456	2025-12-16 16:15:30.28	\N	\N	\N	\N	\N	2025-12-16 16:15:13.734	2025-12-16 16:15:30.278
2	LMS	Admin	admin@lms.com	+9779812345678	$2b$10$ELzvSOF1Ap3Bq85UiygWK.hCLlh/zWULIgH9C15Ij6cRu5X0oCrjq	admin	approved	2025-12-09 07:06:44.939	2025-12-18 04:12:21.296	\N	\N	\N	\N	9862773203	2025-12-18 04:03:31.553	2025-12-18 04:12:21.294
3	Anup	Banskota	baskotanoop@gmail.com	9876543210	$2b$10$V5/jwj95/ogSzpaK0eZKkO6KtPJAimzHtnSgP821u.UyjnxsAtBUK	teacher	approved	2025-12-09 07:38:20.689	2025-12-18 18:07:34.327	\N	\N	\N	\N	\N	2025-12-18 10:01:05.435	2025-12-18 18:07:34.325
\.


--
-- Data for Name: _prisma_migrations; Type: TABLE DATA; Schema: public; Owner: Anup
--

COPY public._prisma_migrations (id, checksum, finished_at, migration_name, logs, rolled_back_at, started_at, applied_steps_count) FROM stdin;
111dbc74-bece-454d-8ac8-8d1c0cae0681	fc8b11d9dd6b6897900ce1a7ca08107a576026a20719337be80722d31f283147	2025-12-09 12:36:15.585905+05:45	20251117071759_init	\N	\N	2025-12-09 12:36:15.504641+05:45	1
e1e00050-fe26-49b8-8378-dce2b1c3bf20	fb2361b2676a65d10b82e22d1545e6d12e174765dbd802a799aa61e3436a5498	2025-12-09 12:36:15.589299+05:45	20251118141837_add_price_to_subject	\N	\N	2025-12-09 12:36:15.58655+05:45	1
3a5f15e6-786f-4cd7-bdd5-cae8abd4167d	c46c137a59b072820e30d90925350924766b7a3529a7b1093db12165a198f0f4	2025-12-10 12:42:36.792705+05:45	20251210065736_add_esewa_number	\N	\N	2025-12-10 12:42:36.779978+05:45	1
ea5ee4dc-23cd-451f-b1bf-508765aaafea	79a9957bbfbe5ea605e6d047d7764cc863944c42846f0e0edec89c4a76f9d737	2025-12-09 12:36:15.592079+05:45	20251119145314_add_lesson_description	\N	\N	2025-12-09 12:36:15.589858+05:45	1
87df9dd5-e9d5-41f4-81bc-d9732f4d0f4a	6c5b301a872eab041d637b5fc7b5b988d8b88a9f63a36115dd3693d4a2d11c64	2025-12-09 12:36:15.594988+05:45	20251119172133_change_submission	\N	\N	2025-12-09 12:36:15.592594+05:45	1
299677e3-9a1b-4865-bde2-4971a69e104d	d70a69ee76f43eed4deed495d98faa2755f05cd4a5b8190db1c7a5bbc441e5e0	2025-12-09 12:36:15.597389+05:45	20251123161251_add_cash_on_gateway	\N	\N	2025-12-09 12:36:15.595494+05:45	1
af285738-1344-4928-b7f2-d17c6ab4c347	6df650a601467be6c2805570a42dfb08555b6b4f9d8431ebba3200883042f217	2025-12-13 00:51:54.991065+05:45	20251212190654_add_last_login_to_user	\N	\N	2025-12-13 00:51:54.986391+05:45	1
43f27a4e-c015-423e-b87e-d1bc2e42962a	6d11206a01b84bb72899156b5f209133cda11a4255ea9f0a8bbb87351b476113	2025-12-09 12:36:15.605943+05:45	20251127165147_contact_message	\N	\N	2025-12-09 12:36:15.598159+05:45	1
da7a69d0-6177-469b-8661-f9a0616fff4c	c70557eb98fd9e69d3b46a594c44870eec38ecc6c5cd70bce9bf7e01d51c4cee	2025-12-09 12:36:15.610978+05:45	20251128184727_add_reset_token_fields	\N	\N	2025-12-09 12:36:15.606586+05:45	1
144f5ddc-7323-4710-9daa-8d13690e69fb	cb6fa32be268bddea90192b1bdd830dd36d2044563dde55fb82677df8ca3d705	2025-12-09 12:36:15.613902+05:45	20251128191153_add_refresh_token_fields	\N	\N	2025-12-09 12:36:15.611537+05:45	1
7c87fba9-7a44-4629-961d-57b38432f91e	ab076ef3936b4c0a2230a38146201a7c7f281b683a6147f81b178f182cf806fe	2025-12-13 01:01:42.200994+05:45	20251212191642_add_last_activity_to_user	\N	\N	2025-12-13 01:01:42.195184+05:45	1
480d0a5d-0589-47e2-8869-fb0082a7f813	b65c3c8862971c78ecc0ab334c37d4db41a24e9b9241de96768b3a51bcf4e28e	2025-12-09 12:36:15.618005+05:45	20251208055855_add_thumbnail_url_to_lesson	\N	\N	2025-12-09 12:36:15.614625+05:45	1
61fb8b47-650e-41b4-8d38-df1c49b57cbd	5c0bb8417c90baf9e4e3ee8555dced5199fba795b2079923e3f8676fea329213	2025-12-09 12:36:15.624206+05:45	20251208094611_add_lesson_assignments	\N	\N	2025-12-09 12:36:15.618489+05:45	1
00b9ff43-0956-4e9b-8574-ae3530508afb	f471a7cfee8f5c51717d9f8af6e58f00ec7a2999d84419f622afb0e2710d9493	2025-12-09 12:36:53.294299+05:45	20251209065153_init_schema	\N	\N	2025-12-09 12:36:53.274507+05:45	1
0178fa47-f908-4dc6-a664-e6742b93140e	da46f46f01745ca1dc7a4e6b68461976212a6005e59428f1120a0aaf0a4ba35b	2025-12-13 23:17:59.406713+05:45	20251213173259_add_lesson_progress_fields	\N	\N	2025-12-13 23:17:59.375816+05:45	1
73f9558c-57fc-46ed-b91b-f0233d8c0e32	34db15a6de7eaa43381b4b886a00e341c1f553f2ed5bb4afd51a8fae86f3740d	2025-12-09 12:40:24.394123+05:45	20251209065524_add_enrollment_payment	\N	\N	2025-12-09 12:40:24.372676+05:45	1
76edd791-0209-46b5-b516-e6cf661d1b4a	758b4c232e168a124b5a1fb3ab16b8c7b5153b9bf462599fb4908319eaa4dd12	2025-12-10 12:34:31.001071+05:45	20251210064930_add_payment_gateway_settings	\N	\N	2025-12-10 12:34:30.952164+05:45	1
2c144f3b-1ffe-4d9a-87d9-eb1f676b62fd	77207413cc847debb1e73f7368ecddb0bb7e5ba358fd5ea4f3df09adeb6f71b7	2025-12-14 00:37:12.0459+05:45	20251213185212_add_viseo_duration_fields	\N	\N	2025-12-14 00:37:12.040636+05:45	1
\.


--
-- Name: Assignment_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Assignment_id_seq"', 13, true);


--
-- Name: Attendance_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Attendance_id_seq"', 23, true);


--
-- Name: ContactMessage_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."ContactMessage_id_seq"', 1, false);


--
-- Name: Enrollment_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Enrollment_id_seq"', 15, true);


--
-- Name: LessonProgress_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."LessonProgress_id_seq"', 68, true);


--
-- Name: Lesson_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Lesson_id_seq"', 26, true);


--
-- Name: LiveClass_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."LiveClass_id_seq"', 15, true);


--
-- Name: Message_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Message_id_seq"', 1, false);


--
-- Name: Notification_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Notification_id_seq"', 1, false);


--
-- Name: PaymentGatewaySettings_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."PaymentGatewaySettings_id_seq"', 1, false);


--
-- Name: PaymentRequest_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."PaymentRequest_id_seq"', 83, true);


--
-- Name: Payment_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Payment_id_seq"', 1, false);


--
-- Name: Salary_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Salary_id_seq"', 1, false);


--
-- Name: Subject_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Subject_id_seq"', 14, true);


--
-- Name: Submission_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."Submission_id_seq"', 10, true);


--
-- Name: User_id_seq; Type: SEQUENCE SET; Schema: public; Owner: Anup
--

SELECT pg_catalog.setval('public."User_id_seq"', 5, true);


--
-- Name: Assignment Assignment_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Assignment"
    ADD CONSTRAINT "Assignment_pkey" PRIMARY KEY (id);


--
-- Name: Attendance Attendance_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Attendance"
    ADD CONSTRAINT "Attendance_pkey" PRIMARY KEY (id);


--
-- Name: ContactMessage ContactMessage_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."ContactMessage"
    ADD CONSTRAINT "ContactMessage_pkey" PRIMARY KEY (id);


--
-- Name: Enrollment Enrollment_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Enrollment"
    ADD CONSTRAINT "Enrollment_pkey" PRIMARY KEY (id);


--
-- Name: LessonProgress LessonProgress_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LessonProgress"
    ADD CONSTRAINT "LessonProgress_pkey" PRIMARY KEY (id);


--
-- Name: Lesson Lesson_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Lesson"
    ADD CONSTRAINT "Lesson_pkey" PRIMARY KEY (id);


--
-- Name: LiveClass LiveClass_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LiveClass"
    ADD CONSTRAINT "LiveClass_pkey" PRIMARY KEY (id);


--
-- Name: Message Message_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Message"
    ADD CONSTRAINT "Message_pkey" PRIMARY KEY (id);


--
-- Name: Notification Notification_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Notification"
    ADD CONSTRAINT "Notification_pkey" PRIMARY KEY (id);


--
-- Name: PaymentGatewaySettings PaymentGatewaySettings_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."PaymentGatewaySettings"
    ADD CONSTRAINT "PaymentGatewaySettings_pkey" PRIMARY KEY (id);


--
-- Name: PaymentRequest PaymentRequest_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."PaymentRequest"
    ADD CONSTRAINT "PaymentRequest_pkey" PRIMARY KEY (id);


--
-- Name: Payment Payment_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Payment"
    ADD CONSTRAINT "Payment_pkey" PRIMARY KEY (id);


--
-- Name: Salary Salary_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Salary"
    ADD CONSTRAINT "Salary_pkey" PRIMARY KEY (id);


--
-- Name: Subject Subject_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Subject"
    ADD CONSTRAINT "Subject_pkey" PRIMARY KEY (id);


--
-- Name: Submission Submission_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Submission"
    ADD CONSTRAINT "Submission_pkey" PRIMARY KEY (id);


--
-- Name: User User_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."User"
    ADD CONSTRAINT "User_pkey" PRIMARY KEY (id);


--
-- Name: _prisma_migrations _prisma_migrations_pkey; Type: CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public._prisma_migrations
    ADD CONSTRAINT _prisma_migrations_pkey PRIMARY KEY (id);


--
-- Name: Enrollment_studentId_subjectId_key; Type: INDEX; Schema: public; Owner: Anup
--

CREATE UNIQUE INDEX "Enrollment_studentId_subjectId_key" ON public."Enrollment" USING btree ("studentId", "subjectId");


--
-- Name: LessonProgress_studentId_lessonId_key; Type: INDEX; Schema: public; Owner: Anup
--

CREATE UNIQUE INDEX "LessonProgress_studentId_lessonId_key" ON public."LessonProgress" USING btree ("studentId", "lessonId");


--
-- Name: PaymentRequest_txnId_key; Type: INDEX; Schema: public; Owner: Anup
--

CREATE UNIQUE INDEX "PaymentRequest_txnId_key" ON public."PaymentRequest" USING btree ("txnId");


--
-- Name: User_email_key; Type: INDEX; Schema: public; Owner: Anup
--

CREATE UNIQUE INDEX "User_email_key" ON public."User" USING btree (email);


--
-- Name: Assignment Assignment_lessonId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Assignment"
    ADD CONSTRAINT "Assignment_lessonId_fkey" FOREIGN KEY ("lessonId") REFERENCES public."Lesson"(id) ON UPDATE CASCADE ON DELETE SET NULL;


--
-- Name: Assignment Assignment_subjectId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Assignment"
    ADD CONSTRAINT "Assignment_subjectId_fkey" FOREIGN KEY ("subjectId") REFERENCES public."Subject"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Assignment Assignment_teacherId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Assignment"
    ADD CONSTRAINT "Assignment_teacherId_fkey" FOREIGN KEY ("teacherId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Attendance Attendance_classId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Attendance"
    ADD CONSTRAINT "Attendance_classId_fkey" FOREIGN KEY ("classId") REFERENCES public."LiveClass"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Attendance Attendance_studentId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Attendance"
    ADD CONSTRAINT "Attendance_studentId_fkey" FOREIGN KEY ("studentId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Enrollment Enrollment_studentId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Enrollment"
    ADD CONSTRAINT "Enrollment_studentId_fkey" FOREIGN KEY ("studentId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Enrollment Enrollment_subjectId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Enrollment"
    ADD CONSTRAINT "Enrollment_subjectId_fkey" FOREIGN KEY ("subjectId") REFERENCES public."Subject"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: LessonProgress LessonProgress_lessonId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LessonProgress"
    ADD CONSTRAINT "LessonProgress_lessonId_fkey" FOREIGN KEY ("lessonId") REFERENCES public."Lesson"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: LessonProgress LessonProgress_studentId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LessonProgress"
    ADD CONSTRAINT "LessonProgress_studentId_fkey" FOREIGN KEY ("studentId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Lesson Lesson_subjectId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Lesson"
    ADD CONSTRAINT "Lesson_subjectId_fkey" FOREIGN KEY ("subjectId") REFERENCES public."Subject"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Lesson Lesson_teacherId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Lesson"
    ADD CONSTRAINT "Lesson_teacherId_fkey" FOREIGN KEY ("teacherId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: LiveClass LiveClass_subjectId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LiveClass"
    ADD CONSTRAINT "LiveClass_subjectId_fkey" FOREIGN KEY ("subjectId") REFERENCES public."Subject"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: LiveClass LiveClass_teacherId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."LiveClass"
    ADD CONSTRAINT "LiveClass_teacherId_fkey" FOREIGN KEY ("teacherId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Message Message_receiverId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Message"
    ADD CONSTRAINT "Message_receiverId_fkey" FOREIGN KEY ("receiverId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Message Message_senderId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Message"
    ADD CONSTRAINT "Message_senderId_fkey" FOREIGN KEY ("senderId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Notification Notification_userId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Notification"
    ADD CONSTRAINT "Notification_userId_fkey" FOREIGN KEY ("userId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Payment Payment_studentId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Payment"
    ADD CONSTRAINT "Payment_studentId_fkey" FOREIGN KEY ("studentId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Payment Payment_subjectId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Payment"
    ADD CONSTRAINT "Payment_subjectId_fkey" FOREIGN KEY ("subjectId") REFERENCES public."Subject"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Salary Salary_teacherId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Salary"
    ADD CONSTRAINT "Salary_teacherId_fkey" FOREIGN KEY ("teacherId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Subject Subject_teacherId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Subject"
    ADD CONSTRAINT "Subject_teacherId_fkey" FOREIGN KEY ("teacherId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Submission Submission_assignmentId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Submission"
    ADD CONSTRAINT "Submission_assignmentId_fkey" FOREIGN KEY ("assignmentId") REFERENCES public."Assignment"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: Submission Submission_studentId_fkey; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."Submission"
    ADD CONSTRAINT "Submission_studentId_fkey" FOREIGN KEY ("studentId") REFERENCES public."User"(id) ON UPDATE CASCADE ON DELETE RESTRICT;


--
-- Name: PaymentRequest fk_student; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."PaymentRequest"
    ADD CONSTRAINT fk_student FOREIGN KEY ("studentId") REFERENCES public."User"(id);


--
-- Name: PaymentRequest fk_subject; Type: FK CONSTRAINT; Schema: public; Owner: Anup
--

ALTER TABLE ONLY public."PaymentRequest"
    ADD CONSTRAINT fk_subject FOREIGN KEY ("subjectId") REFERENCES public."Subject"(id);


--
-- Name: SCHEMA public; Type: ACL; Schema: -; Owner: Anup
--

REVOKE USAGE ON SCHEMA public FROM PUBLIC;


--
-- PostgreSQL database dump complete
--

