基于 .Net + TS 的超高颜值后台内核。开箱即用,提供 RBAC + ABAC 混合权限管理、多租户隔离、代码生成、实时通信、灰度发布、AI 等核心功能,满足新型企业级后台管理场景。属于曦寒懿(XiHanFun)开源生态的基础应用,拥有底座、组件、应用的完整生态。
基于 .Net + TS 的超高颜值后台内核。开箱即用,提供 RBAC + ABAC 混合权限管理、多租户隔离、代码生成、实时通信、灰度发布、AI 等核心功能,满足新型企业级后台管理场景。属于曦寒懿(XiHanFun)开源生态的基础应用,拥有底座、组件、应用的完整生态。
XiHan.BasicApp is a decoupled frontend/backend system. The backend follows DDD layering — writes go through application services, reads through query services — and application services are exposed directly as REST endpoints by the dynamic API convention. The frontend is Vue 3 + TypeScript + XiHan.UI, and the backend .NET 10 + XiHan.Framework. Identity, permissions, tenancy and auditing are built in, so it works both as the starting point for an admin project and as a reference for full-stack .NET + Vue practice. XiHan.BasicApp is the application layer of the XiHanFun open-source ecosystem, which spans foundation, components and applications.
| Destination | Contents |
|---|---|
| Documentation site | Full guides and topic-by-topic documentation |
| Backend engineering notes | Structure, project catalog, endpoint exposure, dependencies, local development |
| Frontend engineering notes | Stack, monorepo structure, architectural constraints, local development |
Tenant selection
User management
User management (dark)
Server monitoring
Preferences
Operation log
Log traceability
About
Mobile:
Identity and authentication
Permissions
module:resource:action; the super administrator wildcard is *Multi-tenancy
TenantId=0 reserved for global data; per-tenant databases are also supportedAudit logging
Code generation
AI
IAiSkillPlatform
[DynamicApi] with no controller boilerplate, and Scalar documentation is generated automaticallyPageRegistry registers menu, route, component path, permission code and i18n key togetherFrontend experience
Backend: .NET 10 with XiHan.Framework 4.0.0 (SqlSugar, Redis, SignalR, Serilog and Scalar all arrive through the framework). Frontend: Vue 3 + TypeScript + Vite 8 + XiHan.UI + Pinia + Tailwind CSS 4.
Item-by-item lists live in the backend and frontend engineering notes.
The system splits into a framework layer, a module layer and the host application; each module follows DDD layering internally (domain / application / infrastructure).
…| Project | Description | Removable |
|---|---|---|
XiHan.BasicApp.Core |
Application base composing the non-web framework modules and shared conventions | No |
XiHan.BasicApp.Web.Core |
Web base composing six framework web modules, provides the maintenance-mode middleware | No |
XiHan.BasicApp.Saas |
Platform governance: users / roles / permissions / menus / departments / tenants / settings / dictionaries / files / notifications / approvals / logs / jobs | No |
XiHan.BasicApp.CodeGeneration |
Code generation: data sources / schema import / template configuration / full-stack output | Yes |
XiHan.BasicApp.AI |
AI: providers and key custody / prompt library / knowledge-base RAG / skills as MCP tools / chat assistant | Yes (the assistant bridge depends on Chat) |
XiHan.BasicApp.Workflow |
Workflow: definitions / instances / todos — persistence and APIs over the framework engine | Yes |
XiHan.BasicApp.Printing |
Print templates: visual design / tenant and platform scopes / resolution by code | Yes |
XiHan.BasicApp.Chat |
Chat: direct / group / department / assistant conversations, realtime delivery, compliance auditing | Yes (also handle the AI assistant bridge) |
XiHan.BasicApp.WebHost |
Startup host composing every module | — |
…An optional module is one backend project plus one src/modules/ directory on the frontend. The per-side steps live in the backend and frontend engineering notes.
⚠️ Removal must be paired with rebuilding the database: seeded menus, permissions, role grants and scheduled jobs are not reclaimed when a module is deleted.
| Dependency | Version | Notes |
|---|---|---|
| .NET SDK | 10.0+ | required by the backend |
| Node.js | 24.0+ | required by the frontend |
| pnpm | 11.0+ | required by the frontend |
| PostgreSQL | 14+ | the only hard requirement; MySQL / SQL Server / SQLite / Oracle also work |
| Redis | 6.0+ | optional; falls back to in-process memory caching when disabled |
| Qdrant | v1.15+ | only needed for the AI knowledge base |
The repository root ships a docker-compose.yml with five services — PostgreSQL, Redis, Qdrant, backend and frontend:
cp .env.example .env
docker compose up -dThe frontend defaults to http://localhost:8080 and the backend to http://localhost:9708; both ports are configurable in .env.
git clone https://github.com/XiHanFun/XiHan.BasicApp.git
cd XiHan.BasicApp/backend
dotnet run --project src/main/XiHan.BasicApp.WebHost --launch-profile DevelopmentThen open http://127.0.0.1:9708/scalar for the API documentation. Ports per environment: Development 9708, Production 9709.
The connection string goes into XiHan:Data:SqlSugarCore:ConnectionConfigs in backend/src/main/XiHan.BasicApp.WebHost/appsettings.Development.json. The first start creates the schema and seeds it automatically.
The framework is consumed from NuGet by default, so cloning this repository alone is enough to build. See the backend engineering notes for working on the framework at the same time.
cd frontend
pnpm install
pnpm dev
@xihan-ui/*comes from the published npm releases, so cloning this repository on its own and runningpnpm installjust works — no siblingXiHan.UIcheckout required. To debug against the component library sources, temporarily add anoverridesblock inpnpm-workspace.yamlpointing atlink:../../XiHan.UI/ui/packages/*, then remove it; do not commit it.
The initial super administrator is superadmin with the password SuperAdmin@123. Override it through Saas:Seed:SuperAdminPassword (environment variable Saas__Seed__SuperAdminPassword). Always override it in production, and change it right after the first sign-in.
In no particular order.
| Project | Thanks for |
|---|---|
| XiHan.Framework | Being the backend foundation of this pr |
暂无开放 Issues,或尚未同步最近议题。