{"id":49552288,"url":"https://github.com/thetealteam/spring-web","last_synced_at":"2026-05-02T23:43:47.842Z","repository":{"id":311393836,"uuid":"1043565954","full_name":"thetealteam/spring-web","owner":"thetealteam","description":"Inventory management system built with Spring Boot, designed as a modern web application for business operations management.","archived":false,"fork":false,"pushed_at":"2025-09-17T06:40:19.000Z","size":82166,"stargazers_count":4,"open_issues_count":0,"forks_count":3,"subscribers_count":0,"default_branch":"docs","last_synced_at":"2026-05-02T23:43:13.054Z","etag":null,"topics":["inventory-management-system","java","oracle","spring","spring-boot","springweb"],"latest_commit_sha":null,"homepage":"https://eirsvi.github.io/","language":"Java","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/thetealteam.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-08-24T06:13:20.000Z","updated_at":"2026-01-14T11:47:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"d1119ec9-5362-4c02-89e1-4397d4865ad4","html_url":"https://github.com/thetealteam/spring-web","commit_stats":null,"previous_names":["eirsvi/springweb","thetealteam/spring-web"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/thetealteam/spring-web","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thetealteam%2Fspring-web","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thetealteam%2Fspring-web/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thetealteam%2Fspring-web/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thetealteam%2Fspring-web/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thetealteam","download_url":"https://codeload.github.com/thetealteam/spring-web/tar.gz/refs/heads/docs","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thetealteam%2Fspring-web/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32553690,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T22:28:24.418Z","status":"ssl_error","status_checked_at":"2026-05-02T22:28:14.225Z","response_time":132,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["inventory-management-system","java","oracle","spring","spring-boot","springweb"],"created_at":"2026-05-02T23:43:47.167Z","updated_at":"2026-05-02T23:43:47.836Z","avatar_url":"https://github.com/thetealteam.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"\nSpringWeb is a full-stack enterprise application built with Spring Boot 3.5.5 that combines modern web technologies with traditional business management needs. The system features a unique profile-based authentication system with visual user cards and provides comprehensive modules for managing products, orders, suppliers, transactions, and more.\n\n### Unique Authentication System\n- **Visual Profile Cards**: Users authenticate by selecting their profile card and entering a 2-digit access code\n- **Secure Session Management**: Server-side session handling with automatic timeout\n- **Khmer Language Support**: Full bilingual support with beautiful Khmer typography using Koh Santepheap font\n- **No Traditional Passwords**: Simplified yet secure authentication approach\n\n### Business Management Modules\n- **Product Management**: Comprehensive inventory tracking with categories and suppliers\n- **Order Processing**: Full order lifecycle management with status tracking\n- **Supplier Management**: Vendor information and relationship management  \n- **Financial Transactions**: Payment processing and transaction history\n- **Category Management**: Product categorization and organization\n- **Reporting System**: Business analytics and insights\n\n### Modern UI/UX Design\n- **Glassmorphism Interface**: Stunning glass-effect design with backdrop blur\n- **Responsive Layout**: Optimized for desktop, tablet, and mobile devices\n- **Emerald Green Theme**: Professional color scheme with subtle gradients\n- **Material Design Icons**: Clean and consistent iconography\n- **Smooth Animations**: Engaging micro-interactions and transitions\n\n### Enterprise Architecture\n- **RESTful API Design**: Clean separation between frontend and backend\n- **JPA/Hibernate ORM**: Robust database abstraction layer\n- **Spring Security Integration**: Built-in security features and CSRF protection\n- **Thymeleaf Templates**: Server-side rendering with dynamic content\n- **Modular Structure**: Scalable and maintainable codebase\n\n## Application Architecture\n\n### MVC Flow Diagram\n```mermaid\ngraph TD\n    subgraph Client Layer\n        B[Browser] --\u003e |HTTP Request| F[Front Controller - DispatcherServlet]\n    end\n\n    subgraph Controller Layer\n        F --\u003e |Forward Request| C1[WebController]\n        F --\u003e |REST Request| C2[ProductController]\n        F --\u003e |REST Request| C3[CategoryController]\n        F --\u003e |REST Request| C4[OrderController]\n        F --\u003e |REST Request| C5[SupplierController]\n        F --\u003e |REST Request| C6[TransactionController]\n    end\n\n    subgraph Service Layer\n        C1 --\u003e |Business Logic| S1[Services]\n        C2 --\u003e |Business Logic| S1\n        C3 --\u003e |Business Logic| S1\n        C4 --\u003e |Business Logic| S1\n        C5 --\u003e |Business Logic| S1\n        C6 --\u003e |Business Logic| S1\n    end\n\n    subgraph Repository Layer\n        S1 --\u003e |Data Access| R1[ProductRepository]\n        S1 --\u003e |Data Access| R2[CategoryRepository]\n        S1 --\u003e |Data Access| R3[OrderRepository]\n        S1 --\u003e |Data Access| R4[SupplierRepository]\n        S1 --\u003e |Data Access| R5[TransactionRepository]\n    end\n\n    subgraph Database Layer\n        R1 --\u003e |JPA/Hibernate| DB[(MySQL Database)]\n        R2 --\u003e |JPA/Hibernate| DB\n        R3 --\u003e |JPA/Hibernate| DB\n        R4 --\u003e |JPA/Hibernate| DB\n        R5 --\u003e |JPA/Hibernate| DB\n    end\n\n    subgraph View Layer\n        C1 --\u003e |Model Data| V1[Thymeleaf Templates]\n        V1 --\u003e |Render| H[HTML/CSS/JS]\n        H --\u003e |Response| B\n    end\n\n    subgraph REST API Layer\n        C2 --\u003e |JSON Response| B\n        C3 --\u003e |JSON Response| B\n        C4 --\u003e |JSON Response| B\n        C5 --\u003e |JSON Response| B\n        C6 --\u003e |JSON Response| B\n    end\n```\n\n### Data Flow Process\n1. **Client Request**: Browser sends HTTP request (page load or AJAX)\n2. **Front Controller**: DispatcherServlet receives and routes request\n3. **Controller Processing**:\n   - Web requests → WebController (Thymeleaf views)\n   - API requests → REST Controllers (JSON responses)\n4. **Service Layer**: Handles business logic and transactions\n5. **Repository Layer**: Manages data access through JPA\n6. **Database Layer**: Stores and retrieves data using MySQL\n7. **Response Generation**:\n   - Web pages: Thymeleaf templates render HTML\n   - API calls: Controllers return JSON responses\n\n### Security Flow\n```mermaid\nsequenceDiagram\n    participant Client\n    participant Security\n    participant Controller\n    participant Service\n    participant Database\n\n    Client-\u003e\u003eSecurity: Request with Session\n    alt Not Authenticated\n        Security-\u003e\u003eClient: Redirect to Login\n    else Authenticated\n        Security-\u003e\u003eController: Forward Request\n        Controller-\u003e\u003eService: Process Request\n        Service-\u003e\u003eDatabase: Data Operation\n        Database-\u003e\u003eService: Data Response\n        Service-\u003e\u003eController: Process Response\n        Controller-\u003e\u003eClient: Return Response\n    end\n```\n\n### Dashboard Data Flow\n```mermaid\ngraph LR\n    subgraph Frontend\n        JS[Dashboard.js] --\u003e |AJAX Calls| API\n    end\n\n    subgraph Backend\n        API[REST API] --\u003e |Request| C[Controllers]\n        C --\u003e |Process| S[Services]\n        S --\u003e |Query| DB[(Database)]\n        DB --\u003e |Data| S\n        S --\u003e |Stats| C\n        C --\u003e |JSON| API\n    end\n\n    API --\u003e |Response| JS\n```\n\n## API Reference\n\n### Base URL\n```\nhttp://localhost:10000/api\n```\n### API Endpoints \u0026 Data Examples\n\n#### Base URL\n```\nhttp://localhost:9999/api/v1\n```\n\n#### Dashboard Endpoints\n```javascript\n// Fetch Dashboard Stats\nGET /api/v1/dashboard/stats\nfetch('http://localhost:9999/api/v1/dashboard/stats')\n\n// Example Response\n{\n    \"totalSales\": \"១២៣,៤៥៦\",\n    \"totalOrders\": \"២៣៤\",\n    \"activeProducts\": \"៤៥៦\",\n    \"recentTransactions\": [\n        {\n            \"id\": \"TR001\",\n            \"amount\": \"១២០០៛\",\n            \"date\": \"២០២៤-០១-១៥\",\n            \"type\": \"ការលក់\"\n        }\n    ]\n}\n```\n\n#### Categories\n```javascript\n// Fetch Categories\nGET /api/v1/categories\nfetch('http://localhost:9999/api/v1/categories')\n\n// Example Response\n{\n    \"categories\": [\n        {\n            \"id\": \"CAT001\",\n            \"name\": \"បង្អែម\",\n            \"description\": \"នំគ្រប់ប្រភេទ\"\n        },\n        {\n            \"id\": \"CAT002\", \n            \"name\": \"ភេសជ្ជៈ\",\n            \"description\": \"ទឹកដបគ្រប់ប្រភេទ\"\n        },\n        {\n            \"id\": \"CAT003\",\n            \"name\": \"ម្ហូបអាហារ\",\n            \"description\": \"អាហារគ្រប់មុខ\"\n        }\n    ]\n}\n```\n\n#### Suppliers \n```javascript\n// Fetch Suppliers\nGET /api/v1/suppliers\nfetch('http://localhost:9999/api/v1/suppliers')\n\n// Example Response\n{\n    \"suppliers\": [\n        {\n            \"id\": \"SUP001\",\n            \"name\": \"ក្រុមហ៊ុន កសិផល\",\n            \"contact\": \"០២៣ ២៣៤ ៥៦៧\",\n            \"address\": \"ផ្សារថ្មី\"\n        },\n        {\n            \"id\": \"SUP002\",\n            \"name\": \"អ្នកស្រី សុខា\",  \n            \"contact\": \"០១២ ៣៤៥ ៦៧៨\",\n            \"address\": \"ទួលគោក\"\n        }\n    ]\n}\n```\n\n#### Products\n```javascript\n// Fetch Products\nGET /api/v1/products\nfetch('http://localhost:9999/api/v1/products')\n\n// Example Response\n{\n    \"products\": [\n        {\n            \"id\": \"PRD001\", \n            \"name\": \"បាយដំណើប\",\n            \"price\": \"២០០០៛\",\n            \"stock\": \"៥០\"\n        },\n        {\n            \"id\": \"PRD002\",\n            \"name\": \"នំបញ្ចុក\",\n            \"price\": \"៣០០០៛\", \n            \"stock\": \"៣០\"\n        }\n    ]\n}\n```\n\n#### Orders\n```javascript\n// Fetch Orders\nGET /api/v1/orders\nfetch('http://localhost:9999/api/v1/orders')\n\n// Example Response\n{\n    \"orders\": [\n        {\n            \"id\": \"ORD001\",\n            \"customer\": \"សុខា\",\n            \"total\": \"៥០០០០៛\",\n            \"status\": \"បញ្ចប់\"\n        },\n        {\n            \"id\": \"ORD002\",\n            \"customer\": \"វណ្ណា\",\n            \"total\": \"៣០០០០៛\",\n            \"status\": \"កំពុងដឹក\"\n        }\n    ]\n}\n```\n\n#### Users\n```javascript\n// Fetch Users\nGET /api/v1/users\nfetch('http://localhost:9999/api/v1/users')\n\n// Example Response\n{\n    \"users\": [\n        {\n            \"id\": \"USR001\",\n            \"name\": \"សុខា\",\n            \"role\": \"អ្នកគ្រប់គ្រង\",\n            \"status\": \"សកម្ម\"\n        },\n        {\n            \"id\": \"USR002\",\n            \"name\": \"វណ្ណា\",\n            \"role\": \"អ្នកលក់\",\n            \"status\": \"សកម្ម\"\n        }\n    ]\n}\n```\n\n#### Transactions\n```javascript\n// Fetch Transactions\nGET /api/v1/transactions\nfetch('http://localhost:9999/api/v1/transactions')\n\n// Example Response\n{\n    \"transactions\": [\n        {\n            \"id\": \"TRX001\",\n            \"type\": \"ការលក់\",\n            \"amount\": \"១២០០០៛\",\n            \"date\": \"២០២៤-០១-១៥\"\n        },\n        {\n            \"id\": \"TRX002\", \n            \"type\": \"ការទិញ\",\n            \"amount\": \"៥០០០០៛\",\n            \"date\": \"២០២៤-០១-១៤\"\n        }\n    ]\n}\n```\n\n#### Reports\n```javascript\n// Fetch Reports\nGET /api/v1/reports/{type}\nfetch('http://localhost:9999/api/v1/reports/sales')\n\n// Example Response\n{\n    \"reportType\": \"របាយការណ៍លក់\",\n    \"period\": \"ខែមករា ២០២៤\",\n    \"data\": [\n        {\n            \"date\": \"២០២៤-០១-១៥\",\n            \"sales\": \"១២០០០០៛\",\n            \"items\": \"២០\"\n        }\n    ]\n}\n```\n\n#### Settings\n```javascript\n// Fetch Settings\nGET /api/v1/settings\nfetch('http://localhost:9999/api/v1/settings')\n\n// Example Response\n{\n    \"settings\": {\n        \"companyName\": \"ហាងលក់ទំនិញ\",\n        \"phone\": \"០២៣ ២៣៤ ៥៦៧\",\n        \"address\": \"ភ្នំពេញ\",\n        \"currency\": \"រៀល\",\n        \"language\": \"ខ្មែរ\"\n    }\n}\n```\n\n\n\n\n\n### HTTP Status Codes\n- 200: Successful operation\n- 401: Authentication required\n- 403: Access forbidden\n- 404: Resource not found\n- 500: Server error\n\n### Prerequisites\nBefore running the application, ensure you have:\n- Java 21 or higher installed\n- Maven 3.6+ (or use included wrapper)\n- Git for version control\n- MySQL Server 8.0+ (optional, H2 available for development)\n- Modern web browser (Chrome, Firefox, Safari, Edge)\n\n### Quick Start Guide 🚀\n\n1. **Clone the Repository**\n   ```bash\n   git clone https://github.com/yourusername/SpringWeb.git\n   cd SpringWeb\n   ```\n\n2. **Configure Database**\n   - Create MySQL database:\n     ```sql\n     CREATE DATABASE java_spring_boot_db;\n     ```\n   - Update `application.properties` with your database credentials:\n     ```properties\n     spring.datasource.url=jdbc:mysql://localhost:3306/java_spring_boot_db\n     spring.datasource.username=your_username\n     spring.datasource.password=your_password\n     ```\n\n3. **Build and Run**\n   ```bash\n   # Using Maven Wrapper\n   ./mvnw clean install\n   ./mvnw spring-boot:run\n\n   # Or using installed Maven\n   mvn clean install\n   mvn spring-boot:run\n   ```\n\n4. **Access the Application**\n   - Open your browser and navigate to: `http://localhost:10000`\n   - Default credentials will be displayed on the login page\n\n\nnetsh advfirewall firewall add rule name=\"SpringBoot8084\" dir=in action=allow protocol=TCP localport=8084\n\n\n\n\n\n### Main Navigation Menu\n\n\u003e Each menu item uses Material Icons and provides quick access to core modules.\n\n- **Logo**: \n    - Company/application branding element\n    - Acts as a home button/link\n\n- **Dashboard** `dashboard`:\n    - Main overview screen\n    - Shows key metrics and analytics  \n    - First screen after login\n\n- **Categories** `local_offer`:\n    - Manage product categories\n    - Organize products into groups\n    - Tag and classify items\n\n- **Suppliers** `local_shipping`:\n    - Manage vendor information\n    - Track supplier relationships\n    - Handle supplier contracts\n\n- **Products** `inventory_2`:\n    - Manage product catalog\n    - Track inventory levels\n    - Handle product details\n\n- **Orders** `shopping_cart`:\n    - Process customer orders\n    - Track order status\n    - Manage fulfillment\n\n- **Transactions** `credit_card`:\n    - Track payment records\n    - Monitor financials\n    - Handle payments\n\n- **Reports** `bar_chart`:\n    - Generate business reports\n    - View analytics/trends\n    - Export data\n\n- **Settings** `settings`:\n    - System configuration\n    - User preferences\n    - Application settings\n\n\n\n## Technology Stack\n\n### Backend Technologies\n- **Framework**: Spring Boot 3.5.5\n- **Java Version**: Java 21 (LTS)\n- **Database**: MySQL 8.0+ / H2 (development)\n- **ORM**: Hibernate 6.6.26 with JPA\n- **Template Engine**: Thymeleaf\n- **Build Tool**: Maven 3.6+\n- **Application Server**: Embedded Tomcat 10.1.44\n\n### Frontend Technologies  \n- **Languages**: HTML5, CSS3, JavaScript (ES6+)\n- **Styling**: Custom CSS with CSS Grid and Flexbox\n- **Fonts**: Google Fonts (Ubuntu, Koh Santepheap)\n- **Icons**: Material Icons + Font Awesome\n- **UI Framework**: Custom glassmorphism components\n\n### Development Tools\n- **IDE**: Compatible with IntelliJ IDEA, Eclipse, VS Code\n- **Version Control**: Git\n- **Package Management**: Maven Central Repository\n- **Testing**: JUnit 5, Spring Boot Test\n\n\n## Business Modules \u0026 Features\n\n### Dashboard Overview\n- **Real-time Statistics**: Key performance indicators and metrics\n  - Total products, orders, and revenue tracking\n  - Category-wise product distribution\n  - Stock status and low stock alerts\n  - Revenue analysis with trends\n- **Interactive Charts**: Beautiful visualizations using Chart.js\n  - Revenue line graph with total and net revenue\n  - Category distribution pie chart\n  - Stock status bar chart\n  - Transaction type and payment method analysis\n- **User Welcome**: Personalized greeting in both English and Khmer\n- **Quick Actions**: Direct access to frequently used features\n- **System Status**: Server health and database connection status\n- **Real-time Updates**: Dynamic data refresh without page reload\n\n### Recent Updates (September 2025)\n- Added comprehensive dashboard with real-time analytics\n- Implemented automatic invoice generation for orders\n- Enhanced stock management with low stock alerts\n- Added support for multiple payment methods\n- Improved transaction tracking and reporting\n- Enhanced UI with responsive design and better user experience\n\n### Product Management\n- **Inventory Tracking**: Real-time stock levels and alerts\n- **Category Organization**: Hierarchical product categorization  \n- **Supplier Integration**: Link products to suppliers\n- **Price Management**: Dynamic pricing with history tracking\n- **Bulk Operations**: Import/export product data\n\n### Order Processing\n- **Order Lifecycle**: From creation to delivery tracking\n- **Customer Management**: Customer information and history\n- **Order Status Tracking**: Real-time status updates\n- **Invoice Generation**: Automated invoice creation\n- **Payment Integration**: Multiple payment method support\n\n### Supplier Management\n- **Vendor Database**: Complete supplier information\n- **Contact Management**: Multiple contact persons per supplier\n- **Performance Tracking**: Supplier rating and history\n- **Purchase Orders**: Automated PO generation\n- **Communication Log**: Interaction history tracking\n\n### Financial Transactions\n- **Payment Processing**: Multiple payment methods\n- **Transaction History**: Complete audit trail\n- **Refund Management**: Easy refund processing\n- **Financial Reporting**: Revenue and expense tracking\n- **Tax Management**: Tax calculation and reporting\n\n### Reporting \u0026 Analytics\n- **Sales Reports**: Detailed sales analytics\n- **Inventory Reports**: Stock levels and movement\n- **Financial Reports**: Profit/loss statements\n- **User Activity**: System usage analytics\n- **Export Capabilities**: PDF, Excel, CSV exports\n\n## Security \u0026 Authentication\n\n### Profile-Based Authentication\n- **Visual Authentication**: Select profile card instead of typing username\n- **2-Digit Access Codes**: Simple yet secure authentication\n- **Session Management**: Automatic session timeout and renewal\n- **CSRF Protection**: Built-in cross-site request forgery protection\n- **XSS Prevention**: Input sanitization and output encoding\n\n### Data Security\n- **SQL Injection Prevention**: Parameterized queries with JPA\n- **Input Validation**: Server-side validation for all inputs\n- **Secure Headers**: HTTP security headers implementation\n- **Audit Trail**: Complete user action logging\n- **Data Encryption**: Sensitive data encryption at rest\n\n### Access Control\n- **Role-Based Access**: Different access levels per user\n- **Module Permissions**: Granular permission system\n- **Session Security**: Secure session token management\n- **Failed Login Protection**: Account lockout after failed attempts\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthetealteam%2Fspring-web","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthetealteam%2Fspring-web","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthetealteam%2Fspring-web/lists"}