A web application designed to help junior doctors quickly find appropriate medications and disease information organized by medical specialty.
eOrdonnances provides a specialty-based interface for medical professionals to browse diseases, view treatment recommendations, and access diagnostic information. The application covers 9 major medical specialties including Cardiology, Dermatology, Neurology, Gastroenterology, and more.
Version: 0.1.0
Language: French (UI & Medical Terminology)
Status: Active Development
- Specialty-Based Disease Browsing - Navigate 9 medical specialties with interactive cards
- Disease Search & Filtering - Search by disease name and filter by specialty
- Disease Management - View, add, and delete diseases with detailed information
- Medication Database - Browse medications with French pharmaceutical data
- Dark/Light Theme - Toggle between themes with persistent state
- Responsive Design - Mobile-first layout with desktop navigation sidebar
- Print Functionality - Print-optimized view for disease information
- Pagination - Browse diseases with 25 items per page
- 🫀 Cardiologie (Cardiology)
- 🧠 Neurologie (Neurology)
- 🫁 Pneumologie (Pulmonology)
- 🩹 Dermatologie (Dermatology)
- 🔗 Gastro-entérologie (Gastroenterology)
- 🏥 Urologie (Urology)
- 👶 Gynéco-Obstétrique (Gynecology)
- 👂 Oto-rhino-laryngologie (ENT/ORL)
- 🚑 Urgences (Emergency Medicine)
- User authentication
- User profiles & favorites
- Advanced medication filtering
- PDF export functionality
- API documentation
- Comprehensive testing
- Automated deployment pipeline
- Next.js 14.1.0 - React framework with App Router
- React 18 - UI library with hooks
- Tailwind CSS 3.3.0 - Utility-first styling
- Framer Motion 11.0.14 - Smooth animations
- React Hook Form 7.51.5 - Form state management
- Heroicons React 2.0.18 - Icon library
- Node.js - Runtime environment
- MongoDB with Mongoose 8.1.3 - NoSQL database & ODM
- Nodemailer 6.9.13 - Email service
- ESLint 8 - Code linting
- TypeScript - Type checking (configuration ready)
- PostCSS 8 - CSS transformation
- Tailwind CSS - CSS framework
- Node.js 18+
- bun (preferred) or npm
- MongoDB instance (local or Atlas)
-
Clone the repository
git clone <repository-url> cd eordonnances
-
Install dependencies
bun install
-
Configure environment variables Create a
.env.localfile in the root directory:DB_URL=mongodb+srv://<username>:<password>@<cluster>.mongodb.net/eordonnances
-
Run development server
bun run dev
-
Open in browser Navigate to http://localhost:3000
- Home - View medical specialties
- Recherchez (Search) - Search diseases by name or specialty
- Ajouter (Add) - Create new disease entries
- Theme Toggle - Switch between dark and light modes
- Click "Recherchez" or a specialty card
- Use the search bar to find diseases by name
- Filter by specialty using the dropdown
- Click a disease to view full details
- Click "Ajouter" in the navigation
- Fill in disease information:
- Disease name
- Medical specialty
- Definition/description
- Medications (Rx)
- Diagnostic information (Dx)
- Submit to save to database
eordonnances/
├── app/
│ ├── api/ # API Routes
│ │ ├── disease/ # Disease CRUD operations
│ │ ├── medications/ # Medication endpoints
│ │ └── mdcDB/ # Medication database
│ ├── ui/ # Reusable components
│ │ ├── Navbar.jsx
│ │ ├── SpecialtyCards.jsx
│ │ ├── ThemeContext.jsx
│ │ └── icons/ # Medical specialty icons
│ ├── diseases/ # Disease pages
│ ├── libs/ # Utility functions
│ ├── layout.js # Root layout
│ └── page.jsx # Home page
├── models/ # Mongoose schemas
│ ├── diseaseModel.js
│ ├── medicationModel.js
│ └── DDxModel.js
├── public/ # Static assets (SVGs)
├── .env # Environment variables
├── next.config.mjs # Next.js configuration
├── tailwind.config.js # Tailwind customization
└── package.json # Dependencies
GET /api/disease
- Retrieve paginated disease list
- Query params:
page,q(search),specialty - Returns: Array of diseases with pagination
POST /api/disease
- Create new disease (currently disabled)
- Body: Disease object with name, specialty, definition
DELETE /api/disease
- Delete disease by ID
- Query param:
id
GET /api/medications/[name]
- Search medications by name
- Returns: Medication details
GET /api/mdcDB
- Access medication database
{
disease: {
name: String,
specialty: String,
definition: String
},
Rx: Mixed, // Medications/prescriptions
Dx: [ObjectId], // Diagnostic references
DDx: ObjectId // Differential diagnosis
}Schema prepared for expansion with:
- CIS codes
- Pharmaceutical forms
- Administration routes
- Pricing information
- Composition details
# Start development server with hot reload
bun run dev
# Build for production
bun run build
# Start production server
bun start
# Run ESLint
bun run lintThe application uses CSS custom properties for theming:
- Light mode: Clean white backgrounds with dark text
- Dark mode: Dark backgrounds with light text
- Theme state persists across sessions
- Specialty cards have dedicated color schemes
Toggle theme using the icon in the top navigation.
MongoDB connection is established via Mongoose in app/libs/mongodb.js. The application:
- Connects to MongoDB on each API request
- Uses mongoose model caching to prevent duplicate model creation
- Logs connection status to console
Connection string should be stored in .env.local:
DB_URL=mongodb+srv://username:password@cluster.mongodb.net/database- Static generation with 60-second revalidation for home page
- Aggregation pipeline for efficient database queries
- CSS-in-JS for dynamic styling
- Debounced search input (10ms)
- Image optimization through SVG assets
- No user authentication system
- Medication model not fully implemented
- Limited error handling
- No input validation on API endpoints
- No test coverage
- Database connection pooling not implemented
- Implement authentication (JWT/OAuth)
- Add comprehensive error handling
- Input validation with Zod or Joi
- Database connection pooling
- Unit and integration tests (Jest)
- API rate limiting
- Add search result caching (Redis)
- Implement differential diagnosis relationships
- Create mobile native app version
Required for development:
DB_URL=mongodb://connection-stringOptional (prepared for future use):
POSTGRES_URL= # For Vercel Postgres
NODEMAILER_USER= # For email functionality
NODEMAILER_PASSWORD= # For email functionality- Vercel (recommended for Next.js)
- Netlify
- Self-hosted (AWS, DigitalOcean, etc.)
- Environment variables configured
- MongoDB backup strategy in place
- Error monitoring set up (Sentry)
- Analytics integrated
- Security headers configured
- Database indexes optimized
To contribute to eOrdonnances:
- Create a feature branch (
git checkout -b feature/YourFeature) - Make your changes
- Commit (
git commit -m 'Add YourFeature') - Push to branch (
git push origin feature/YourFeature) - Open a Pull Request
This project is private and maintained for medical education purposes.
For issues, questions, or suggestions, please create an issue in the project repository.
Last Updated: December 2025
Next Priority Features: User authentication, comprehensive testing, API documentation
