A full-stack web application for managing faculty research profiles, publications, projects, and patents β built with Flask, MongoDB, and vanilla HTML/CSS/JS.
faculty-research-system/
βββ backend/
β βββ app.py # Flask app β all API routes
β βββ seed_data.py # Seed MongoDB with sample data
β βββ requirements.txt # Python dependencies
βββ frontend/
β βββ static/
β β βββ css/style.css # All styling
β β βββ js/app.js # Frontend logic (Fetch API)
β βββ templates/
β βββ index.html # Single Page Application shell
βββ .env.example # Environment variable template
βββ .gitignore
βββ README.md
| Layer | Technology |
|---|---|
| Backend | Python 3.10+, Flask |
| Database | MongoDB (NoSQL) |
| Frontend | HTML5, CSS3, JS (ES6+) |
| Charts | Chart.js |
| DB Driver | pymongo |
- Python 3.10 or newer
- MongoDB Community Server (local) or MongoDB Atlas (cloud)
- pip
- Git
git clone https://github.com/YOUR_USERNAME/faculty-research-system.git
cd faculty-research-system# Create virtualenv
python -m venv venv
# Activate it
# Windows:
venv\Scripts\activatepip install -r backend/requirements.txt# Copy the example file
cp .env.example .envEdit .env:
MONGO_URI=mongodb://localhost:27017/
# OR for Atlas:
# MONGO_URI=mongodb+srv://<user>:<pass>@cluster.mongodb.net/
SECRET_KEY=your_random_secret_key_here
Local MongoDB:
# Windows β start from Services or:
net start MongoDBMongoDB Atlas:
Update MONGO_URI in your .env with your Atlas connection string.
cd backend
python seed_data.pyThis inserts 4 sample faculty members and creates the default admin account.
cd backend
python app.pyOpen your browser and go to: http://localhost:5000
| Username | Password |
|---|---|
admin |
admin123 |
β οΈ Change the password in production by updating theadminscollection in MongoDB.
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/login |
Admin login |
| POST | /api/logout |
Logout |
| GET | /api/auth/status |
Check session |
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/faculty |
List all faculty |
| GET | /api/faculty/<faculty_id> |
Get faculty profile |
| POST | /api/addFaculty |
Add new faculty |
| PUT | /api/updateFaculty/<faculty_id> |
Update faculty |
| DELETE | /api/deleteFaculty/<faculty_id> |
Delete faculty |
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/addPublication/<faculty_id> |
Add publication |
| PUT | /api/updatePublication/<faculty_id>/<pub_id> |
Update publication |
| DELETE | /api/deletePublication/<faculty_id>/<pub_id> |
Delete publication |
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/addProject/<faculty_id> |
Add project |
| DELETE | /api/deleteProject/<faculty_id>/<proj_id> |
Delete project |
| POST | /api/addPatent/<faculty_id> |
Add patent |
| DELETE | /api/deletePatent/<faculty_id>/<patent_id> |
Delete patent |
| Method | Endpoint | Query Params |
|---|---|---|
| GET | /api/searchFaculty |
name, department, interest, pub_year, project_status, funding_agency |
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/dashboard |
Stats + analytics |
- Go to https://cloud.mongodb.com and create a free account
- Create a new Cluster (free M0 tier works fine)
- Under Database Access, create a user with read/write permissions
- Under Network Access, add your IP (or
0.0.0.0/0for development) - Click Connect β Drivers and copy the connection string
- Paste it into your
.envfile asMONGO_URI
# Find faculty by department
collection.find({"department": "CSE"})
# Find by research interest
collection.find({"research_interests": {"$regex": "AI", "$options": "i"}})
# Top cited faculty (aggregation pipeline)
collection.aggregate([
{"$project": {"name": 1, "total_citations": {"$sum": "$publications.citation_count"}}},
{"$sort": {"total_citations": -1}},
{"$limit": 5}
])
# Add embedded document
collection.update_one({"faculty_id": "FAC101"}, {"$push": {"publications": {...}}})
# Remove embedded document
collection.update_one({"faculty_id": "FAC101"}, {"$pull": {"publications": {"pub_id": "p1"}}})- Admin login / session management
- Dashboard with live stats & charts
- Add / Edit / Delete faculty
- Add / Delete publications, projects, patents
- Faculty profile page with embedded records
- Multi-field search & filter
- Top-cited faculty analytics
- Funding agency analysis
- Department distribution chart
- Data validation & error handling
- MongoDB indexing (faculty_id, department, research_interests)
- Responsive design
Built as a NoSQL database project using Flask + MongoDB.