# ruoyi-rs **Repository Path**: aoplxml/ruoyi-rs ## Basic Information - **Project Name**: ruoyi-rs - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2025-07-22 - **Last Updated**: 2025-08-17 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # ruoyi-rs - Rust版若依后台管理系统 这是一个使用 Rust 语言编写的后台管理系统,基于 spring-rs 框架开发,灵感来源于 Java 版若依(RuoYi)后台管理系统。 ## 技术栈 - **语言**: Rust - **框架**: [spring-rs](https://github.com/spring-rs/spring-rs) - 类似 Spring Boot 的 Rust Web 框架 - **Web**: Axum - **ORM**: SeaORM - **数据库**: MySQL - **缓存**: Redis - **认证**: JWT - **异步运行时**: Tokio ## 项目结构 ``` ruoyi-rs/ ├── admin/ # 管理后台模块 │ ├── src/ │ │ ├── controller/ # 控制器层 │ │ ├── models/ # 数据模型 │ │ ├── service/ # 业务逻辑层 │ │ ├── main.rs # 程序入口 │ │ └── router.rs # 路由配置 │ └── Cargo.toml ├── core/ # 核心模块 │ ├── src/ │ │ ├── config/ # 配置相关 │ │ ├── entity/ # 数据实体 │ │ ├── middlewares/# 中间件 │ │ ├── plugin/ # 插件 │ │ ├── response/ # 响应处理 │ │ └── utils/ # 工具类 │ └── Cargo.toml ├── config/ # 配置文件目录 │ └── app.toml # 应用配置文件 └── doc/ # 文档目录 ``` ## 功能特性 - 用户登录认证 - 验证码生成与验证 - JWT Token 认证 - 用户信息管理 - 部门信息管理 - 路由权限控制 ## 环境要求 - Rust 2021 或更高版本 - MySQL 5.7 或更高版本 - Redis ## 安装与运行 1. 克隆项目代码: ```bash git clone cd ruoyi-rs ``` 2. 配置数据库和 Redis: 编辑 [config/app.toml](file:///D:/workspace/rust/ruoyi-rs/config/app.toml) 文件,修改数据库和 Redis 连接信息: ```toml [sea-orm] uri = "mysql://username:password@localhost:3306/database" [redis] uri = "redis://localhost/" ``` 3. 运行项目: ```bash cargo run ``` 4. 访问应用: 浏览器访问 `http://localhost:8080` ## 开发说明 ### 编译项目 ```bash # 检查语法 cargo check # 构建项目 cargo build # 运行项目 cargo run ``` ### 代码质量 项目当前存在一些未使用的导入和代码,可以通过以下命令修复: ```bash cargo fix ``` ## API 文档 项目包含以下主要接口: - `POST /login` - 用户登录 - `GET /getInfo` - 获取用户信息 - `GET /getRouters` - 获取路由信息 - `GET /captchaImage` - 获取验证码 详细接口文档请参考 [doc/登录](file:///D:/workspace/rust/ruoyi-rs/doc/%E7%99%BB%E5%BD%95) 目录下的文档。 ## 许可证 本项目采用 MIT 许可证,详情请见 [LICENSE](file:///D:/workspace/rust/ruoyi-rs/LICENSE) 文件。