From 3f766107876e9193b2d5cd3ffbbdc02d69f4450a Mon Sep 17 00:00:00 2001 From: Daniel Bedeleanu Date: Fri, 10 Apr 2026 13:42:00 +0300 Subject: [PATCH] refactor: switch database architecture from PostgreSQL to SQLite --- PLAN.md | 4 ++-- requirements.md | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/PLAN.md b/PLAN.md index 6319c460..225988da 100644 --- a/PLAN.md +++ b/PLAN.md @@ -6,7 +6,7 @@ This document outlines the technical architecture for the unified Inventory Syst ### 1. Backend Server (Linux / Docker) - **Framework:** Python + FastAPI -- **Database:** PostgreSQL +- **Database:** SQLite (SQLAlchemy ORM) - **Key Modules:** - `Items / Interventions`: Standard CRUD logic. - `Audit`: Every payload that mutates data writes an immutable log row. @@ -24,7 +24,7 @@ This document outlines the technical architecture for the unified Inventory Syst ## Implementation Phases -- **Phase 1: Database & Backend Foundation** - Docker setup, PostgreSQL schemas, User management, and Python API structures. +- **Phase 1: Database & Backend Foundation** - SQLite schemas, User management, and Python API structures. - **Phase 2: Core Inventory API** - Endpoints to Add/Remove items, offline sync-merge logic, Audit triggers. - **Phase 3: The PWA Frontend** - PWA manifest, offline capabilities, UI scaffolding for Desktop/Mobile. - **Phase 4: Client-Side Scanning** - Integration of local JS barcode reading for routine stock scanning. diff --git a/requirements.md b/requirements.md index ed4ff5b9..e3343651 100644 --- a/requirements.md +++ b/requirements.md @@ -7,7 +7,7 @@ A unified system to maintain an inventory of "items" and their quantities, inclu ### 2.1 Main Application Server (Linux Backend) * **Target Environment:** Dockerized Linux Environment. -* **Framework:** Python (FastAPI) + PostgreSQL database. +* **Framework:** Python (FastAPI) + SQLite database. * **Users & Security:** Support multiple authenticated users with distinct actions. * **Audit Compliance:** **All operations** must maintain a strict audit log detailing who changed what and when.