fix(routing): 默认进入审核聊天工作台

This commit is contained in:
2026-06-04 08:47:27 +08:00
parent e701b4502e
commit 5aa7b5f3d0
2 changed files with 6 additions and 3 deletions

View File

@@ -1,13 +1,16 @@
from django.conf import settings from django.conf import settings
from django.conf.urls.static import static from django.conf.urls.static import static
from django.contrib import admin from django.contrib import admin
from django.views.generic import RedirectView
from django.urls import include, path from django.urls import include, path
# 总路由只承担模块装配职责,不在这里写业务逻辑。 # 总路由只承担模块装配职责,不在这里写业务逻辑。
urlpatterns = [ urlpatterns = [
path("admin/", admin.site.urls), path("admin/", admin.site.urls),
path("", include("apps.scenarios.urls")), # 首页默认进入审核工作台,旧的平台总览改为非默认入口,便于演示聚焦主链路。
path("", RedirectView.as_view(pattern_name="chat:index", permanent=False)),
path("scenarios/", include("apps.scenarios.urls")),
path("chat/", include("apps.chat.urls")), path("chat/", include("apps.chat.urls")),
path("documents/", include("apps.documents.urls")), path("documents/", include("apps.documents.urls")),
path("audit/", include("apps.audit.urls")), path("audit/", include("apps.audit.urls")),

View File

@@ -360,13 +360,13 @@
<body> <body>
<header class="topbar"> <header class="topbar">
<div class="topbar-inner"> <div class="topbar-inner">
<div class="brand"> <a class="brand" href="{% url 'chat:index' %}">
<div class="brand-mark">RA</div> <div class="brand-mark">RA</div>
<div> <div>
<h1>注册审核智能体平台</h1> <h1>注册审核智能体平台</h1>
<p>极简后台原型</p> <p>极简后台原型</p>
</div> </div>
</div> </a>
<nav class="topnav"> <nav class="topnav">
<a href="{% url 'chat:index' %}"{% if request.resolver_match.namespace == 'chat' %} class="active"{% endif %}>审核智能体</a> <a href="{% url 'chat:index' %}"{% if request.resolver_match.namespace == 'chat' %} class="active"{% endif %}>审核智能体</a>
<a href="{% url 'documents:list' %}"{% if request.resolver_match.namespace == 'documents' %} class="active"{% endif %}>资料包</a> <a href="{% url 'documents:list' %}"{% if request.resolver_match.namespace == 'documents' %} class="active"{% endif %}>资料包</a>