feat: 获取扫码的参数

This commit is contained in:
2025-09-04 21:27:58 +08:00
parent 46a3b6a878
commit 613a2be148
5 changed files with 75 additions and 38 deletions

View File

@@ -157,7 +157,9 @@ import {
import WebSocketManager from "@/utils/WebSocketManager";
import TypewriterManager from "@/utils/TypewriterManager";
import { IdUtils } from "@/utils";
import { useAppStore } from "@/store";
const appStore = useAppStore();
/// 导航栏相关
const statusBarHeight = ref(20);
/// 输入框组件引用
@@ -182,8 +184,6 @@ const chatMsgList = ref([]);
/// 输入口的输入消息
const inputMessage = ref("");
/// 从个渠道获取如二维,没有的时候就返回首页的数据
const sceneId = ref("");
/// agentId 首页接口中获取
const agentId = ref("1");
/// 会话ID 历史数据接口中获取
@@ -383,7 +383,9 @@ const loadConversationMsgList = async () => {
// 获取首页数据
const getMainPageData = async () => {
const res = await mainPageData(sceneId.value);
/// 从个渠道获取如二维,没有的时候就返回首页的数据
const sceneId = appStore.sceneId || "";
const res = await mainPageData(sceneId);
if (res.code === 0) {
mainPageDataModel.value = res.data;
agentId.value = res.data.agentId;