Skip to content

a basic user management system using Node.js, Express, Express-EJS and MongoDB.

Notifications You must be signed in to change notification settings

Rohit-Bhetal/userMGMTSys

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

USERMGMTSYS

► A simple and efficient user management system using Node.js, Express, Express-EJS, and MongoDB

license last-commit repo-top-language repo-language-count

Developed with the software and tools below.

JavaScript Nodemon Express JSON


🔗 Quick Links


📍 Overview

This is a basic user management system built using Node.js, Express, Express-EJS, and MongoDB. The project allows for adding, viewing, editing, and deleting users. Additionally, it features search functionality and an about page.

Deployed Site: usermgmtsys.onrender.com


📦 Features

Features of the user management system include:

  • Add, view, edit, and delete user information
  • Search functionality to find users
  • User-friendly interface with EJS templating
  • Simple routing and controller setup

📂 Repository Structure

└── userMGMTSys/
    ├── README.md
    ├── app.js
    ├── package-lock.json
    ├── package.json
    ├── public
    │   └── css
    │       └── main.css
    ├── server
    │   ├── config
    │   │   └── db.js
    │   ├── controller
    │   │   └── customerController.js
    │   ├── model
    │   │   └── Customer.js
    │   └── routes
    │       └── customer.js
    └── views
        ├── 404.ejs
        ├── about.ejs
        ├── index.ejs
        ├── layouts
        │   └── main.ejs
        ├── pages
        │   ├── add.ejs
        │   ├── edit.ejs
        │   └── view.ejs
        ├── partials
        │   ├── header.ejs
        │   └── sidebar.ejs
        └── search.ejs

🧩 Modules

package.json
File Summary
package.json Contains project dependencies and scripts for running the application.
app.js
File Summary
app.js Main entry point for the application, setting up Express server and routes.
server.controller
File Summary
customerController.js Contains controller logic for handling user-related operations like add, edit, view, and delete.
server.model
File Summary
Customer.js MongoDB model schema for the user data.
server.routes
File Summary
customer.js Defines the routes for user management functionalities such as add, view, edit, and delete.
server.config
File Summary
db.js Sets up the MongoDB connection for the application.
public.css
File Summary
main.css Contains custom CSS for styling the application.
views
File Summary
index.ejs Home page template displaying the list of users.
search.ejs Template for the search results.
404.ejs 404 error page template.
about.ejs About page template.
views.partials
File Summary
header.ejs Partial template for the header section.
sidebar.ejs Partial template for the sidebar section.
views.pages
File Summary
edit.ejs Template for editing user details.
view.ejs Template for viewing user details.
add.ejs Template for adding a new user.
views.layouts
File Summary
main.ejs Main layout template used across different views.

📝 Routes

The following routes are available in the application:

Method Route Description
GET / Home page, displays the list of users
GET /about About page
GET /add-user Page to add a new user
POST /add-user Submit a new user
GET /edit-user/:id Page to edit an existing user
POST /edit-user/:id Submit changes to an existing user
GET /view-user/:id View details of a specific user
GET /delete-user/:id Delete a specific user
GET /search Search users by name or other criteria

🚀 Getting Started

⚙️ Installation

  1. Clone the repository:

    git clone https://github.com/Rohit-Bhetal/userMGMTSys.git
    cd userMGMTSys
  2. Install dependencies:

    npm install
  3. Set up environment variables:

    Create a .env file in the root of the project and add the following:

    MONGO_URI=your_mongodb_uri

🤖 Running userMGMTSys

  1. Start the server:

    npm start
  2. Visit the application in your browser:

    http://localhost:3000
    

🛠 Project Roadmap

Planned enhancements and future features:

  • Integration of user authentication
  • Enhanced search capabilities
  • Implementing role-based access control (RBAC)
  • Deployment to a production environment

🤝 Contributing

Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.


📄 License

Distributed under the MIT License. See LICENSE for more information.


👏 Acknowledgments

This project was inspired by various online tutorials and open-source projects. Special thanks to the Node.js, Express, and MongoDB communities for their resources and support.

About

a basic user management system using Node.js, Express, Express-EJS and MongoDB.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published