Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sdream-ai-fe
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
侯明涛
sdream-ai-fe
Commits
e3c00c45
Commit
e3c00c45
authored
Jan 12, 2026
by
Liu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:工单分割线每次提问都展示
parent
5b51f76d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
src/layouts/MainLayout/MainLayout.module.less
+1
-1
src/pages/ChatTactics/TacticsChat.tsx
+4
-1
No files found.
src/layouts/MainLayout/MainLayout.module.less
View file @
e3c00c45
...
...
@@ -6,7 +6,7 @@
flex: 1 1;
height: 100%;
width: 100%;
max-width: calc(100vw - 120px);
//
max-width: calc(100vw - 120px);
position: relative;
box-sizing: border-box;
// padding: 0 12px;
...
...
src/pages/ChatTactics/TacticsChat.tsx
View file @
e3c00c45
...
...
@@ -357,7 +357,10 @@ export const TacticsChat: React.FC = () => {
// 分割线应该显示在已有对话记录之后、新记录之前
// 渲染时使用 divider.index === index + 1 来匹配,所以分割线的 index 应该是新记录的位置
// 判断 allItems 中是否存在除了 system 之外的记录(user 或 ai)
if
(
isReanalyze
)
{
// 场景1: 重新分析时显示分割线
// 场景2: orderMeta 场景下,有历史记录且自动调用时也显示分割线
const
shouldCreateDivider
=
isReanalyze
||
(
orderMeta
&&
hasHistory
===
true
&&
!
question
)
if
(
shouldCreateDivider
)
{
const
hasExistingRecords
=
allItems
.
some
(
item
=>
item
.
role
!==
'system'
)
if
(
hasExistingRecords
)
{
// 基于当前 allItems 长度计算分割线位置
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment