├── .gitattributes ├── .gitignore ├── README.md ├── e-learning ├── .gitattributes ├── .gitignore ├── .prettierrc ├── package-lock.json ├── package.json ├── public │ ├── favicon.ico │ ├── index.html │ ├── logo192.png │ ├── logo512.png │ ├── manifest.json │ └── robots.txt └── src │ ├── App.js │ ├── ColorModeSwitcher.js │ ├── assets │ ├── docs │ │ └── termsAndCondition.js │ ├── images │ │ ├── CBR.jpg │ │ ├── Cloudinary.png │ │ ├── Render.png │ │ ├── bg.png │ │ ├── cursor.png │ │ ├── icon.png │ │ ├── logo.png │ │ ├── mailtrap.png │ │ └── razorpay.png │ └── videos │ │ └── intro.mp4 │ ├── components │ ├── About │ │ └── About.jsx │ ├── Admin │ │ ├── AdminCourses │ │ │ ├── AdminCourses.jsx │ │ │ └── CourseModal.jsx │ │ ├── CreateCourse │ │ │ └── CreateCourse.jsx │ │ ├── Dashboard │ │ │ ├── Chart.jsx │ │ │ └── Dashboard.jsx │ │ ├── Sidebar.jsx │ │ └── Users │ │ │ └── Users.jsx │ ├── Auth │ │ ├── ForgetPassword.jsx │ │ ├── Login.jsx │ │ ├── Register.jsx │ │ └── ResetPassword.jsx │ ├── Contact │ │ └── Contact.jsx │ ├── CoursePage │ │ └── CoursePage.jsx │ ├── Courses │ │ ├── Courses.jsx │ │ └── RecommendedCourses.jsx │ ├── Home │ │ ├── Home.jsx │ │ └── home.css │ ├── Layout │ │ ├── Footer │ │ │ └── Footer.jsx │ │ ├── Header │ │ │ └── Header.jsx │ │ ├── Loader │ │ │ └── Loader.jsx │ │ └── NotFound │ │ │ └── NotFound.jsx │ ├── Payments │ │ ├── PaymentFail.jsx │ │ ├── PaymentSuccess.jsx │ │ └── Subscribe.jsx │ ├── Profile │ │ ├── ChangePassword.jsx │ │ ├── Profile.jsx │ │ └── UpdateProfile.jsx │ └── Request │ │ └── Request.jsx │ ├── index.js │ └── redux │ ├── actions │ ├── admin.js │ ├── course.js │ ├── other.js │ ├── profile.js │ ├── recommendedCourse.js │ └── user.js │ ├── reducers │ ├── adminReducer.js │ ├── courseReducer.js │ ├── otherReducer.js │ ├── recommendedCourseReducer.js │ └── userReducer.js │ └── store.js └── e-learningserver ├── app.js ├── config └── database.js ├── controllers ├── courseController.js ├── otherController.js ├── paymentController.js ├── recommendationController.js └── userController.js ├── middlewares ├── Error.js ├── auth.js ├── catchAsyncError.js └── multer.js ├── models ├── Course.js ├── Payment.js ├── Stats.js └── User.js ├── package-lock.json ├── package.json ├── routes ├── courseRoutes.js ├── otherRoutes.js ├── paymentRoutes.js └── userRoutes.js ├── server.js └── utils ├── dataUri.js ├── errorHandler.js ├── sendEmail.js └── sendToken.js /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /e-learning/node_modules 5 | /e-learningserver/node_modules 6 | /.pnp 7 | .pnp.js 8 | 9 | # testing 10 | /coverage 11 | 12 | # production 13 | /build 14 | 15 | # misc 16 | /e-learningserver/config/config.env 17 | .DS_Store 18 | .env.local 19 | .env.development.local 20 | .env.test.local 21 | .env.production.local 22 | 23 | npm-debug.log* 24 | yarn-debug.log* 25 | yarn-error.log* 26 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | # 📢 E-Learning Emoji 3 | 4 | 5 | 6 | Emoji 7 | 8 | This is a **MERN** stack Subscription based Online Learning Platform with content based recommendation system. 9 | 10 | [Project Demo Video Link](https://drive.google.com/file/d/18vreMcZctCm2B5kgurNnIZDMwJrNGuz8/view?usp=sharing) 11 | 12 |
13 |
14 | 15 | # 🛠️ Tech stack 16 | 17 | ## Frontend : 18 | 19 | ![reactjs](https://img.shields.io/badge/React-20232A?style=for-the-badge&logo=react&logoColor=61DAFB) ![redux](https://img.shields.io/badge/Redux-593D88?style=for-the-badge&logo=redux&logoColor=white) ![Chakra](https://img.shields.io/badge/chakra-%234ED1C5.svg?style=for-the-badge&logo=chakraui&logoColor=white)![Chart.js](https://img.shields.io/badge/chart.js-F5788D.svg?style=for-the-badge&logo=chart.js&logoColor=white) 20 | 21 | 22 | ## Backend : 23 | 24 | ![nodejs](https://img.shields.io/badge/Node.js-43853D?style=for-the-badge&logo=node.js&logoColor=white) ![expressjs](https://img.shields.io/badge/Express.js-000000?style=for-the-badge&logo=express&logoColor=white) ![mongodb](https://img.shields.io/badge/MongoDB-4EA94B?style=for-the-badge&logo=mongodb&logoColor=white) ![jwt](https://img.shields.io/badge/JWT-000000?style=for-the-badge&logo=JSON%20web%20tokens&logoColor=white) 25 | 26 | Content-based Recommender System 27 | MailTrap 28 | 29 | ## Media Management : 30 | 31 | Cloudinary 32 | 33 | ## Payment Management : 34 | 35 | Razorpay 36 | 37 | ## Deployed On : 38 | 39 | Render 40 | 41 |
42 |
43 | 44 | # 🚀 Features 45 | 46 | ## Any User 47 | 48 | - can search courses with title and filter it with categories. 49 | - can see the top recommended course's title. 50 | - can request course and contact us for feedbacks. 51 | - Register themselves with name, email, password and avatar. 52 | 53 | ## Registered User 54 | 55 | - Can reset their password via mail by selecting forget password and entering their email. 56 | - Can Log in to website. 57 | 58 | ## Logged-In User 59 | 60 | - Can change their profile info or password. 61 | - Can add or remove courses from their playlist. 62 | - can see the top recommended course's title according to their playlist. 63 | - Can subscribe (by making payment of Rs 299) to the website for accessing any courses. 64 | - Can logout. 65 | 66 | ## Subscribed User 67 | 68 | - Can access any courses and watch their lectures. 69 | - Can cancel the subscription before 7 days. 70 | 71 | ## Admin User 72 | 73 | - Can has access to Admin dashboard and analyze the stats of everything in real time. 74 | - Can create courses, watch any course's lectures, add or delete lectures in Courses, and delete any courses. 75 | - Can change the user role and delete any user. 76 | 77 | -------------------------------------------------------------------------------- /e-learning/.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /e-learning/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | # misc 15 | .DS_Store 16 | .env.local 17 | .env.development.local 18 | .env.test.local 19 | .env.production.local 20 | 21 | npm-debug.log* 22 | yarn-debug.log* 23 | yarn-error.log* 24 | -------------------------------------------------------------------------------- /e-learning/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "arrowParens": "avoid", 3 | "trailingComma": "es5", 4 | "singleQuote": true, 5 | "semi": true 6 | } 7 | -------------------------------------------------------------------------------- /e-learning/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "e-learning", 3 | "version": "0.1.0", 4 | "private": true, 5 | "dependencies": { 6 | "@chakra-ui/react": "^2.4.8", 7 | "@emotion/react": "^11.10.5", 8 | "@emotion/styled": "^11.10.5", 9 | "@reduxjs/toolkit": "^1.9.1", 10 | "@testing-library/jest-dom": "^5.16.5", 11 | "@testing-library/react": "^13.4.0", 12 | "@testing-library/user-event": "^14.4.3", 13 | "axios": "^1.2.2", 14 | "chart.js": "^4.1.2", 15 | "framer-motion": "^6.5.1", 16 | "protected-route-react": "^1.0.1", 17 | "react": "^18.2.0", 18 | "react-chartjs-2": "^5.2.0", 19 | "react-dom": "^18.2.0", 20 | "react-hot-toast": "^2.4.0", 21 | "react-icons": "^3.11.0", 22 | "react-redux": "^8.0.5", 23 | "react-router-dom": "^6.6.2", 24 | "react-scripts": "5.0.1", 25 | "web-vitals": "^2.1.4" 26 | }, 27 | "scripts": { 28 | "start": "react-scripts start", 29 | "build": "react-scripts build", 30 | "test": "react-scripts test", 31 | "eject": "react-scripts eject" 32 | }, 33 | "eslintConfig": { 34 | "extends": "react-app" 35 | }, 36 | "browserslist": { 37 | "production": [ 38 | ">0.2%", 39 | "not dead", 40 | "not op_mini all" 41 | ], 42 | "development": [ 43 | "last 1 chrome version", 44 | "last 1 firefox version", 45 | "last 1 safari version" 46 | ] 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /e-learning/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mananghetia/E-Learning/2a440e9e56b1b030c7e0e05af528ba0704f16ef4/e-learning/public/favicon.ico -------------------------------------------------------------------------------- /e-learning/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 15 | 16 | 25 | E-Learning 26 | 27 | 28 | 29 | 30 |
31 | 41 | 42 | 43 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /e-learning/public/logo192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mananghetia/E-Learning/2a440e9e56b1b030c7e0e05af528ba0704f16ef4/e-learning/public/logo192.png -------------------------------------------------------------------------------- /e-learning/public/logo512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mananghetia/E-Learning/2a440e9e56b1b030c7e0e05af528ba0704f16ef4/e-learning/public/logo512.png -------------------------------------------------------------------------------- /e-learning/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | }, 10 | { 11 | "src": "logo192.png", 12 | "type": "image/png", 13 | "sizes": "192x192" 14 | }, 15 | { 16 | "src": "logo512.png", 17 | "type": "image/png", 18 | "sizes": "512x512" 19 | } 20 | ], 21 | "start_url": ".", 22 | "display": "standalone", 23 | "theme_color": "#000000", 24 | "background_color": "#ffffff" 25 | } 26 | -------------------------------------------------------------------------------- /e-learning/public/robots.txt: -------------------------------------------------------------------------------- 1 | # https://www.robotstxt.org/robotstxt.html 2 | User-agent: * 3 | Disallow: 4 | -------------------------------------------------------------------------------- /e-learning/src/App.js: -------------------------------------------------------------------------------- 1 | import React, { useEffect } from 'react'; 2 | import { BrowserRouter as Router, Route, Routes } from 'react-router-dom'; 3 | import ForgetPassword from './components/Auth/ForgetPassword'; 4 | import Login from './components/Auth/Login'; 5 | import Register from './components/Auth/Register'; 6 | import ResetPassword from './components/Auth/ResetPassword'; 7 | import Contact from './components/Contact/Contact'; 8 | import Courses from './components/Courses/Courses'; 9 | import Home from './components/Home/Home'; 10 | import Footer from './components/Layout/Footer/Footer'; 11 | import Header from './components/Layout/Header/Header'; 12 | import Request from './components/Request/Request'; 13 | import About from './components/About/About'; 14 | import Subscribe from './components/Payments/Subscribe'; 15 | import PaymentFail from './components/Payments/PaymentFail'; 16 | import PaymentSuccess from './components/Payments/PaymentSuccess'; 17 | import NotFound from './components/Layout/NotFound/NotFound'; 18 | import CoursePage from './components/CoursePage/CoursePage'; 19 | import Profile from './components/Profile/Profile'; 20 | import ChangePassword from './components/Profile/ChangePassword'; 21 | import UpdateProfile from './components/Profile/UpdateProfile'; 22 | import Dashboard from './components/Admin/Dashboard/Dashboard'; 23 | import CreateCourse from './components/Admin/CreateCourse/CreateCourse'; 24 | import AdminCourses from './components/Admin/AdminCourses/AdminCourses'; 25 | import Users from './components/Admin/Users/Users'; 26 | import { useDispatch, useSelector } from 'react-redux'; 27 | import toast, { Toaster } from 'react-hot-toast'; 28 | import { loadUser } from './redux/actions/user'; 29 | import { ProtectedRoute } from 'protected-route-react'; 30 | import Loader from './components/Layout/Loader/Loader'; 31 | import RecommendedCourses from './components/Courses/RecommendedCourses'; 32 | 33 | function App() { 34 | // window.addEventListener('contextmenu', e => { 35 | // e.preventDefault(); 36 | // }); 37 | 38 | const { isAuthenticated, user, message, error, loading } = useSelector( 39 | state => state.user 40 | ); 41 | 42 | const dispatch = useDispatch(); 43 | useEffect(() => { 44 | if (error) { 45 | toast.error(error); 46 | dispatch({ type: 'clearError' }); 47 | } 48 | 49 | if (message) { 50 | toast.success(message); 51 | dispatch({ type: 'clearMessage' }); 52 | } 53 | }, [dispatch, error, message]); 54 | 55 | useEffect(() => { 56 | dispatch(loadUser()); 57 | }, [dispatch]); 58 | 59 | return ( 60 | 61 | {loading ? ( 62 | 63 | ) : ( 64 | <> 65 |
66 | 67 | } /> 68 | } /> 69 | } /> 70 | 71 | 75 | 76 | 77 | } 78 | /> 79 | 80 | } /> 81 | } /> 82 | } /> 83 | 84 | 88 | 89 | 90 | } 91 | /> 92 | 96 | 97 | 98 | } 99 | /> 100 | 104 | 105 | 106 | } 107 | /> 108 | 109 | 116 | 117 | 118 | } 119 | /> 120 | 127 | 128 | 129 | } 130 | /> 131 | 138 | 139 | 140 | } 141 | /> 142 | 143 | 150 | 151 | 152 | } 153 | /> 154 | 155 | 159 | 160 | 161 | } 162 | /> 163 | 164 | } /> 165 | 166 | } /> 167 | 168 | } /> 169 | 170 | {/* Admin Routes */} 171 | 179 | 180 | 181 | } 182 | /> 183 | 191 | 192 | 193 | } 194 | /> 195 | 203 | 204 | 205 | } 206 | /> 207 | 215 | 216 | 217 | } 218 | /> 219 | 220 | 221 |