{"id":23922442,"url":"https://github.com/thaokvu/clinical-data-capture-system","last_synced_at":"2025-02-23T22:23:45.675Z","repository":{"id":269128483,"uuid":"906516103","full_name":"thaokvu/Clinical-Data-Capture-System","owner":"thaokvu","description":"A Flask-powered web application for managing clinical trial patient data. Features include adding, editing, viewing, and deleting patient information. This project focuses on user-friendly interaction and clean design, with data stored in an SQLite database.","archived":false,"fork":false,"pushed_at":"2024-12-24T04:35:55.000Z","size":2874,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-05T17:13:54.607Z","etag":null,"topics":["clincal-data-management","css","flask","html","jinja2","python","sqlachemy","sqlite","web-development"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thaokvu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-21T05:48:11.000Z","updated_at":"2024-12-24T04:35:58.000Z","dependencies_parsed_at":"2024-12-22T00:24:58.071Z","dependency_job_id":null,"html_url":"https://github.com/thaokvu/Clinical-Data-Capture-System","commit_stats":null,"previous_names":["thaokvu/clinical-data-capture","thaokvu/clinical-data-capture-system"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thaokvu%2FClinical-Data-Capture-System","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thaokvu%2FClinical-Data-Capture-System/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thaokvu%2FClinical-Data-Capture-System/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thaokvu%2FClinical-Data-Capture-System/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thaokvu","download_url":"https://codeload.github.com/thaokvu/Clinical-Data-Capture-System/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240386728,"owners_count":19793224,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["clincal-data-management","css","flask","html","jinja2","python","sqlachemy","sqlite","web-development"],"created_at":"2025-01-05T17:13:56.919Z","updated_at":"2025-02-23T22:23:45.620Z","avatar_url":"https://github.com/thaokvu.png","language":"HTML","readme":"# Clincial Data Capture System\n\n## Overview\nA web-based application for managing patient information in clinical trials. This system allows users to add, view, edit, and delete patient records while ensuring a user-friendly interface and robust backend functionality. Built using Flask, SQLAlchemy, and Jinja2, the project seamlessly integrates front-end design and back-end logic for managing clinical data efficiently.\n\n## Features\n- Add Patients - Input patient details such as name, age, medical condition, and trial status\n- Edit Existing Patient Data - Modify existing patient details dynamically\n- Delete Patient - Remove patient data with a confirmation prompt to prevent accidental deletion\n- View Patient List - Display all patient records in a table format\n- Responsive Design - User-friendly interface with a clean and modern design\n\n## Technologies Used\n### Backend\n- **Python** - Core programming language for backend logic\n- **Flask** - Framework for routing, handling HTTP requests, and managing server-side logic\n- **SQLite** - Lightweight database for storing and managing patient data\n- **SQLAlchemy** - Object-Relational Mapping (ORM) library for interacting with SQLite database\n  \n### Frontend\n- **HTML** - Structuring the web pages for displaying patient information and forms\n- **CSS** - Styling the interface to make it visually appealing and user-friendly\n- **JavaScript** - Adding interactivity, such as the confirmation dialog for deleting a patient\n- **Jinja2** - Template engine for dynamically rendering HTML content based on backend data\n\n### Prerequisites\n- Python 3.10+\n- Flask\n- **Flask-SQLAlchemy**\n  \n### Installation\n1. **Clone the Repository**\n```bash\n   git clone https://github.com/thaokvu/clinical-data-capture.git\n   cd clinical-data-capture\n   ```\n   \n2. **Install Dependencies**\n```bash\n   pip install -r requirements.txt\n\n   # If you don't have a requirements.txt, manually install the dependencies\n   pip install flask flask-sqlalchemy\n   ```\n   \n3. **Set up the Database**\n```bash\nfrom main import db, app\nwith app.app_context():\ndb.create_all()\n\n# You can manually create the database tables by ensuring the db.create_all() function is executed in the app.py file\n   ```\n\n4. **Start the Application**\n```bash\n   python main.py\n   ```\n\n5. **Access the Application**\nOpen a web browser and go to the following URL -\n`http://127.0.0.1:5000/`\n\n## Project Structure\nThis project follows a simple and organized structure to make the codebase easy to understand and maintain. \n\n### Layout\n\u003cimg width=\"482\" alt=\"image\" src=\"https://github.com/user-attachments/assets/6e3cbb9d-85e2-4a83-8c64-896099aa645e\" /\u003e\n\n### Folder and File Description\n- **`static/style.css`** - Contains custom CSS to style the web pages and improve the user interface\n- **`templates/`** - Holds all the HTML templates for the web application\n    - **`add_patient.html`** - Displays the form for adding a new patient\n    - **`index_html`** - The main page that lists all patients in the database\n    - **`edit_patient.html`** - Displays the form for editing patient details\n- **`clinical_data.db`** - The SQLite database file where patient information is stored; it is auto-generated when the application is run for the first time\n- **`main.py`** - The main Flask application file that contains the app routes and logic\n- **`requirements.txt`** - Lists all the Python dependencies required to run the project\n- **README.md** - Project documentation that explains how to set up and use the application\n\n### Usage\n1. **Add a Patient**\n  - Fill in the patient's name, age, medical condition, and trial status\n  - Click the \"Add Patient\" button on the homepage to submit the form to add the patient to the database.\n2. **Edit Patient Data**\n  - Click the \"Edit\" button in the patient's row on the homepage\n  - Update the details in the form and save changes\n3. **Delete a Patient**\n  - Click the \"Delete\" button in the patient's row on the homepage\n4. **View All Patient**\n  - The homepage displays a list of all patients in a table format, including their details and actions\n\n## Screenshots\n\n### **Homepage - List of Patients**\n`http://127.0.0.1:5000/`\n- The table should display patient details (name, age, condition, trial status) with action buttons for \"Edit\" and \"Delete\".\n\u003cimg width=\"959\" alt=\"Clinical Data Capture System - Homepage (index html)\" src=\"https://github.com/user-attachments/assets/65f1d6e3-1f0a-4cdd-8f04-c84f7dde3642\" /\u003e\n\u003cimg width=\"959\" alt=\"Clinical Data Capture System - Homepage with Added Patient\" src=\"https://github.com/user-attachments/assets/af0406f9-3ab3-4e0c-b649-4116cad81a50\" /\u003e\n\n### **Add Patient Page**\n`http://127.0.0.1:5000/add_patient`\n- Users can input details for a new patient.\n\u003cimg width=\"959\" alt=\"Clinical Data Capture System - Add Patient (add_patient html)\" src=\"https://github.com/user-attachments/assets/5380d027-b2d4-4a4a-80f4-eabae06be7dd\" /\u003e\n\u003cimg width=\"959\" alt=\"Clinical Data Capture System - Add Patient (John Doe)\" src=\"https://github.com/user-attachments/assets/96333898-9629-42ed-b585-17462193c292\" /\u003e\n\n### **Edit Patient Page**\n`http://127.0.0.1:5000/edit_patient/1`\n- Users can update patient information. The form is pre-filled with existing patient details for easy editing.\n\u003cimg width=\"959\" alt=\"Clinical Data Capture System - Edit Patient (edit_patient html)\" src=\"https://github.com/user-attachments/assets/e939f8db-b56e-4917-b63f-b4a0caa61b93\" /\u003e\n\n### **Delete Patient Confirmation Dialog**\n- Confirmation dialog that appears when the \"Delete\" button is pressed. The dialog helps prevent accidental deletions by asking the user for confirmation before proceeding.\n\u003cimg width=\"959\" alt=\"Clinical Data Capture System - Delete Patient Confirmation\" src=\"https://github.com/user-attachments/assets/5b6b16a1-979a-4993-827f-d827ff817c2f\" /\u003e\n\n### Clinical Data Capture System Demo\nhttps://github.com/user-attachments/assets/23a67082-1c91-4942-888f-bba7465ab1e7\n\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthaokvu%2Fclinical-data-capture-system","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthaokvu%2Fclinical-data-capture-system","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthaokvu%2Fclinical-data-capture-system/lists"}