# zzyl **Repository Path**: enough-words/zzyl ## Basic Information - **Project Name**: zzyl - **Description**: 中州养老项目仓库 - **Primary Language**: Unknown - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-04-17 - **Last Updated**: 2026-07-25 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Smart Elderly Care Management System (Zzyl) ## Project Introduction The Smart Elderly Care Management System is a comprehensive information technology solution designed for elderly care institutions. The system adopts a separation of front-end and back-end architecture, with the backend built on **Spring Boot**. It features a complete employee management system, resident information management, room/bed management, nursing plan formulation, contract signing, and appointment visits functionality. Additionally, the system integrates WeChat Mini Program interfaces, supporting family members in making appointments and querying admission information. ## Tech Stack - **Core Framework**: Spring Boot 2.x - **Persistence Layer Framework**: MyBatis (with Generic Mapper and Interceptor for automatic field filling) - **Database**: MySQL (Relational data storage) - **Cache**: Redis (Session management, hot data caching) - **Object Storage**: Alibaba Cloud OSS (Contract files, image storage) - **API Documentation**: Swagger (Knife4j) (Interface visualization and testing) - **Security Authentication**: JWT (JSON Web Token) - **Scheduled Tasks**: Spring Task (Appointment status expiration processing, etc.) ## Project Structure The project utilizes Maven multi-module construction, mainly containing the following four core modules: ### 1. zzyl-common (Common Module) Provides common foundational components for the entire system. - **Base Classes**: `BaseEntity`, `BaseDto`, `BaseVo` (Unified management of data desensitization and basic fields) - **Utility Classes**: `SnowflakeIdWorker` (Distributed ID generation), `JwtUtil` (Token utilities), `StringUtils`, `UserThreadLocal` (User context) - **Configuration Classes**: Integration of Swagger, MyBatis, WebMvc, Alibaba Cloud OSS configurations - **Constant Definitions**: Cache key constants, system status code constants, etc. - **Exception Handling**: Global `GlobalExceptionHandler`, unified response format `ResponseResult` ### 2. zzyl-security (Security and Permissions Module) Responsible for system user authentication, permission control, and organizational structure management. - **User Management**: User CRUD, enable/disable, role assignment (`UserController`, `UserService`) - **Role Management**: Role permission configuration, data permission scope control (`RoleController`) - **Resource Menus**: Dynamic menu tree generation (`ResourceController`) - **Authentication**: Backend administrator login (`LoginController`) - **Entities**: `User`, `Role`, `Dept`, `Post`, `UserRole`, `RoleResource` ### 3. zzyl-service (Core Business Logic Module) Handles core business entities and processes of the nursing home. - **Elder Management**: Elder profiles, information modification, bed allocation (`ElderController`, `ElderService`) - **Room Management**: Floor, room, bed, and room type information maintenance (`RoomController`, `FloorController`, `BedController`) - **Contract Management**: Admission contracts, contract termination, PDF file management (`ContractController`) - **Nursing Management**: Nursing levels, nursing plans, nursing item management (`NursingPlanController`, `NursingLevelController`, `NursingProjectController`) - **Appointments and Visits**: Tour appointments, visit appointments, visitor check-in (`ReservationController`, `VisitController`) - **Members and WeChat**: WeChat Mini Program user login (`MemberService`, `WechatService`) ### 4. zzyl-web (WEB Startup Module and Controllers) The startup entry point of the project, responsible for exposing RESTful API interfaces. - **Controller Layer**: Directly handles requests from the front-end or Mini Program client. - **Scheduled Tasks**: Automatic processing of expired appointments (`ReservationJob`). ## Core Function Overview ### System Management - **Users and Permissions**: Based on the RBAC (Role-Based Access Control) model, supports granular menu and button permission control. - **Organizational Structure**: Supports multi-level department and post management. ### Elderly Care Business - **Elder Profiles**: Records personal information, health status, and bed number for elders. - **Room Management**: Three-tier structure of Floor-Room-Bed, supports querying by status (Vacant/Occupied). - **Nursing System**: Defines nursing levels, formulates periodic nursing plans, associates specific nursing items and costs. - **Contract Signing**: Full-process contract management, supports PDF storage and viewing. ### Appointments and Visits - **Appointment System**: Supports tour appointments and visit appointments, including time slot control. - **Visitor Registration**: Manages visitor information, records visit status (Pending Check-in, Completed, Cancelled). ### WeChat Mini Program (Member Side) - **User Login**: Exchanges WeChat `code` for `openId` to achieve silent login or mobile phone quick login. - **Business Processing**: Family members can view room types, submit appointment applications, and check appointment status. ## Quick Start ### Environment Requirements - JDK 1.8+ - Maven 3.0+ - MySQL 5.7+ / 8.0+ - Redis 3.0+ ### Configuration Modifications Configure database connections, Redis passwords, Alibaba Cloud OSS keys, and other information in `zzyl-web/src/main/resources/application.yml`. ```yaml spring: datasource: url: jdbc:mysql://localhost:3306/zzyl username: root password: password redis: host: localhost password: redis_password zzyl: framework: jwt: base64EncodedSecretKey: your_jwt_secret oss: endpoint: oss-cn-hangzhou.aliyuncs.com accessKeyId: your_access_key accessKeySecret: your_secret bucketName: your_bucket_name ``` ### Running the Project ```bash mvn clean package -DskipTests java -jar zzyl-web/target/zzyl-web.jar ``` ### API Documentation After starting the project, you can access the Swagger UI to view all interface documentation via the following address: `http://localhost:8080/doc.html` (Default port, subject to configuration) ## License [License Name]