feat(portal):优化AI对话窗口状态管理

- 移除硬编码的HTTP地址注释
- 修改最小化窗口点击事件处理逻辑- 移除窗口状态自动恢复的旧逻辑
- 新增restore事件机制处理窗口状态- 调整按钮图标颜色值- 完善AI Call组件的状态控制逻辑
- 保留
This commit is contained in:
陈昱达
2025-09-29 09:33:12 +08:00
parent 8c023d459f
commit e1f2e91648
3 changed files with 23 additions and 10 deletions

View File

@@ -7,7 +7,8 @@
<!-- 添加AI Call组件 -->
<AICall
:dialogVisible="showAICall"
@close="onCloseAICall"
@close="onCloseAICall"
@restore="onRestoreAICall"
/>
</div>
</template>
@@ -31,6 +32,11 @@
this.$store.dispatch('app/setShowAICall', false);
},
onRestoreAICall() {
// 通过Vuex显示AI Call组件
this.$store.dispatch('app/setShowAICall', true);
},
// 检查当前路由是否应该显示AI弹窗
checkRouteForAICall() {
const currentRoute = this.$route.name;
@@ -38,6 +44,7 @@
if (currentRoute === 'case' || currentRoute === 'caseDetail') {
// 设置最小化窗口显示状态为true
this.$store.dispatch('app/setShowAICallMinimized', true);
// 注意这里不再强制设置showAICall为true保留用户之前的操作状态
} else {
// 其他路由关闭弹窗
this.$store.dispatch('app/setShowAICall', false);