A comprehensive web application for radiologists featuring a worklist management system and medical image viewer. Built with ASP.NET Core for the backend, React.js for the frontend, and Microsoft SQL Server database.
- Secure Authentication: JWT-based login system for radiologists
- Exam Management: Create, update, and track patient exams
- Patient Database: Comprehensive patient information management
- Worklist Interface: Grid-based exam history with search capabilities
- DICOM Viewer: Medical image viewing with basic measurement tools
- Status Tracking: Real-time exam status updates (Scheduled, Arrived, Canceled, Completed)
- RESTful API architecture
- React-based responsive frontend
- SQL Server database with Dapper ORM
- BLOB storage for medical images
- JWT authentication and authorization
- Search and filtering capabilities
- Framework: ASP.NET Core
- Database: Microsoft SQL Server
- ORM: Dapper
- Authentication: JWT (JSON Web Tokens)
- API: RESTful Web API
- Framework: React.js
- Data Fetching: TanStack Query (React Query)
- Form Management: React Hook Form
- Styling: TailwindCSS
- Build Tool: Vite
- Primary Database: Microsoft SQL Server
- Image Storage: BLOB storage in SQL Server
- Data Access: Dapper for efficient database operations
DICOMView.NET/
βββ frontend/ # React frontend application
β βββ src/
β βββ public/
β βββ package.json
β βββ ...
βββ backend/ # ASP.NET Core API
β βββ Controllers/
β βββ Models/
β βββ Services/
β βββ scripts/
β β βββ createTables.sql
β β βββ InsertDummyData.sql
β β βββ dataSeed.py
β βββ ...
βββ CT_data/ # Sample CT scan data
β βββ (DICOM files for testing)
βββ README.md
Before running the application, ensure you have the following installed:
- .NET 6.0 or later
- Node.js 16+ and npm
- Microsoft SQL Server
- Python 3.8+
- Git
git clone https://github.com/yourusername/DICOMView.NET.git
cd DICOMView.NET- Open SQL Server Management Studio (SSMS) or Azure Data Studio
- Connect to your SQL Server instance
- Execute the table creation script:
-- Create the WorkListTask database and tables
-- File location: /backend/scripts/createTables.sql-- Execute the dummy data script
-- File location: /backend/scripts/InsertDummyData.sql# Navigate to backend scripts directory
cd backend/scripts
# Install Python dependencies
pip install pyodbc pydicom
# Run the data seeding script to populate ExamBlob
python dataSeed.py- Navigate to
/backend/appsettings.json - Update the connection string:
{
"ConnectionStrings": {
"DefaultConnection": "Server=localhost;Database=WorkListTask;Trusted_Connection=true;TrustServerCertificate=true;"
},
"Jwt": {
"Key": "your-secret-key-here",
"Issuer": "DICOMView.NET",
"Audience": "DICOMView.NET"
}
}# Navigate to backend directory
cd backend
# Restore NuGet packages
dotnet restore
# Build the project
dotnet build
# Run the application
dotnet run or dotnet watch runThe API will be available at https://localhost:5190 (or the port specified in your configuration).
# Navigate to frontend directory
cd frontend
# Install npm packages
npm install or pnpm install
Update the API base URL in your frontend configuration (typically in a config file or environment variables):
// Example configuration
const API_BASE_URL = "https://localhost:5190/api";# Start the development server
npm run dev or npm run devThe frontend will be available at http://localhost:5173.
POST /api/auth/register- Register new userPOST /api/auth/login- User loginPOST /api/auth/refresh-token- Refresh JWT tokenGET /api/auth- Checks Authentication StateGET /api/auth/user- Get user detailsPOST /api/auth/logout- User logout
POST /api/exams/create- Create new examGET /api/exams/{examId}- Get one examPUT /api/exams/{examId}- Update examDELETE /api/exams/{examId}- Delete examGET /api/exams- Get all examsGET /api/exams/{examId}/dicom- Get DICOM data
GET /api/patients- Get all patients
- Access the application at
http://localhost:5173 - Use the provided credentials from the dummy data or register a new account
- Click "Add New Exam"
- Fill in patient details (ID, Name, Gender, Birthdate, Email)
- Specify exam type (CT Brain, Chest X-Ray, etc.)
- Set date and time
- Select exam status
- Access the worklist to see all patient exams
- Use search functionality to filter by patient ID, name, or exam date
- View exam details in grid format
- Double-click on any exam to open the viewer
- View medical images with basic measurement tools
- Navigate through image series
The application uses four main tables in the WorkListTask database:
- UserId (INT, Primary Key, Identity): Unique user identifier
- Username (VARCHAR(50), Unique): User login name
- PasswordHash (VARCHAR(255)): Hashed password for security
- Email (VARCHAR(100), Unique): User email address
- RefreshToken (VARCHAR(255), Nullable): Stores JWT refresh token
- RefreshTokenExpiryTime (DATETIME, Nullable): Refresh token expiration timestamp
- CreatedDate (DATETIME): Account creation timestamp
- PatientId (INT, Primary Key, Identity): Unique patient identifier
- PatientName (VARCHAR(100)): Patient's full name
- Birthdate (DATE): Patient's date of birth
- Gender (CHAR(1)): Patient gender (M/F)
- Email (VARCHAR(100), Unique): Patient email address
- CreatedDate (DATETIME): Record creation timestamp
- ExamId (INT, Primary Key, Identity): Unique exam identifier
- PatientId (INT, Foreign Key): Reference to Patients table
- ExamType (VARCHAR(100)): Type of exam (CT Brain, Chest X-Ray, etc.)
- ExamDate (DATETIME2): Scheduled exam date and time
- Status (VARCHAR(20)): Exam status (Scheduled, Arrived, Cancelled, Completed)
- Comments (TEXT): Additional exam notes
- CreatedDate (DATETIME): Record creation timestamp
- ExamBlobId (INT, Primary Key, Identity): Unique identifier for DICOM blob
- ExamId (INT, Foreign Key): Reference to Exams table
- DicomStudyBlob (VARBINARY(MAX)): DICOM image data stored as binary blob
- CreatedDate (DATETIME): Record creation timestamp
Note: This application is designed for educational and development purposes. For production use in healthcare environments, ensure compliance with relevant regulations (HIPAA, GDPR, etc.) and implement additional security measures.